• (免费分享)基于springboot,vue毕业设计管理系统


    源码获取:关注文末gongzhonghao,输入011领取下载链接
    开发工具IDEA ,数据库mysql5.7,前后端分离
    系统分学生、教师、管理员三个角色
    在这里插入图片描述

    1.学生截图
    在这里插入图片描述
    在这里插入图片描述
    在这里插入图片描述
    在这里插入图片描述
    在这里插入图片描述
    2.教师截图:
    在这里插入图片描述
    在这里插入图片描述
    在这里插入图片描述
    在这里插入图片描述
    在这里插入图片描述
    3.管理员截图:
    在这里插入图片描述
    在这里插入图片描述
    在这里插入图片描述
    在这里插入图片描述
    在这里插入图片描述

    package com.cx.controller;
    
    import com.cx.common.Result;
    import com.cx.common.ResultCode;
    import com.cx.fluentmybatis.entity.LunwenEntity;
    import com.cx.service.LunwenService;
    import io.swagger.annotations.Api;
    import io.swagger.annotations.ApiOperation;
    import lombok.extern.slf4j.Slf4j;
    import org.springframework.beans.factory.annotation.Autowired;
    import org.springframework.web.bind.annotation.*;
    
    @Slf4j
    @Api(tags = "LunwenController", description = "论文接口")
    @RequestMapping("/lunwen")
    @RestController
    public class LunwenController {
    
        @Autowired
        LunwenService lunwenService;
    
        @ApiOperation("新增论文")
        @PostMapping("/add")
        public Result addLunwen(@RequestBody LunwenEntity lunwen) {
            if (lunwenService.addLunwen(lunwen) > 0) return Result.success();
            else return Result.failure(ResultCode.INSERT_ERROR);
        }
    
        @ApiOperation("删除论文")
        @GetMapping("/remove")
        public Result removeLunwen(@RequestParam Integer id) {
            if (lunwenService.removeLunwen(id) > 0) return Result.success();
            else return Result.failure(ResultCode.DELETE_ERROR);
        }
    
        @ApiOperation("更新论文")
        @PostMapping("/update")
        public Result updateLunwen(@RequestBody LunwenEntity lunwen){
            if (lunwenService.updateLunwen(lunwen)>0) return Result.success();
            else return Result.failure(ResultCode.UPDATE_ERROR);
        }
    
        @ApiOperation("通过id获取论文")
        @GetMapping("/getById")
        public Result<LunwenEntity> getLunwenById(@RequestParam Integer id) {
            return Result.success(lunwenService.getLunwen(id));
        }
    
        @ApiOperation("通过studentid获取论文")
        @GetMapping("/getByStudentId")
        public Result<LunwenEntity> getLunwenById(@RequestParam String studentId) {
            return Result.success(lunwenService.getLunwenByStudentId(studentId));
        }
    }
    
    
    • 1
    • 2
    • 3
    • 4
    • 5
    • 6
    • 7
    • 8
    • 9
    • 10
    • 11
    • 12
    • 13
    • 14
    • 15
    • 16
    • 17
    • 18
    • 19
    • 20
    • 21
    • 22
    • 23
    • 24
    • 25
    • 26
    • 27
    • 28
    • 29
    • 30
    • 31
    • 32
    • 33
    • 34
    • 35
    • 36
    • 37
    • 38
    • 39
    • 40
    • 41
    • 42
    • 43
    • 44
    • 45
    • 46
    • 47
    • 48
    • 49
    • 50
    • 51
    • 52
    • 53
    • 54
    • 55

    package com.cx.controller;

    import cn.dev33.satoken.annotation.SaCheckLogin;
    import cn.dev33.satoken.stp.StpUtil;
    import com.cx.common.Result;
    import com.cx.fluentmybatis.entity.SessionListEntity;
    import com.cx.fluentmybatis.entity.UserEntity;
    import com.cx.service.SessionListService;
    import com.cx.service.UserService;
    import io.swagger.annotations.Api;
    import io.swagger.annotations.ApiOperation;
    import lombok.extern.slf4j.Slf4j;
    import org.springframework.beans.factory.annotation.Autowired;
    import org.springframework.web.bind.annotation.*;

    import javax.websocket.Session;
    import java.util.List;

    @Api(tags = “SessionController”,description = “聊天会话管理”)
    @RestController
    @Slf4j
    @RequestMapping(“/session”)
    public class MessageSessionListController {
    @Autowired
    private UserService userService;
    @Autowired
    private SessionListService sessionListService;

    @SaCheckLogin
    @ApiOperation(value = "根据用户ID查询已经建立会话的列表")
    @GetMapping("/sessionListsAlready")
    public Result sessionListAlready(){
        String userId=(String)StpUtil.getLoginId();
        List sessionListEntityList=sessionListService.getSessionListByUserId(userId);
        return Result.success(sessionListEntityList);
    }
    
    
    @SaCheckLogin
    @ApiOperation(value = "根据用户ID查询未建立(可以建立)会话的列表")
    @GetMapping("/sessionListsNot")
    public Result sessionListNot(){
        String userId=(String)StpUtil.getLoginId();
        List list=sessionListService.getUserIdByUserId(userId);
        list.add(userId);
        List excludeList=userService.getExcludeList(list);
        return Result.success(excludeList);
    }
    
    @ApiOperation(value = "创建一个会话记录列表")
    // 创建会话
    @SaCheckLogin
    @GetMapping("/createSessionList")
    public Result createSession(@RequestParam String toUserId,@RequestParam String toUserName){
        //互相建立session
        SessionListEntity sessionListEntity=new SessionListEntity();
        String userId=(String)StpUtil.getLoginId();
        Integer temp1=sessionListService.getIdByUser(userId,toUserId);
        if (temp1==null||temp1<=0) {
            sessionListEntity.setUserId(userId);
            sessionListEntity.setToUserId(toUserId);
            sessionListEntity.setUnReadCount(0);
            sessionListEntity.setListName(toUserName);
            sessionListService.insert(sessionListEntity);
        }
        // 判断对方和我建立会话没有? 没有也要建立
        Integer temp=sessionListService.getIdByUser(toUserId,userId);
        //如果没有建立会话
        if (temp == null || temp <= 0){
            UserEntity user = userService.getUserById(userId);
            sessionListEntity.setUserId(toUserId);
            sessionListEntity.setToUserId(userId);
            sessionListEntity.setListName(user.getUserName());
            sessionListService.insert(sessionListEntity);
        }
        temp=sessionListService.getIdByUser(userId,toUserId);
        sessionListService.getSessionListById(temp);
        return Result.success(sessionListService.getSessionListById(temp));
    }
    
    @ApiOperation(value = "删除一个聊天会话记录")
    @SaCheckLogin
    // 删除会话
    @GetMapping("/delSessionList")
    public Result delSession(@RequestParam Integer sessionListId){
        sessionListService.deleteById(sessionListId);
        return Result.success();
    }
    
    • 1
    • 2
    • 3
    • 4
    • 5
    • 6
    • 7
    • 8
    • 9
    • 10
    • 11
    • 12
    • 13
    • 14
    • 15
    • 16
    • 17
    • 18
    • 19
    • 20
    • 21
    • 22
    • 23
    • 24
    • 25
    • 26
    • 27
    • 28
    • 29
    • 30
    • 31
    • 32
    • 33
    • 34
    • 35
    • 36
    • 37
    • 38
    • 39
    • 40
    • 41
    • 42
    • 43
    • 44
    • 45
    • 46
    • 47
    • 48
    • 49
    • 50
    • 51
    • 52
    • 53
    • 54
    • 55
    • 56
    • 57
    • 58
    • 59
    • 60

    }

  • 相关阅读:
    第十章-项目沟通管理
    MapReduce Shuffle源码解读
    【AI大模型】李彦宏从“卷模型”到“卷应用”的深度解析:卷用户场景卷能给用户解决什么问题
    【KAWAKO】从mac上定时将腾讯云的数据备份到本地
    MySQL中组合索引需要满足最左匹配原则?
    微信小程序开发之后台数据交互及wxs应用
    删除vxe-table右上角的工具栏
    [Windows环境]nvm工具的介绍和安装
    MST2513A 双USB充电器端口控制器
    51单片机-LED实验
  • 原文地址:https://blog.csdn.net/qq_35334787/article/details/127913997