精彩专栏推荐订阅:在 下方专栏👇🏻👇🏻👇🏻👇🏻
💖🔥作者主页:计算机毕设木哥🔥 💖
一、项目介绍
随着互联网技术的发展和普及,摄影作为一种艺术形式在日常生活中占据了越来越重要的地位。人们通过摄影来记录生活、分享经验,而摄影日常分享系统则成为了一个汇聚这些影像资源的大舞台。本文将详细介绍一款基于SpringBoot的摄影日常分享系统,包括其各个功能模块的设计与实现。
一、首页
首页作为摄影日常分享系统的门面,承担着展示系统特色和吸引用户关注的重任。在设计中,我们注重简洁、美观与实用性。通过轮播图的形式展示系统内的热门活动、优质作品以及最新公告,方便用户快速了解平台动态。同时,首页还设有搜索框,用户可通过关键词搜索感兴趣的内容,提高用户体验。
二、个人中心
个人中心着重于为用户提供一个个性化展示和管理的空间。用户可以在这里查看和编辑自己的个人信息,管理自己的作品、参加的活动以及发布的评论等。此外,个人中心还设有消息中心,用户可以接收系统通知,与好友聊天,增加用户间的互动。
三、管理员管理
管理员管理模块为管理员提供了一个方便快捷的管理平台,可对整个系统进行各种权限管理和运营监控。管理员可以对作品、活动、用户等进行批量操作,确保系统的正常运行。
四、用户管理
用户管理模块负责对平台用户进行管理,包括但不限于用户注册、登录、信息修改、密码找回等功能。我们采用第三方认证接口实现用户身份的认证,提高系统安全性。同时,我们还设置了积分制度,鼓励用户参与平台互动,提高用户粘性。
五、图片素材管理
图片素材管理模块允许管理员上传、删除、修改平台使用的图片素材,提供自定义分类功能,方便查找和使用。此外,该模块还能对图片进行批量处理,如批量上传、批量删除等,大大提高管理员的工作效率。
六、视频素材管理
视频素材管理模块与图片素材管理类似,但主要针对视频类素材。管理员可以上传、删除、修改平台使用的视频素材,同样也提供分类功能和批量处理功能,以方便平台运营过程中对视频类素材的管理。
七、活动管理
活动管理模块允许管理员创建、编辑和删除平台上的各类摄影活动。管理员可以设置活动的主题、时间、地点、规则以及奖项等信息,同时还可以监控活动的参与情况,便于对活动进行及时调整。
八、活动报名管理
活动报名管理模块允许用户在平台上报名参加各类摄影活动。用户可以查看活动的详细信息,选择是否参加并在规定时间内提交报名信息。管理员可以在此模块中对报名信息进行审核,确认参加者名单,保证活动的顺利进行。
九、基础数据管理
基础数据管理模块为管理员提供对平台基础数据的维护功能,包括但不限于数据字典、数据备份与恢复、数据统计等。通过该模块,管理员可以对平台数据进行有效管理和维护,保证系统的稳定性和可靠性。
十、论坛管理
论坛管理模块允许用户在平台上进行交流和讨论,分享自己的摄影经验和学习心得。管理员可以在此模块中对论坛内容进行监管和维护,确保讨论环境的有序和健康。同时,论坛管理模块还支持主题分类、置顶等功能,提高用户体验。
十一、公告资讯管理
公告资讯管理模块允许管理员发布平台的最新消息、活动通知和行业资讯等。管理员可以创建多个公告类别,设定不同的发布时间,还可以对已发布的公告进行修改和删除。用户可以在首页或个人中心查看公告资讯,及时了解平台动态。
二、开发环境
- 开发语言:Java
- 数据库:MySQL
- 系统架构:B/S
- 后端:springboot
- 前端:vue
- 工具:IDEA或者Eclipse、HBuilderX、JDK1.8、Maven
三、系统展示
登录模块:
首页模块:
管理员模块:
四、代码展示
package com.controller;
import java.text.SimpleDateFormat;
import java.util.ArrayList;
import java.util.Arrays;
import java.util.Calendar;
import java.util.Map;
import java.util.HashMap;
import java.util.Iterator;
import java.util.Date;
import java.util.List;
import javax.servlet.http.HttpServletRequest;
import com.utils.ValidatorUtils;
import org.apache.commons.lang3.StringUtils;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.format.annotation.DateTimeFormat;
import org.springframework.web.bind.annotation.PathVariable;
import org.springframework.web.bind.annotation.RequestBody;
import org.springframework.web.bind.annotation.RequestMapping;
import org.springframework.web.bind.annotation.RequestParam;
import org.springframework.web.bind.annotation.RestController;
import com.baomidou.mybatisplus.mapper.EntityWrapper;
import com.baomidou.mybatisplus.mapper.Wrapper;
import com.annotation.IgnoreAuth;
import com.entity.StoreupEntity;
import com.entity.view.StoreupView;
import com.service.StoreupService;
import com.service.TokenService;
import com.utils.PageUtils;
import com.utils.R;
import com.utils.MD5Util;
import com.utils.MPUtil;
import com.utils.CommonUtil;
/**
* 收藏表
* 后端接口
* @author
* @email
* @date 2021-03-12 20:31:07
*/
@RestController
@RequestMapping("/storeup")
public class StoreupController {
@Autowired
private StoreupService storeupService;
/**
* 后端列表
*/
@RequestMapping("/page")
public R page(@RequestParam Map<String, Object> params,StoreupEntity storeup,
HttpServletRequest request){
if(!request.getSession().getAttribute("role").toString().equals("管理员")) {
storeup.setUserid((Long)request.getSession().getAttribute("userId"));
}
EntityWrapper<StoreupEntity> ew = new EntityWrapper<StoreupEntity>();
PageUtils page = storeupService.queryPage(params, MPUtil.sort(MPUtil.between(MPUtil.likeOrEq(ew, storeup), params), params));
return R.ok().put("data", page);
}
/**
* 前端列表
*/
@RequestMapping("/list")
public R list(@RequestParam Map<String, Object> params,StoreupEntity storeup, HttpServletRequest request){
if(!request.getSession().getAttribute("role").toString().equals("管理员")) {
storeup.setUserid((Long)request.getSession().getAttribute("userId"));
}
EntityWrapper<StoreupEntity> ew = new EntityWrapper<StoreupEntity>();
PageUtils page = storeupService.queryPage(params, MPUtil.sort(MPUtil.between(MPUtil.likeOrEq(ew, storeup), params), params));
return R.ok().put("data", page);
}
/**
* 列表
*/
@RequestMapping("/lists")
public R list( StoreupEntity storeup){
EntityWrapper<StoreupEntity> ew = new EntityWrapper<StoreupEntity>();
ew.allEq(MPUtil.allEQMapPre( storeup, "storeup"));
return R.ok().put("data", storeupService.selectListView(ew));
}
/**
* 查询
*/
@RequestMapping("/query")
public R query(StoreupEntity storeup){
EntityWrapper< StoreupEntity> ew = new EntityWrapper< StoreupEntity>();
ew.allEq(MPUtil.allEQMapPre( storeup, "storeup"));
StoreupView storeupView = storeupService.selectView(ew);
return R.ok("查询收藏表成功").put("data", storeupView);
}
/**
* 后端详情
*/
@RequestMapping("/info/{id}")
public R info(@PathVariable("id") Long id){
StoreupEntity storeup = storeupService.selectById(id);
return R.ok().put("data", storeup);
}
/**
* 前端详情
*/
@RequestMapping("/detail/{id}")
public R detail(@PathVariable("id") Long id){
StoreupEntity storeup = storeupService.selectById(id);
return R.ok().put("data", storeup);
}
/**
* 后端保存
*/
@RequestMapping("/save")
public R save(@RequestBody StoreupEntity storeup, HttpServletRequest request){
storeup.setId(new Date().getTime()+new Double(Math.floor(Math.random()*1000)).longValue());
//ValidatorUtils.validateEntity(storeup);
storeup.setUserid((Long)request.getSession().getAttribute("userId"));
storeupService.insert(storeup);
return R.ok();
}
/**
* 前端保存
*/
@RequestMapping("/add")
public R add(@RequestBody StoreupEntity storeup, HttpServletRequest request){
storeup.setId(new Date().getTime()+new Double(Math.floor(Math.random()*1000)).longValue());
//ValidatorUtils.validateEntity(storeup);
storeup.setUserid((Long)request.getSession().getAttribute("userId"));
storeupService.insert(storeup);
return R.ok();
}
/**
* 修改
*/
@RequestMapping("/update")
public R update(@RequestBody StoreupEntity storeup, HttpServletRequest request){
//ValidatorUtils.validateEntity(storeup);
storeupService.updateById(storeup);//全部更新
return R.ok();
}
/**
* 删除
*/
@RequestMapping("/delete")
public R delete(@RequestBody Long[] ids){
storeupService.deleteBatchIds(Arrays.asList(ids));
return R.ok();
}
/**
* 提醒接口
*/
@RequestMapping("/remind/{columnName}/{type}")
public R remindCount(@PathVariable("columnName") String columnName, HttpServletRequest request,
@PathVariable("type") String type,@RequestParam Map<String, Object> map) {
map.put("column", columnName);
map.put("type", type);
if(type.equals("2")) {
SimpleDateFormat sdf = new SimpleDateFormat("yyyy-MM-dd");
Calendar c = Calendar.getInstance();
Date remindStartDate = null;
Date remindEndDate = null;
if(map.get("remindstart")!=null) {
Integer remindStart = Integer.parseInt(map.get("remindstart").toString());
c.setTime(new Date());
c.add(Calendar.DAY_OF_MONTH,remindStart);
remindStartDate = c.getTime();
map.put("remindstart", sdf.format(remindStartDate));
}
if(map.get("remindend")!=null) {
Integer remindEnd = Integer.parseInt(map.get("remindend").toString());
c.setTime(new Date());
c.add(Calendar.DAY_OF_MONTH,remindEnd);
remindEndDate = c.getTime();
map.put("remindend", sdf.format(remindEndDate));
}
}
Wrapper<StoreupEntity> wrapper = new EntityWrapper<StoreupEntity>();
if(map.get("remindstart")!=null) {
wrapper.ge(columnName, map.get("remindstart"));
}
if(map.get("remindend")!=null) {
wrapper.le(columnName, map.get("remindend"));
}
if(!request.getSession().getAttribute("role").toString().equals("管理员")) {
wrapper.eq("userid", (Long)request.getSession().getAttribute("userId"));
}
int count = storeupService.selectCount(wrapper);
return R.ok().put("count", count);
}
}