——————————DescriptionStart——————————
运行环境
Java≥8、MySQL≥5.7
开发工具
eclipse/idea/myeclipse/sts等均可配置运行
适用
课程设计,大作业,毕业设计,项目练习,学习演示等
功能说明






基于javaweb的SpringBoot田径运动会管理系统(java+springboot+thymeleaf+html+maven+mysql)
项目介绍
本项目分为管理员、学生两种角色, 管理员主要功能包括: 功能:登录、查看个人资料、修改密码、选手管理、赛事管理、报名管理、成绩管理、开幕式管理、闭幕式管理 学生主要功能包括: 首页, 项目管理:报名项目、查看已报名项目; 成绩查询:单个项目查询、总成绩查询、个人总积分查询; 查看开幕式; 查看闭幕式; 个人资料:查看个人资料、修改密码;
环境需要
1.运行环境:最好是java jdk 1.8,我们在这个平台上运行的。其他版本理论上也可以。
2.IDE环境:IDEA,Eclipse,Myeclipse都可以。推荐IDEA;
3.硬件环境:windows 7/8/10 1G内存以上;或者 Mac OS;
4.数据库:MySql 8.0版本;
5.是否Maven项目:是;
技术栈
后端:SpringBoot
前端:Thymeleaf+HTML+CSS+jQuery
使用说明
运行项目,输入localhost:8080/
管理员账号/密码:10001/123456
学生账号/密码:1001/123456
——————————CodeStart——————————
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
| model.addAttribute("referee",referee); return "admin/sports-add"; } @RequestMapping("/admin/addSports") @ResponseBody public Msg addStu(Sports sports) { sportsService.addSports(sports); return Msg.success(); }
@RequestMapping("/admin/toUpdSports/{sportsId}") public String toUpdSports(@PathVariable("sportsId")Integer sportsId , Model model) { Sports sports = sportsService.querySportsById(sportsId); model.addAttribute("sports",sports);
List referee = refereeService.queryReferee(); model.addAttribute("referee",referee);
return "admin/sports-update"; }
@RequestMapping("/admin/updSports") @ResponseBody public Msg updSports(Sports sports, Model model) { sportsService.updSports(sports); return Msg.success().add("msg","修改成功!"); }
@RequestMapping(value = "/admin/toDelSports/{sportsId}",method = RequestMethod.DELETE) @ResponseBody public Msg toDelSports(@PathVariable("sportsId") String sportsId){ int sportsId2=Integer.parseInt(sportsId); sportsService.delSportsById(sportsId2); return Msg.success().add("msg","删除成功!"); }
|
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
|
@Controller public class StudentController {
@Autowired private StudentService studentService;
public String getStu(Model model){ Collection<Student> list = studentService.queryStu(); model.addAttribute("students",list); return "admin/student-list"; }
@RequestMapping("/admin/getStu/{pn}") public String getStuWithJson(@PathVariable(value = "pn") Integer pn,Model model){ PageHelper.startPage(pn,5); List<Student> students=studentService.queryStu(); List schooltype = studentService.querySchool();
model.addAttribute("schooltype",schooltype); PageInfo page=new PageInfo(students,5); model.addAttribute("pageInfo",page); model.addAttribute("sign","getStu"); return "admin/student-list"; }
Integer id; String gender; String school; @RequestMapping("/admin/queryStuWithCondition/{pn}") public String queryStuWithCondition(@RequestParam(value = "school",required = false)String school,
|
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
| return Msg.success().add("msg","修改成功!请重新登录"); }
} package com.xhu.controller;
@Controller public class StudentController {
@Autowired private StudentService studentService;
public String getStu(Model model){ Collection<Student> list = studentService.queryStu(); model.addAttribute("students",list); return "admin/student-list"; }
@RequestMapping("/admin/getStu/{pn}") public String getStuWithJson(@PathVariable(value = "pn") Integer pn,Model model){ PageHelper.startPage(pn,5); List<Student> students=studentService.queryStu(); List schooltype = studentService.querySchool();
|
1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24
| PageInfo page=new PageInfo(score,5); model.addAttribute("pageInfo",page); model.addAttribute("sign","querySportsWithCondition"); return "admin/scoreAllBySchool";
} } package com.xhu.controller;
@Controller public class GradeController {
@Autowired GradeService gradeService; @Autowired SportsService sportsService; @Autowired StudentService studentService;
@RequestMapping("/admin/toGetScore")
|
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
| @RequestMapping("/admin/toUpdAdminPass/{adminId}") public String toUpdAdminPass(@PathVariable("adminId")Integer adminId,Model model){ model.addAttribute("adminId",adminId); return "admin/admin-pass-upd"; }
@RequestMapping("/admin/updAdminPass") @ResponseBody public Msg updAdminPass( @RequestParam("adminId")Integer adminId, @RequestParam("adminPassword")String adminPassword, @RequestParam("adminPassword2")String adminPassword2){
adminService.updAdminPass(adminPassword,adminId); return Msg.success().add("msg","修改成功!请重新登录"); }
} package com.xhu.controller;
@Controller public class StuSportsController {
@Autowired private SportsService sportsService; @Autowired private RefereeService refereeService; @Autowired private StudentService studentService; @Autowired GradeService gradeService; @Autowired CeremonyService ceremonyService;
|
——————————PayStart——————————
项目链接:
https://javayms.github.io?id=181422292105200es
https://javayms.pages.dev?id=181422292105200es