博主介绍:✌从事软件开发10年之余,专注于Java技术领域、Python人工智能及数据挖掘、小程序项目开发和Android项目开发等。CSDN、掘金、华为云、InfoQ、阿里云等平台优质作者✌
文末获取源码联系
精彩专栏推荐订阅 不然下次找不到哟
————————————————
计算机毕业设计《1000套》✌
目录
1、项目介绍及开发技术
1.1 项目介绍
1.2 开发技术
2、系统功能设计结构图
3、功能截图
3.1 前台功能
3.2后台功能
3.2.1管理员模块
3.2.2教师模块
3.2.3学生模块
4、数据库表结构设计
5、关键代码
5.1 学生学籍管理Controller模块
5.2 学生学籍管理Service模块
5.3 学生学籍管理ServiceImpl模块
5.4 学生学籍管理Dao模块
6、论文目录结构
7、源码获取
1、项目介绍及开发技术
对在线学籍管理的流程进行科学整理、归纳和功能的精简,通过软件工程的研究方法,结合当下流行的互联网技术,最终设计并实现了一个简单、易操作的在线学籍管理系统。内容包括系统的设计思路、系统模块和实现方法。系统使用过程主要涉及到管理员、教师和学生三种角色,主要包含系统首页、个人中心、学生管理、教师管理、院校管理、专业管理、班级信息管理、课程信息管理、学生成绩管理、学生学籍管理等功能。
Java开发语言、SpringBoot、MyBatisPlus、MySQL数据库、Maven、IDEA开发工具、JDK1.8+、Vue、HTML、CSS、JS。
2、系统功能设计结构图
3、功能截图
系统用户登录,在登录页面选择需要登录的角色,在正确输入用户名和密码后,进入操作系统进行操作。
管理员进入主页面,主要功能包括对首页、个人中心、学生管理、教师管理、院校管理、专业管理、班级信息管理、课程信息管理、学生成绩管理、学生学籍管理等进行相应操作。
管理员点击学生管理。在学生页面输入学号和学生姓名进行查询学生列表,并根据需要对学生详情信息进行详情、修改或删除操作。
管理员点击教师管理。在教师页面输入教师工号和教师姓名进行查询教师列表,并根据需要对教师详情信息进行详情、修改或删除操作。
管理员点击院校管理。在院校页面输入院校进行查询院校列表,并根据需要对院校详情信息进行详情、修改或删除操作。
管理员点击专业管理。在专业页面输入专业进行查询专业列表,并根据需要对专业详情信息进行详情、修改或删除操作。
管理员点击班级信息管理。在班级信息页面输入班级名称、院校和选择专业进行查询班级信息列表,并根据需要对班级详情信息进行详情、修改或删除操作。
管理员点击课程信息管理。在课程信息页面输入课程名称、班级和专业进行查询课程信息列表,并根据需要对课程详情信息进行详情、修改或删除操作。
管理员点击学生成绩管理。在学生成绩页面输入课程名称和学生姓名进行查询学生成绩列表,并根据需要对学生成绩详情信息进行详情、修改或删除操作。
管理员点击学生学籍管理。在学生学籍页面输入学号和学生姓名进行查询学生学籍列表,并根据需要对学生学籍详情信息进行详情、修改或删除操作。
教师进入主页面,主要功能包括对首页、个人中心、班级信息管理、课程信息管理、学生成绩管理、学生学籍管理等进行操作。
教师点击班级信息管理。在班级信息页面输入班级名称、院校和选择专业进行查询班级信息列表,并根据需要对班级详情信息进行详情操作。
教师点击课程信息管理。在课程信息页面输入课程名称、班级和选择专业进行查询或删除课程信息列表,并根据需要对课程详情信息进行详情操作。
学生进入主页面,主要功能包括对首页、个人中心、课程信息管理、学生成绩管理等进行操作。
学生点击课程信息管理。在课程信息页面输入课程名称、班级和选择专业进行查询课程信息列表,并根据需要对课程详情信息进行详情操作。
4、数据库表结构设计
CREATE DATABASE /*!32312 IF NOT EXISTS*/ `springboott17xx` /*!40100 DEFAULT CHARACTER SET utf8mb4 */;
USE `springboott17xx`;
--
-- Table structure for table `banjixinxi`
--
DROP TABLE IF EXISTS `banjixinxi`;
/*!40101 SET @saved_cs_client = @@character_set_client */;
/*!40101 SET character_set_client = utf8 */;
CREATE TABLE `banjixinxi` (
`id` bigint(20) NOT NULL AUTO_INCREMENT COMMENT '主键',
`addtime` timestamp NOT NULL DEFAULT CURRENT_TIMESTAMP COMMENT '创建时间',
`banjimingcheng` varchar(200) NOT NULL COMMENT '班级名称',
`banjirenshu` varchar(200) DEFAULT NULL COMMENT '班级人数',
`yuanxiao` varchar(200) NOT NULL COMMENT '院校',
`zhuanye` varchar(200) NOT NULL COMMENT '专业',
`jiaoshigonghao` varchar(200) NOT NULL COMMENT '教师工号',
`jiaoshixingming` varchar(200) DEFAULT NULL COMMENT '教师姓名',
PRIMARY KEY (`id`)
) ENGINE=InnoDB AUTO_INCREMENT=59 DEFAULT CHARSET=utf8 COMMENT='班级信息';
/*!40101 SET character_set_client = @saved_cs_client */;
--
-- Dumping data for table `banjixinxi`
--
LOCK TABLES `banjixinxi` WRITE;
/*!40000 ALTER TABLE `banjixinxi` DISABLE KEYS */;
INSERT INTO `banjixinxi` VALUES (51,'2023-02-15 02:46:56','班级名称1','班级人数1','院校1','专业1','教师工号1','教师姓名1'),(52,'2023-02-15 02:46:56','班级名称2','班级人数2','院校2','专业2','教师工号2','教师姓名2'),(53,'2023-02-15 02:46:56','班级名称3','班级人数3','院校3','专业3','教师工号3','教师姓名3'),(54,'2023-02-15 02:46:56','班级名称4','班级人数4','院校4','专业4','教师工号4','教师姓名4'),(55,'2023-02-15 02:46:56','班级名称5','班级人数5','院校5','专业5','教师工号5','教师姓名5'),(56,'2023-02-15 02:46:56','班级名称6','班级人数6','院校6','专业6','教师工号6','教师姓名6'),(57,'2023-02-15 02:46:56','班级名称7','班级人数7','院校7','专业7','教师工号7','教师姓名7'),(58,'2023-02-15 02:46:56','班级名称8','班级人数8','院校8','专业8','教师工号8','教师姓名8');
/*!40000 ALTER TABLE `banjixinxi` ENABLE KEYS */;
UNLOCK TABLES;
--
-- Table structure for table `config`
--
DROP TABLE IF EXISTS `config`;
/*!40101 SET @saved_cs_client = @@character_set_client */;
/*!40101 SET character_set_client = utf8 */;
CREATE TABLE `config` (
`id` bigint(20) NOT NULL AUTO_INCREMENT COMMENT '主键',
`name` varchar(100) NOT NULL COMMENT '配置参数名称',
`value` varchar(100) DEFAULT NULL COMMENT '配置参数值',
PRIMARY KEY (`id`)
) ENGINE=InnoDB AUTO_INCREMENT=4 DEFAULT CHARSET=utf8 COMMENT='配置文件';
/*!40101 SET character_set_client = @saved_cs_client */;
--
-- Dumping data for table `config`
--
LOCK TABLES `config` WRITE;
/*!40000 ALTER TABLE `config` DISABLE KEYS */;
INSERT INTO `config` VALUES (1,'picture1','upload/picture1.jpg'),(2,'picture2','upload/picture2.jpg'),(3,'picture3','upload/picture3.jpg');
/*!40000 ALTER TABLE `config` ENABLE KEYS */;
UNLOCK TABLES;
--
-- Table structure for table `jiaoshi`
--
DROP TABLE IF EXISTS `jiaoshi`;
/*!40101 SET @saved_cs_client = @@character_set_client */;
/*!40101 SET character_set_client = utf8 */;
CREATE TABLE `jiaoshi` (
`id` bigint(20) NOT NULL AUTO_INCREMENT COMMENT '主键',
`addtime` timestamp NOT NULL DEFAULT CURRENT_TIMESTAMP COMMENT '创建时间',
`jiaoshigonghao` varchar(200) NOT NULL COMMENT '教师工号',
`mima` varchar(200) NOT NULL COMMENT '密码',
`touxiang` longtext COMMENT '头像',
`jiaoshixingming` varchar(200) NOT NULL COMMENT '教师姓名',
`xingbie` varchar(200) DEFAULT NULL COMMENT '性别',
`lianxidianhua` varchar(200) DEFAULT NULL COMMENT '联系电话',
`youxiang` varchar(200) DEFAULT NULL COMMENT '邮箱',
PRIMARY KEY (`id`),
UNIQUE KEY `jiaoshigonghao` (`jiaoshigonghao`)
) ENGINE=InnoDB AUTO_INCREMENT=29 DEFAULT CHARSET=utf8 COMMENT='教师';
/*!40101 SET character_set_client = @saved_cs_client */;
--
-- Dumping data for table `jiaoshi`
--
LOCK TABLES `jiaoshi` WRITE;
/*!40000 ALTER TABLE `jiaoshi` DISABLE KEYS */;
INSERT INTO `jiaoshi` VALUES (21,'2023-02-15 02:46:56','教师工号1','123456','upload/jiaoshi_touxiang1.jpg','教师姓名1','男','13823888881','[email protected]'),(22,'2023-02-15 02:46:56','教师工号2','123456','upload/jiaoshi_touxiang2.jpg','教师姓名2','男','13823888882','[email protected]'),(23,'2023-02-15 02:46:56','教师工号3','123456','upload/jiaoshi_touxiang3.jpg','教师姓名3','男','13823888883','[email protected]'),(24,'2023-02-15 02:46:56','教师工号4','123456','upload/jiaoshi_touxiang4.jpg','教师姓名4','男','13823888884','[email protected]'),(25,'2023-02-15 02:46:56','教师工号5','123456','upload/jiaoshi_touxiang5.jpg','教师姓名5','男','13823888885','[email protected]'),(26,'2023-02-15 02:46:56','教师工号6','123456','upload/jiaoshi_touxiang6.jpg','教师姓名6','男','13823888886','[email protected]'),(27,'2023-02-15 02:46:56','教师工号7','123456','upload/jiaoshi_touxiang7.jpg','教师姓名7','男','13823888887','[email protected]'),(28,'2023-02-15 02:46:56','教师工号8','123456','upload/jiaoshi_touxiang8.jpg','教师姓名8','男','13823888888','[email protected]');
/*!40000 ALTER TABLE `jiaoshi` ENABLE KEYS */;
UNLOCK TABLES;
--
-- Table structure for table `kechengxinxi`
--
DROP TABLE IF EXISTS `kechengxinxi`;
/*!40101 SET @saved_cs_client = @@character_set_client */;
/*!40101 SET character_set_client = utf8 */;
CREATE TABLE `kechengxinxi` (
`id` bigint(20) NOT NULL AUTO_INCREMENT COMMENT '主键',
`addtime` timestamp NOT NULL DEFAULT CURRENT_TIMESTAMP COMMENT '创建时间',
`kechengmingcheng` varchar(200) NOT NULL COMMENT '课程名称',
`fengmian` longtext COMMENT '封面',
`keshi` varchar(200) DEFAULT NULL COMMENT '课时',
`banji` varchar(200) NOT NULL COMMENT '班级',
`zhuanye` varchar(200) NOT NULL COMMENT '专业',
`shangkedidian` varchar(200) NOT NULL COMMENT '上课地点',
`shangkeshijian` longtext NOT NULL COMMENT '上课时间',
`xueqi` varchar(200) NOT NULL COMMENT '学期',
`nianxian` varchar(200) NOT NULL COMMENT '年限',
`kechengxiangqing` longtext COMMENT '课程详情',
`jiaoshigonghao` varchar(200) NOT NULL COMMENT '教师工号',
`jiaoshixingming` varchar(200) DEFAULT NULL COMMENT '教师姓名',
PRIMARY KEY (`id`)
) ENGINE=InnoDB AUTO_INCREMENT=69 DEFAULT CHARSET=utf8 COMMENT='课程信息';
/*!40101 SET character_set_client = @saved_cs_client */;
--
-- Dumping data for table `kechengxinxi`
--
LOCK TABLES `kechengxinxi` WRITE;
/*!40000 ALTER TABLE `kechengxinxi` DISABLE KEYS */;
INSERT INTO `kechengxinxi` VALUES (61,'2023-02-15 02:46:56','课程名称1','upload/kechengxinxi_fengmian1.jpg,upload/kechengxinxi_fengmian2.jpg,upload/kechengxinxi_fengmian3.jpg','课时1','班级1','专业1','上课地点1','上课时间1','上学期','年限1','课程详情1','教师工号1','教师姓名1'),(62,'2023-02-15 02:46:56','课程名称2','upload/kechengxinxi_fengmian2.jpg,upload/kechengxinxi_fengmian3.jpg,upload/kechengxinxi_fengmian4.jpg','课时2','班级2','专业2','上课地点2','上课时间2','上学期','年限2','课程详情2','教师工号2','教师姓名2'),(63,'2023-02-15 02:46:56','课程名称3','upload/kechengxinxi_fengmian3.jpg,upload/kechengxinxi_fengmian4.jpg,upload/kechengxinxi_fengmian5.jpg','课时3','班级3','专业3','上课地点3','上课时间3','上学期','年限3','课程详情3','教师工号3','教师姓名3'),(64,'2023-02-15 02:46:56','课程名称4','upload/kechengxinxi_fengmian4.jpg,upload/kechengxinxi_fengmian5.jpg,upload/kechengxinxi_fengmian6.jpg','课时4','班级4','专业4','上课地点4','上课时间4','上学期','年限4','课程详情4','教师工号4','教师姓名4'),(65,'2023-02-15 02:46:56','课程名称5','upload/kechengxinxi_fengmian5.jpg,upload/kechengxinxi_fengmian6.jpg,upload/kechengxinxi_fengmian7.jpg','课时5','班级5','专业5','上课地点5','上课时间5','上学期','年限5','课程详情5','教师工号5','教师姓名5'),(66,'2023-02-15 02:46:56','课程名称6','upload/kechengxinxi_fengmian6.jpg,upload/kechengxinxi_fengmian7.jpg,upload/kechengxinxi_fengmian8.jpg','课时6','班级6','专业6','上课地点6','上课时间6','上学期','年限6','课程详情6','教师工号6','教师姓名6'),(67,'2023-02-15 02:46:56','课程名称7','upload/kechengxinxi_fengmian7.jpg,upload/kechengxinxi_fengmian8.jpg,upload/kechengxinxi_fengmian9.jpg','课时7','班级7','专业7','上课地点7','上课时间7','上学期','年限7','课程详情7','教师工号7','教师姓名7'),(68,'2023-02-15 02:46:56','课程名称8','upload/kechengxinxi_fengmian8.jpg,upload/kechengxinxi_fengmian9.jpg,upload/kechengxinxi_fengmian10.jpg','课时8','班级8','专业8','上课地点8','上课时间8','上学期','年限8','课程详情8','教师工号8','教师姓名8');
/*!40000 ALTER TABLE `kechengxinxi` ENABLE KEYS */;
UNLOCK TABLES;
--
-- Table structure for table `token`
--
DROP TABLE IF EXISTS `token`;
/*!40101 SET @saved_cs_client = @@character_set_client */;
/*!40101 SET character_set_client = utf8 */;
CREATE TABLE `token` (
`id` bigint(20) NOT NULL AUTO_INCREMENT COMMENT '主键',
`userid` bigint(20) NOT NULL COMMENT '用户id',
`username` varchar(100) NOT NULL COMMENT '用户名',
`tablename` varchar(100) DEFAULT NULL COMMENT '表名',
`role` varchar(100) DEFAULT NULL COMMENT '角色',
`token` varchar(200) NOT NULL COMMENT '密码',
`addtime` timestamp NOT NULL DEFAULT CURRENT_TIMESTAMP COMMENT '新增时间',
`expiratedtime` timestamp NOT NULL DEFAULT CURRENT_TIMESTAMP COMMENT '过期时间',
PRIMARY KEY (`id`)
) ENGINE=InnoDB AUTO_INCREMENT=3 DEFAULT CHARSET=utf8 COMMENT='token表';
/*!40101 SET character_set_client = @saved_cs_client */;
--
-- Dumping data for table `token`
--
LOCK TABLES `token` WRITE;
/*!40000 ALTER TABLE `token` DISABLE KEYS */;
INSERT INTO `token` VALUES (1,1,'admin','users','管理员','xagdal79en9ciqn31k759r248211m3so','2023-02-15 02:48:05','2023-02-15 03:48:06'),(2,28,'教师工号8','jiaoshi','教师','f8ft77a95wjif262z6kpx42lnbpfgkwb','2023-02-15 02:49:09','2023-02-15 03:49:10');
/*!40000 ALTER TABLE `token` ENABLE KEYS */;
UNLOCK TABLES;
--
-- Table structure for table `users`
--
DROP TABLE IF EXISTS `users`;
/*!40101 SET @saved_cs_client = @@character_set_client */;
/*!40101 SET character_set_client = utf8 */;
CREATE TABLE `users` (
`id` bigint(20) NOT NULL AUTO_INCREMENT COMMENT '主键',
`username` varchar(100) NOT NULL COMMENT '用户名',
`password` varchar(100) NOT NULL COMMENT '密码',
`role` varchar(100) DEFAULT '管理员' COMMENT '角色',
`addtime` timestamp NOT NULL DEFAULT CURRENT_TIMESTAMP COMMENT '新增时间',
PRIMARY KEY (`id`)
) ENGINE=InnoDB AUTO_INCREMENT=2 DEFAULT CHARSET=utf8 COMMENT='用户表';
/*!40101 SET character_set_client = @saved_cs_client */;
--
-- Dumping data for table `users`
--
LOCK TABLES `users` WRITE;
/*!40000 ALTER TABLE `users` DISABLE KEYS */;
INSERT INTO `users` VALUES (1,'admin','admin','管理员','2023-02-15 02:46:56');
/*!40000 ALTER TABLE `users` ENABLE KEYS */;
UNLOCK TABLES;
--
-- Table structure for table `xuesheng`
--
DROP TABLE IF EXISTS `xuesheng`;
/*!40101 SET @saved_cs_client = @@character_set_client */;
/*!40101 SET character_set_client = utf8 */;
CREATE TABLE `xuesheng` (
`id` bigint(20) NOT NULL AUTO_INCREMENT COMMENT '主键',
`addtime` timestamp NOT NULL DEFAULT CURRENT_TIMESTAMP COMMENT '创建时间',
`xuehao` varchar(200) NOT NULL COMMENT '学号',
`mima` varchar(200) NOT NULL COMMENT '密码',
`xueshengxingming` varchar(200) NOT NULL COMMENT '学生姓名',
`touxiang` longtext COMMENT '头像',
`xingbie` varchar(200) DEFAULT NULL COMMENT '性别',
`shoujihaoma` varchar(200) DEFAULT NULL COMMENT '手机号码',
`jiguan` varchar(200) DEFAULT NULL COMMENT '籍贯',
`zhuzhi` varchar(200) DEFAULT NULL COMMENT '住址',
`banji` varchar(200) DEFAULT NULL COMMENT '班级',
`zhuanye` varchar(200) DEFAULT NULL COMMENT '专业',
PRIMARY KEY (`id`),
UNIQUE KEY `xuehao` (`xuehao`)
) ENGINE=InnoDB AUTO_INCREMENT=19 DEFAULT CHARSET=utf8 COMMENT='学生';
/*!40101 SET character_set_client = @saved_cs_client */;
--
-- Dumping data for table `xuesheng`
--
LOCK TABLES `xuesheng` WRITE;
/*!40000 ALTER TABLE `xuesheng` DISABLE KEYS */;
INSERT INTO `xuesheng` VALUES (11,'2023-02-15 02:46:56','学号1','123456','学生姓名1','upload/xuesheng_touxiang1.jpg','男','13823888881','籍贯1','住址1','班级1','专业1'),(12,'2023-02-15 02:46:56','学号2','123456','学生姓名2','upload/xuesheng_touxiang2.jpg','男','13823888882','籍贯2','住址2','班级2','专业2'),(13,'2023-02-15 02:46:56','学号3','123456','学生姓名3','upload/xuesheng_touxiang3.jpg','男','13823888883','籍贯3','住址3','班级3','专业3'),(14,'2023-02-15 02:46:56','学号4','123456','学生姓名4','upload/xuesheng_touxiang4.jpg','男','13823888884','籍贯4','住址4','班级4','专业4'),(15,'2023-02-15 02:46:56','学号5','123456','学生姓名5','upload/xuesheng_touxiang5.jpg','男','13823888885','籍贯5','住址5','班级5','专业5'),(16,'2023-02-15 02:46:56','学号6','123456','学生姓名6','upload/xuesheng_touxiang6.jpg','男','13823888886','籍贯6','住址6','班级6','专业6'),(17,'2023-02-15 02:46:56','学号7','123456','学生姓名7','upload/xuesheng_touxiang7.jpg','男','13823888887','籍贯7','住址7','班级7','专业7'),(18,'2023-02-15 02:46:56','学号8','123456','学生姓名8','upload/xuesheng_touxiang8.jpg','男','13823888888','籍贯8','住址8','班级8','专业8');
/*!40000 ALTER TABLE `xuesheng` ENABLE KEYS */;
UNLOCK TABLES;
--
-- Table structure for table `xueshengchengji`
--
DROP TABLE IF EXISTS `xueshengchengji`;
/*!40101 SET @saved_cs_client = @@character_set_client */;
/*!40101 SET character_set_client = utf8 */;
CREATE TABLE `xueshengchengji` (
`id` bigint(20) NOT NULL AUTO_INCREMENT COMMENT '主键',
`addtime` timestamp NOT NULL DEFAULT CURRENT_TIMESTAMP COMMENT '创建时间',
`kechengmingcheng` varchar(200) NOT NULL COMMENT '课程名称',
`xueqi` varchar(200) DEFAULT NULL COMMENT '学期',
`nianxian` varchar(200) DEFAULT NULL COMMENT '年限',
`chengji` float NOT NULL COMMENT '成绩',
`xuehao` varchar(200) NOT NULL COMMENT '学号',
`xueshengxingming` varchar(200) DEFAULT NULL COMMENT '学生姓名',
`jiaoshigonghao` varchar(200) DEFAULT NULL COMMENT '教师工号',
`jiaoshixingming` varchar(200) DEFAULT NULL COMMENT '教师姓名',
PRIMARY KEY (`id`)
) ENGINE=InnoDB AUTO_INCREMENT=79 DEFAULT CHARSET=utf8 COMMENT='学生成绩';
/*!40101 SET character_set_client = @saved_cs_client */;
--
-- Dumping data for table `xueshengchengji`
--
LOCK TABLES `xueshengchengji` WRITE;
/*!40000 ALTER TABLE `xueshengchengji` DISABLE KEYS */;
INSERT INTO `xueshengchengji` VALUES (71,'2023-02-15 02:46:56','课程名称1','学期1','年限1',1,'学号1','学生姓名1','教师工号1','教师姓名1'),(72,'2023-02-15 02:46:56','课程名称2','学期2','年限2',2,'学号2','学生姓名2','教师工号2','教师姓名2'),(73,'2023-02-15 02:46:56','课程名称3','学期3','年限3',3,'学号3','学生姓名3','教师工号3','教师姓名3'),(74,'2023-02-15 02:46:56','课程名称4','学期4','年限4',4,'学号4','学生姓名4','教师工号4','教师姓名4'),(75,'2023-02-15 02:46:56','课程名称5','学期5','年限5',5,'学号5','学生姓名5','教师工号5','教师姓名5'),(76,'2023-02-15 02:46:56','课程名称6','学期6','年限6',6,'学号6','学生姓名6','教师工号6','教师姓名6'),(77,'2023-02-15 02:46:56','课程名称7','学期7','年限7',7,'学号7','学生姓名7','教师工号7','教师姓名7'),(78,'2023-02-15 02:46:56','课程名称8','学期8','年限8',8,'学号8','学生姓名8','教师工号8','教师姓名8');
/*!40000 ALTER TABLE `xueshengchengji` ENABLE KEYS */;
UNLOCK TABLES;
--
-- Table structure for table `xueshengxueji`
--
DROP TABLE IF EXISTS `xueshengxueji`;
/*!40101 SET @saved_cs_client = @@character_set_client */;
/*!40101 SET character_set_client = utf8 */;
CREATE TABLE `xueshengxueji` (
`id` bigint(20) NOT NULL AUTO_INCREMENT COMMENT '主键',
`addtime` timestamp NOT NULL DEFAULT CURRENT_TIMESTAMP COMMENT '创建时间',
`xuehao` varchar(200) NOT NULL COMMENT '学号',
`xueshengxingming` varchar(200) DEFAULT NULL COMMENT '学生姓名',
`xingbie` varchar(200) DEFAULT NULL COMMENT '性别',
`banji` varchar(200) DEFAULT NULL COMMENT '班级',
`zhuanye` varchar(200) DEFAULT NULL COMMENT '专业',
`shoujihaoma` varchar(200) DEFAULT NULL COMMENT '手机号码',
`zhuzhi` varchar(200) DEFAULT NULL COMMENT '住址',
`jiguan` varchar(200) DEFAULT NULL COMMENT '籍贯',
`zhengzhimianmao` varchar(200) NOT NULL COMMENT '政治面貌',
`ruxueriqi` date NOT NULL COMMENT '入学日期',
`danganwenjian` longtext COMMENT '档案文件',
`gerenjianjie` longtext COMMENT '个人简介',
`jiaoshigonghao` varchar(200) DEFAULT NULL COMMENT '教师工号',
PRIMARY KEY (`id`)
) ENGINE=InnoDB AUTO_INCREMENT=89 DEFAULT CHARSET=utf8 COMMENT='学生学籍';
/*!40101 SET character_set_client = @saved_cs_client */;
--
-- Dumping data for table `xueshengxueji`
--
LOCK TABLES `xueshengxueji` WRITE;
/*!40000 ALTER TABLE `xueshengxueji` DISABLE KEYS */;
INSERT INTO `xueshengxueji` VALUES (81,'2023-02-15 02:46:56','学号1','学生姓名1','性别1','班级1','专业1','13823888881','住址1','籍贯1','政治面貌1','2023-02-15','','个人简介1','教师工号1'),(82,'2023-02-15 02:46:56','学号2','学生姓名2','性别2','班级2','专业2','13823888882','住址2','籍贯2','政治面貌2','2023-02-15','','个人简介2','教师工号2'),(83,'2023-02-15 02:46:56','学号3','学生姓名3','性别3','班级3','专业3','13823888883','住址3','籍贯3','政治面貌3','2023-02-15','','个人简介3','教师工号3'),(84,'2023-02-15 02:46:56','学号4','学生姓名4','性别4','班级4','专业4','13823888884','住址4','籍贯4','政治面貌4','2023-02-15','','个人简介4','教师工号4'),(85,'2023-02-15 02:46:56','学号5','学生姓名5','性别5','班级5','专业5','13823888885','住址5','籍贯5','政治面貌5','2023-02-15','','个人简介5','教师工号5'),(86,'2023-02-15 02:46:56','学号6','学生姓名6','性别6','班级6','专业6','13823888886','住址6','籍贯6','政治面貌6','2023-02-15','','个人简介6','教师工号6'),(87,'2023-02-15 02:46:56','学号7','学生姓名7','性别7','班级7','专业7','13823888887','住址7','籍贯7','政治面貌7','2023-02-15','','个人简介7','教师工号7'),(88,'2023-02-15 02:46:56','学号8','学生姓名8','性别8','班级8','专业8','13823888888','住址8','籍贯8','政治面貌8','2023-02-15','','个人简介8','教师工号8');
/*!40000 ALTER TABLE `xueshengxueji` ENABLE KEYS */;
UNLOCK TABLES;
--
-- Table structure for table `yuanxiao`
--
DROP TABLE IF EXISTS `yuanxiao`;
/*!40101 SET @saved_cs_client = @@character_set_client */;
/*!40101 SET character_set_client = utf8 */;
CREATE TABLE `yuanxiao` (
`id` bigint(20) NOT NULL AUTO_INCREMENT COMMENT '主键',
`addtime` timestamp NOT NULL DEFAULT CURRENT_TIMESTAMP COMMENT '创建时间',
`yuanxiao` varchar(200) DEFAULT NULL COMMENT '院校',
PRIMARY KEY (`id`)
) ENGINE=InnoDB AUTO_INCREMENT=39 DEFAULT CHARSET=utf8 COMMENT='院校';
/*!40101 SET character_set_client = @saved_cs_client */;
--
-- Dumping data for table `yuanxiao`
--
LOCK TABLES `yuanxiao` WRITE;
/*!40000 ALTER TABLE `yuanxiao` DISABLE KEYS */;
INSERT INTO `yuanxiao` VALUES (31,'2023-02-15 02:46:56','院校1'),(32,'2023-02-15 02:46:56','院校2'),(33,'2023-02-15 02:46:56','院校3'),(34,'2023-02-15 02:46:56','院校4'),(35,'2023-02-15 02:46:56','院校5'),(36,'2023-02-15 02:46:56','院校6'),(37,'2023-02-15 02:46:56','院校7'),(38,'2023-02-15 02:46:56','院校8');
/*!40000 ALTER TABLE `yuanxiao` ENABLE KEYS */;
UNLOCK TABLES;
--
-- Table structure for table `zhuanye`
--
DROP TABLE IF EXISTS `zhuanye`;
/*!40101 SET @saved_cs_client = @@character_set_client */;
/*!40101 SET character_set_client = utf8 */;
CREATE TABLE `zhuanye` (
`id` bigint(20) NOT NULL AUTO_INCREMENT COMMENT '主键',
`addtime` timestamp NOT NULL DEFAULT CURRENT_TIMESTAMP COMMENT '创建时间',
`zhuanye` varchar(200) DEFAULT NULL COMMENT '专业',
PRIMARY KEY (`id`)
) ENGINE=InnoDB AUTO_INCREMENT=49 DEFAULT CHARSET=utf8 COMMENT='专业';
/*!40101 SET character_set_client = @saved_cs_client */;
--
-- Dumping data for table `zhuanye`
--
LOCK TABLES `zhuanye` WRITE;
/*!40000 ALTER TABLE `zhuanye` DISABLE KEYS */;
INSERT INTO `zhuanye` VALUES (41,'2023-02-15 02:46:56','专业1'),(42,'2023-02-15 02:46:56','专业2'),(43,'2023-02-15 02:46:56','专业3'),(44,'2023-02-15 02:46:56','专业4'),(45,'2023-02-15 02:46:56','专业5'),(46,'2023-02-15 02:46:56','专业6'),(47,'2023-02-15 02:46:56','专业7'),(48,'2023-02-15 02:46:56','专业8');
/*!40000 ALTER TABLE `zhuanye` ENABLE KEYS */;
UNLOCK TABLES;
/*!40103 SET TIME_ZONE=@OLD_TIME_ZONE */;
/*!40101 SET SQL_MODE=@OLD_SQL_MODE */;
/*!40014 SET FOREIGN_KEY_CHECKS=@OLD_FOREIGN_KEY_CHECKS */;
/*!40014 SET UNIQUE_CHECKS=@OLD_UNIQUE_CHECKS */;
/*!40101 SET CHARACTER_SET_CLIENT=@OLD_CHARACTER_SET_CLIENT */;
/*!40101 SET CHARACTER_SET_RESULTS=@OLD_CHARACTER_SET_RESULTS */;
/*!40101 SET COLLATION_CONNECTION=@OLD_COLLATION_CONNECTION */;
/*!40111 SET SQL_NOTES=@OLD_SQL_NOTES */;
5、关键代码
package com.controller;
import java.math.BigDecimal;
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.transaction.annotation.Transactional;
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.XueshengxuejiEntity;
import com.entity.view.XueshengxuejiView;
import com.service.XueshengxuejiService;
import com.service.TokenService;
import com.utils.PageUtils;
import com.utils.R;
import com.utils.MD5Util;
import com.utils.MPUtil;
import com.utils.CommonUtil;
import java.io.IOException;
/**
* 学生学籍
* 后端接口
* @author
* @email
*/
@RestController
@RequestMapping("/xueshengxueji")
public class XueshengxuejiController {
@Autowired
private XueshengxuejiService xueshengxuejiService;
/**
* 后端列表
*/
@RequestMapping("/page")
public R page(@RequestParam Map params,XueshengxuejiEntity xueshengxueji,
HttpServletRequest request){
String tableName = request.getSession().getAttribute("tableName").toString();
if(tableName.equals("xuesheng")) {
xueshengxueji.setXuehao((String)request.getSession().getAttribute("username"));
}
if(tableName.equals("jiaoshi")) {
xueshengxueji.setJiaoshigonghao((String)request.getSession().getAttribute("username"));
}
EntityWrapper ew = new EntityWrapper();
PageUtils page = xueshengxuejiService.queryPage(params, MPUtil.sort(MPUtil.between(MPUtil.likeOrEq(ew, xueshengxueji), params), params));
return R.ok().put("data", page);
}
/**
* 前端列表
*/
@IgnoreAuth
@RequestMapping("/list")
public R list(@RequestParam Map params,XueshengxuejiEntity xueshengxueji,
HttpServletRequest request){
EntityWrapper ew = new EntityWrapper();
PageUtils page = xueshengxuejiService.queryPage(params, MPUtil.sort(MPUtil.between(MPUtil.likeOrEq(ew, xueshengxueji), params), params));
return R.ok().put("data", page);
}
/**
* 列表
*/
@RequestMapping("/lists")
public R list( XueshengxuejiEntity xueshengxueji){
EntityWrapper ew = new EntityWrapper();
ew.allEq(MPUtil.allEQMapPre( xueshengxueji, "xueshengxueji"));
return R.ok().put("data", xueshengxuejiService.selectListView(ew));
}
/**
* 查询
*/
@RequestMapping("/query")
public R query(XueshengxuejiEntity xueshengxueji){
EntityWrapper< XueshengxuejiEntity> ew = new EntityWrapper< XueshengxuejiEntity>();
ew.allEq(MPUtil.allEQMapPre( xueshengxueji, "xueshengxueji"));
XueshengxuejiView xueshengxuejiView = xueshengxuejiService.selectView(ew);
return R.ok("查询学生学籍成功").put("data", xueshengxuejiView);
}
/**
* 后端详情
*/
@RequestMapping("/info/{id}")
public R info(@PathVariable("id") Long id){
XueshengxuejiEntity xueshengxueji = xueshengxuejiService.selectById(id);
return R.ok().put("data", xueshengxueji);
}
/**
* 前端详情
*/
@IgnoreAuth
@RequestMapping("/detail/{id}")
public R detail(@PathVariable("id") Long id){
XueshengxuejiEntity xueshengxueji = xueshengxuejiService.selectById(id);
return R.ok().put("data", xueshengxueji);
}
/**
* 后端保存
*/
@RequestMapping("/save")
public R save(@RequestBody XueshengxuejiEntity xueshengxueji, HttpServletRequest request){
xueshengxueji.setId(new Date().getTime()+new Double(Math.floor(Math.random()*1000)).longValue());
//ValidatorUtils.validateEntity(xueshengxueji);
xueshengxuejiService.insert(xueshengxueji);
return R.ok();
}
/**
* 前端保存
*/
@RequestMapping("/add")
public R add(@RequestBody XueshengxuejiEntity xueshengxueji, HttpServletRequest request){
xueshengxueji.setId(new Date().getTime()+new Double(Math.floor(Math.random()*1000)).longValue());
//ValidatorUtils.validateEntity(xueshengxueji);
xueshengxuejiService.insert(xueshengxueji);
return R.ok();
}
/**
* 修改
*/
@RequestMapping("/update")
@Transactional
public R update(@RequestBody XueshengxuejiEntity xueshengxueji, HttpServletRequest request){
//ValidatorUtils.validateEntity(xueshengxueji);
xueshengxuejiService.updateById(xueshengxueji);//全部更新
return R.ok();
}
/**
* 删除
*/
@RequestMapping("/delete")
public R delete(@RequestBody Long[] ids){
xueshengxuejiService.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 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 wrapper = new EntityWrapper();
if(map.get("remindstart")!=null) {
wrapper.ge(columnName, map.get("remindstart"));
}
if(map.get("remindend")!=null) {
wrapper.le(columnName, map.get("remindend"));
}
String tableName = request.getSession().getAttribute("tableName").toString();
if(tableName.equals("xuesheng")) {
wrapper.eq("xuehao", (String)request.getSession().getAttribute("username"));
}
if(tableName.equals("jiaoshi")) {
wrapper.eq("jiaoshigonghao", (String)request.getSession().getAttribute("username"));
}
int count = xueshengxuejiService.selectCount(wrapper);
return R.ok().put("count", count);
}
}
package com.service;
import com.baomidou.mybatisplus.mapper.Wrapper;
import com.baomidou.mybatisplus.service.IService;
import com.utils.PageUtils;
import com.entity.XueshengxuejiEntity;
import java.util.List;
import java.util.Map;
import com.entity.vo.XueshengxuejiVO;
import org.apache.ibatis.annotations.Param;
import com.entity.view.XueshengxuejiView;
/**
* 学生学籍
*
* @author
* @email
*/
public interface XueshengxuejiService extends IService {
PageUtils queryPage(Map params);
List selectListVO(Wrapper wrapper);
XueshengxuejiVO selectVO(@Param("ew") Wrapper wrapper);
List selectListView(Wrapper wrapper);
XueshengxuejiView selectView(@Param("ew") Wrapper wrapper);
PageUtils queryPage(Map params,Wrapper wrapper);
}
package com.service.impl;
import org.springframework.stereotype.Service;
import java.util.Map;
import java.util.List;
import com.baomidou.mybatisplus.mapper.Wrapper;
import com.baomidou.mybatisplus.mapper.EntityWrapper;
import com.baomidou.mybatisplus.plugins.Page;
import com.baomidou.mybatisplus.service.impl.ServiceImpl;
import com.utils.PageUtils;
import com.utils.Query;
import com.dao.XueshengxuejiDao;
import com.entity.XueshengxuejiEntity;
import com.service.XueshengxuejiService;
import com.entity.vo.XueshengxuejiVO;
import com.entity.view.XueshengxuejiView;
@Service("xueshengxuejiService")
public class XueshengxuejiServiceImpl extends ServiceImpl implements XueshengxuejiService {
@Override
public PageUtils queryPage(Map params) {
Page page = this.selectPage(
new Query(params).getPage(),
new EntityWrapper()
);
return new PageUtils(page);
}
@Override
public PageUtils queryPage(Map params, Wrapper wrapper) {
Page page =new Query(params).getPage();
page.setRecords(baseMapper.selectListView(page,wrapper));
PageUtils pageUtil = new PageUtils(page);
return pageUtil;
}
@Override
public List selectListVO(Wrapper wrapper) {
return baseMapper.selectListVO(wrapper);
}
@Override
public XueshengxuejiVO selectVO(Wrapper wrapper) {
return baseMapper.selectVO(wrapper);
}
@Override
public List selectListView(Wrapper wrapper) {
return baseMapper.selectListView(wrapper);
}
@Override
public XueshengxuejiView selectView(Wrapper wrapper) {
return baseMapper.selectView(wrapper);
}
}
package com.dao;
import com.entity.XueshengxuejiEntity;
import com.baomidou.mybatisplus.mapper.BaseMapper;
import java.util.List;
import java.util.Map;
import com.baomidou.mybatisplus.mapper.Wrapper;
import com.baomidou.mybatisplus.plugins.pagination.Pagination;
import org.apache.ibatis.annotations.Param;
import com.entity.vo.XueshengxuejiVO;
import com.entity.view.XueshengxuejiView;
/**
* 学生学籍
*
* @author
* @email
*/
public interface XueshengxuejiDao extends BaseMapper {
List selectListVO(@Param("ew") Wrapper wrapper);
XueshengxuejiVO selectVO(@Param("ew") Wrapper wrapper);
List selectListView(@Param("ew") Wrapper wrapper);
List selectListView(Pagination page,@Param("ew") Wrapper wrapper);
XueshengxuejiView selectView(@Param("ew") Wrapper wrapper);
}
6、论文目录结构
7、源码获取
感谢大家的阅读,如有不懂的问题可以评论区交流或私聊!
喜欢文章可以点赞、收藏、关注、评论啦
→获取源码请私信←