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





基于javaweb的SSM+Maven医院住院管理系统(java+ssm+jsp+mysql+maven)
一、项目简述
功能包括: 住院病人管理,住院病房管理,医生管理,药品管理,仪 器管理等等。
二、项目运行
环境配置: Jdk1.8 + Tomcat8.5 + mysql + Eclispe (IntelliJ IDEA,Eclispe,MyEclispe,Sts 都支持)
项目技术: JSP +Spring + SpringMVC + 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 51 52 53
| session.setAttribute("t",empName); return "personnel_list"; }
@RequestMapping(value = "/addPersonnel" ,method = RequestMethod.POST) @ResponseBody public String addPersonnel(@RequestBody Personnel personnel) { int a = personnelService.addPersonnel(personnel); return "personnel_list"; }
@RequestMapping( "/deletePersonnel") @ResponseBody public String deletePersonnel(Integer empId) { int a = personnelService.deletePersonnel(empId); return "personnel_list"; }
@RequestMapping( value = "/updatePersonnel", method = RequestMethod.POST) public String updatePersonnel(Personnel personnel) { int a = personnelService.updatePersonnel(personnel); return "redirect:/findPersonnel"; }
@RequestMapping("/findPersonnelById") public String findPersonnelById(Integer empId, HttpSession session) { Personnel pe2= personnelService.findPersonnelById(empId); session.setAttribute("pe2",pe2); return "personnel_edit"; }
@RequestMapping(value = "/exportPersonnel" , method = RequestMethod.POST) @ResponseBody public List<Personnel> exportPersonnel(){ List<Personnel> personnel = personnelService.getAll();
|
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
| model.addAttribute("po",po); session.setAttribute("u",potionNo); session.setAttribute("t",potionName); return "potion_list"; }
@RequestMapping(value = "/addPotion" ,method = RequestMethod.POST) @ResponseBody public String addPotion(@RequestBody Potion potion) { int a = potionService.addPotion(potion); return "potion_list"; }
@RequestMapping( "/deletePotion") @ResponseBody public String deletePotion(Integer potionId) { int a = potionService.deletePotion(potionId); return "potion_list"; }
@RequestMapping( value = "/updatePotion", method = RequestMethod.POST) public String updatePotion(Potion potion) { int a = potionService.updatePotion(potion); return "redirect:/findPotion"; }
@RequestMapping("/findPotionById") public String findPotionById(Integer potionId, HttpSession session) { Potion po2= potionService.findPotionById(potionId); session.setAttribute("po2",po2); return "potion_edit"; }
|
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
| public String findDeptById(Integer deptId, HttpSession session) { Dept de2= deptService.findDeptById(deptId); session.setAttribute("de2",de2); return "Dept_edit"; }
@RequestMapping(value = "/exportDeptlist" , method = RequestMethod.POST) @ResponseBody public List<Dept> exportDept(){ List<Dept> depts = deptService.getAll(); return depts; }
@RequestMapping(value = "/findDeptPersonnel") public String findClassStudent(Dept dept,Model model, HttpSession session) { List<Dept> dep = deptService.findDeptPersonnel(dept); model.addAttribute("dep",dep); return "dept_Personnellist"; }
} package com.xie.controller;
@Controller public class BedController { @Autowired private BedService bedService;
|
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
| public String login(Tms tms, Model model, HttpSession session){ tms.setTmsPswd(MD5Util.MD5EncodeUtf8(tms.getTmsPswd())); Tms ad = tmsService.findTms(tms); if(ad!=null){ session.setAttribute("ad", ad); return "homepage"; } model.addAttribute("msg", "error"); return "login"; }
@RequestMapping(value = "/loginOut") public String loginOut(Tms tms, Model model, HttpSession session) { session.invalidate(); return "login";
}
@RequestMapping(value = "/findAdmin") public String findAdmin(String tmsUser, String tmsName,Integer pageIndex , Integer pageSize, Model model,HttpSession session) { PageInfo<Tms> ai = tmsService.findPageInfo(tmsUser,tmsName, pageIndex,pageSize); model.addAttribute("ai",ai); session.setAttribute("u",tmsUser); session.setAttribute("t",tmsName); return "admin_list"; }
@RequestMapping(value = "/addAdmin" ,method = RequestMethod.POST) @ResponseBody public String addAdmin(@RequestBody Tms tms) { tms.setTmsPswd(MD5Util.MD5EncodeUtf8(tms.getTmsPswd())); int a = tmsService.addTms(tms);
|
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
| , Integer pageSize, Model model,HttpSession session){ PageInfo<Dept> de = deptService.findPageInfo(deptNo,deptName, pageIndex,pageSize); model.addAttribute("de",de); session.setAttribute("u",deptNo); session.setAttribute("t",deptName); return "Dept_list"; }
@RequestMapping(value = "/addDept" ,method = RequestMethod.POST) @ResponseBody public String addDept(@RequestBody Dept dept) { int a = deptService.addDept(dept); return "Dept_list"; }
@RequestMapping( value = "/updateDept", method = RequestMethod.POST) public String updateDept(Dept dept) { int a = deptService.updateDept(dept); return "redirect:/findDept"; }
@RequestMapping("/findDeptById") public String findDeptById(Integer deptId, HttpSession session) { Dept de2= deptService.findDeptById(deptId); session.setAttribute("de2",de2); return "Dept_edit"; }
@RequestMapping(value = "/exportDeptlist" , method = RequestMethod.POST) @ResponseBody public List<Dept> exportDept(){ List<Dept> depts = deptService.getAll(); return depts; }
|
——————————PayStart——————————
项目链接:
https://javayms.github.io?id=221422272105200at
https://javayms.pages.dev?id=221422272105200at