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







基于javaweb的SpringBoot宠物医院预约挂号系统(java+spring+springboot+mybatis+thymeleaf+html+layui+maven+mysql)
一、项目简述功能包括: 用户分为宠物,医生,管理员,宠物主人可进行注册选择医生挂号,选择日期,选择号源,医生可进行宠物接诊,管理员可对宠物,医生信息的维护等等功能。
二、项目运行 环境配置:
Jdk1.8 + mysql + Eclispe(IntelliJ IDEA,Eclispe,MyEclispe,Sts都支持)
项目技术:
JSP +Spring + SpringBoot + MyBatis + html+ css + JavaScript + JQuery + Ajax + layui+ maven等等
——————————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 49 50
| } model.addAttribute("sectionlist", sectionlist); model.addAttribute("sectionlist2", sectionlist2); return "doctorRegister"; }
@RequestMapping("/admin_Register") public String admin_Register(Admin admin,Model model) { int insertSelective = adminService.insertSelective(admin); model.addAttribute("type",2); return "login"; }
@RequestMapping("/verificatio") public String verificatio(String username, String password, Integer type, HttpServletRequest request,Model model) { HttpSession session = request.getSession(); session.setAttribute("type",type); if(type == 1){ Doctor doctor = new Doctor(); doctor.setUsername(username); doctor.setPasswoed(password); List<Doctor> doctorlist = doctorService.selectDoctor(doctor); if(doctorlist.size() <= 0){ model.addAttribute("message","密码错误"); model.addAttribute("type",type); return "login"; } session.setAttribute("DOCTOR",doctorlist.get(0)); return "redirect:/doctor/index"; } if(type == 3){ Patient patient = new Patient(); patient.setUsername(username); patient.setPassword(password); List<Patient> list = patientService.selectPatient(patient);
|
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
| } return "behind/admin/commentList"; }
* * 评论删除 * @return * @RequestMapping("/commentDel") public String commentDel(Model model,Integer id) { if(id != null){ commentService.deleteByPrimaryKey(id);
} return "redirect:/admin/commentList"; }
* *审核 * @return * @RequestMapping("/merchantList") public String merchantList(Model model,Integer id) { Merchant merchant = new Merchant(); merchant.setState(0); List<Merchant> merchantlist = merchantService.selectMerchant(merchant); model.addAttribute("merchantlist",merchantlist); return "behind/admin/merchantList"; } * *通过 * @return * @RequestMapping("/merchanUpate") public String merchanUpate(Model model,Integer id) { Merchant merchant = new Merchant(); if(id != null){ merchant.setId(id); merchant.setState(1); merchantService.updateByPrimaryKeySelective(merchant); } return "redirect:/admin/merchantList";
} * *未通过 * @return * @RequestMapping("/merchanDel") public String merchanDel(Model model,Integer id) { if(id != null){ merchantService.deleteByPrimaryKey(id);
|
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
| return "redirect:/login/index"; } messages.setType(type); PageInfo<Messages> pageInfo = messagesService.selectMessagesList(messages,page,size); messages.setTime(new Date()); List<Messages> list = messagesService.selectMessagesPai(messages); model.addAttribute("mlist",list); model.addAttribute("messagesList",pageInfo.getList()); model.addAttribute("pageInfo",pageInfo); model.addAttribute("messages",messages); model.addAttribute("type",type); return "doctor/messageList"; }
@RequestMapping(value = "/messageAjax") @ResponseBody public List<Messages> doctorList(HttpServletRequest request) { Messages messages = new Messages(); HttpSession session = request.getSession(); Doctor dt = (Doctor) session.getAttribute("DOCTOR"); messages.setDid(dt.getId()); messages.setType(1); messages.setTime(new Date()); PageInfo<Messages> pageInfo2 = messagesService.selectMessagesListDemo(messages,1,99); return pageInfo2.getList(); }
@RequestMapping(value = "/messagesQundingUptate") @ResponseBody public String messagesQundingUptate(Integer id) { if(id != null) { Messages messages = new Messages(); messages.setId(id); messages.setType(3); messagesService.updateByPrimaryKeySelective(messages); Messages selectByPrimaryKey = messagesService.selectByPrimaryKey(id); Messages mes = new Messages(); mes.setType(1); mes.setTime(new Date()); mes.setDid(selectByPrimaryKey.getDid()); List<Messages> list = messagesService.selectMessagesPai(mes); for (int i = 0; i < list.size(); i++) {
|
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
| section.setType(2); sectionlist2 = sectionService.selectByExample(section); } model.addAttribute("sectionlist", sectionlist); model.addAttribute("sectionlist2", sectionlist2); return "admin/doctorAdd"; }
@RequestMapping("/admindoctorAdd") public String admindoctorAdd(Doctor doctor,Model model) { if(doctor.getId() != null){ if(doctor.getSid() != null) { Section selectByPrimaryKey = sectionService.selectByPrimaryKey(doctor.getSid()); doctor.setSname(selectByPrimaryKey.getName()); } doctorService.updateByPrimaryKeySelective(doctor); } return "redirect:/admin/doctorList"; }
@RequestMapping("/doctorList") public String doctorList(Model model, Doctor doctor, @RequestParam(value="page",defaultValue="1")Integer page) { if(doctor == null) { doctor = new Doctor(); } PageInfo<Doctor> pageInfo = doctorService.selectDoctorList(doctor,page,size); List<Doctor> list = pageInfo.getList(); model.addAttribute("doctorList",pageInfo.getList()); model.addAttribute("pageInfo",pageInfo); model.addAttribute("doctor",doctor); return "admin/doctorList"; }
|
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
|
@RequestMapping("/admindoctorUptate") public String adminUptatePassword(Doctor doctor,Model model) { if(doctor != null && doctor.getId() != null) { if(doctor.getSid() != null) { Section section = sectionService.selectByPrimaryKey(doctor.getSid()); doctor.setSid(section.getId()); doctor.setSname(section.getName()); } doctorService.updateByPrimaryKeySelective(doctor); } return "redirect:/admin/doctorList"; }
@RequestMapping("/doctorDelect") public String doctorDelect(Integer id,Model model) { if(id != null) { doctorService.deleteByPrimaryKey(id); } return "redirect:/admin/doctorList"; }
@RequestMapping("/doctorAddPage") public String doctorAddPage(Model model) { List<Section> sectionlist2 = null; Section se = new Section(); se.setType(1); List<Section> sectionlist = sectionService.selectByExample(se); if(sectionlist.size() > 0 ) { Section section = new Section(); section.setPid(sectionlist.get(0).getId()); section.setType(2); sectionlist2 = sectionService.selectByExample(section);
|
——————————PayStart——————————
项目链接:
https://javayms.github.io?id=261422312105200if
https://javayms.pages.dev?id=261422312105200if