Java项目:医院分诊管理系统(java+SSM+jsp+HTML+JavaScript+mysql)

本文档详细介绍了医院管理系统的管理员功能,包括登录、用户、患者、挂号、科室及分诊管理。涉及的技术栈有Spring、Mybatis等,以及数据库MySQL。提供了环境配置、使用步骤和关键控制器操作,如添加、修改和删除患者信息。

源码获取:俺的博客首页 "资源" 里下载!

项目介绍

管理员角色包含以下功能:
管理员登录,用户管理,患者管理,挂号管理,科室管理,分诊叫号管理等功能。

环境需要

1.运行环境:最好是java jdk 1.8,我们在这个平台上运行的。其他版本理论上也可以。
2.IDE环境:IDEA,Eclipse,Myeclipse都可以。推荐IDEA;
3.tomcat环境:Tomcat 7.x,8.x,9.x版本均可
4.硬件环境:windows 7/8/10 1G内存以上;或者 Mac OS; 
5.数据库:MySql 5.7版本;


技术栈

1. 后端:Spring+SpringMVC+Mybatis
2. 前端:HTML+CSS+JavaScript+jsp


使用说明

1. 使用Navicat或者其它工具,在mysql中创建对应名称的数据库,并导入项目的sql文件;
2. 使用IDEA/Eclipse/MyEclipse导入项目,Eclipse/MyEclipse导入时,若为maven项目请选择maven;
若为maven项目,导入成功后请执行maven clean;maven install命令,然后运行;
3. 将项目中application.yml配置文件中的数据库配置改为自己的配置;
4. 运行项目,输入localhost:8080/ 登录

 

 

 

 

 

 

患者管理控制层:

@Controller
public class PatientController {
    @Autowired
    PatientService patientService;
    @Autowired
    DoctorService doctorService;
    @Autowired
    AppointmentService appointmentService;
    @Autowired
    HospitalizationService hospitalizationService;
    @Autowired
    MedicalhistoryService medicalhistoryService;
    @RequestMapping("/admin/patientManage")
    public String patientlist(HttpServletRequest request,@RequestParam(value="name",required = false) String name,@RequestParam(value="certId",required = false) String certId){
        request.setAttribute("patients",patientService.getAllPatients(name,certId));
        return "admin/patientManage";
    }
    @RequestMapping(value = "/admin/patient/{id}",method = RequestMethod.DELETE)
    @ResponseBody
    public JSONObject delPatient(@PathVariable Integer id){
        JSONObject json=new JSONObject();
        json.put("message",patientService.delPatient(id));
        return json;
    }
    @RequestMapping(value = "/admin/patient/{id}",method = RequestMethod.GET)
    public String patientInfo(@PathVariable Integer id,HttpServletRequest request){
        request.setAttribute("patient",patientService.getPatient(id));
        request.setAttribute("appointments",appointmentService.getPatientMessage(id));
        request.setAttribute("hospitalizations",hospitalizationService.getPatientMessage(id));
        request.setAttribute("doctors",doctorService.getAllDoctor());
        return "admin/info/patientinfo";
    }
    @RequestMapping(value = "/admin/patientAdd",method = RequestMethod.GET)
    public String patientAddPage(){
        return "admin/add/patientadd";
    }
    @RequestMapping(value = "/admin/patient",method = RequestMethod.PUT)
    @ResponseBody
    public JSONObject patientInfo(@RequestBody Patient patient){
        JSONObject json=new JSONObject();
        json.put("message",patientService.updatePatient(patient));
        return json;
    }
    @RequestMapping(value = "/admin/patient",method = RequestMethod.POST)
    @ResponseBody
    public JSONObject delPatient(@RequestBody Patient patient){
        JSONObject json=new JSONObject();
        json.put("message",patientService.addPatient(patient));
        return json;
    }
    @RequestMapping(value = "/patient/medicalhistory")
    public String medicalhistory(HttpSession session,HttpServletRequest request){
        Login login=(Login)session.getAttribute("login");
        Patient patient=patientService.findPatientByLoginId(login.getId());
        request.setAttribute("medicalhistorys",medicalhistoryService.getMedicalhistoryByPatientId(patient.getId()));
        return "patient/medicalhistory";
    }
    @RequestMapping(value = "/patient/hospitalization")
    public String hospitalization(HttpSession session,HttpServletRequest request){
        Login login=(Login)session.getAttribute("login");
        Patient patient=patientService.findPatientByLoginId(login.getId());
        request.setAttribute("theLast",hospitalizationService.findTheLastHospitalization(patient.getHospitalizationid()));
        Hospitalization hospitalization=new Hospitalization();
        hospitalization.setPatientid(patient.getId());
        hospitalization.setId(patient.getHospitalizationid());
        request.setAttribute("others",hospitalizationService.findOtherHospitalization(hospitalization));
        return "patient/hospitalization";
    }
    @RequestMapping(value = "/patient/appointment")
    public String appointmentInfo(HttpServletRequest request,HttpSession session){
        Login login=(Login)session.getAttribute("login");
        Patient patient=patientService.findPatientByLoginId(login.getId());
        request.setAttribute("patientid",patient.getId());
        request.setAttribute("doctors",doctorService.getAllDoctor());
        return "patient/appointment";
    }
    @RequestMapping(value = "/patient/appointment",method = RequestMethod.POST)
    @ResponseBody
    public JSONObject appointment(@RequestBody Appointment appointment){
        JSONObject json=new JSONObject();
        Patient patient=new Patient();
        String message=appointmentService.addAppointment(appointment);
        patient.setAppointmentid(appointmentService.selectTheLastAppointment(appointment.getPatientid()));
        patient.setId(appointment.getPatientid());
        patientService.updateAppointMent(patient);
        json.put("message",message);
        return json;
    }
    @RequestMapping(value="/patient/search",method=RequestMethod.GET)
    public String search(){
        return "patient/search";
    }
}

登录管理控制层:

@Controller
public class LoginController {
    @Autowired
    LoginService loginService;
    @RequestMapping(value = "/hospital/login")
    public String loginAndregist(){
        return "login&regist";
    }
    @RequestMapping("/admin/adminManage")
    public String adminManage(HttpServletRequest request,@RequestParam(value = "username",required = false)String username){
        request.setAttribute("admins",loginService.findAllAdmin(username));
        return "/admin/adminManage";
    }
    @RequestMapping("/admin/admin/{id}")
    public String adminInfo(HttpServletRequest request,@PathVariable Integer id){
        request.setAttribute("admin",loginService.getAdmin(id));
        return "/admin/info/admininfo";
    }
    @RequestMapping("/admin/adminAdd")
    public String adminAddPage(){
        return"admin/add/adminadd";
    }
    @RequestMapping(value = "/admin/admin",method = RequestMethod.POST)
    @ResponseBody
    public JSONObject adminAdd(@RequestBody Login login){
        JSONObject json=new JSONObject();
        json.put("message",loginService.addAmin(login));
        return json;
    }
    @RequestMapping(value = "/admin/admin",method = RequestMethod.PUT)
    @ResponseBody
    public JSONObject upAdmin(@RequestBody Login login){
        JSONObject json=new JSONObject();
        json.put("message",loginService.updateAdmin(login));
        return json;
    }
    @RequestMapping(value = "/admin/admin/{id}",method = RequestMethod.DELETE)
    @ResponseBody
    public JSONObject delAdmin(@PathVariable Integer id){
        JSONObject json=new JSONObject();
        json.put("message",loginService.delAdmin(id));
        return json;
    }
    @RequestMapping(value = "/loginout",method = RequestMethod.GET)
    public String loginout(HttpSession session){
        session.removeAttribute("login");
        return "login&regist";
    }
    @RequestMapping(value = "/login",method = RequestMethod.POST)
    @ResponseBody
    public JSONObject login(@RequestBody Login login,HttpSession session){
        // 生成登录验证用到的token对象
        UsernamePasswordToken token = new UsernamePasswordToken(login.getUsername(), login.getPassword());
        Subject subject = SecurityUtils.getSubject();

        //登录验证
        subject.login(token);


        String login1 = loginService.login(login);

        JSONObject json=new JSONObject();
        json.put("message",login1);
        session.setAttribute("login",login);
        return json;
    }
    @RequestMapping(value = "/regest",method = RequestMethod.POST)
    @ResponseBody
    public JSONObject regest(@RequestBody Login login){
        JSONObject json=new JSONObject();
        json.put("message",loginService.regist(login));
        return json;
    }

    @RequestMapping("/hospital/patient/index")
    public String patientIndex(){
        return "/patient/index";
    }
    @RequestMapping("/hospital/doctor/index")
    public String doctorIndex(){
        return "/doctor/index";
    }
    @RequestMapping("/hospital/admin/index")
    public String adminIndex(){
        return "/admin/index";
    }

}

源码获取:俺的博客首页 "资源" 里下载! 

基于JAVA的医院门诊信息管理系统设计与实现 摘 要 医院门诊信息管理系统是一个基于Internet的应用系统,它是一个面对当前的医院门 诊管理工作基本还处于手工和半信息自动化处理状态而应运而生的一个基于Internet的 一个信息自动化的系统,整个系统从符合操作简便、界面友好、灵活、实用、安全的要求 出发,完成预约、诊断、开具处方、保存病历管理的全过程。医疗事业单位只需具备访 问Internet的条件即可在系统发布的站点上进行医疗门诊的管理。在图型化的人机界 面中完成日常的医疗门诊管理工作.一方面摆脱了时间和空间的限制,另一方面有效的解 决的数据共享的问题。经过实际使用证明,本文所设计的医院门诊信息管理系统可以满 足医院在门诊管理方面的需要。 关键词:JSP;医院门诊;信息管理系统 JSP-BASED HOSPITAL OUTPATIENT INFORMATION MANAGEMENT SYSTEM  ABSTRACT Hospital outpatient information management system is an Internet-based application system. It is an Internet-based automated information system that solves the outpatient medical management of the basic work is still in the manual and semi-automated processing of information. The entire system is simple, friendly interface, flexible, practical and safe, and complete the entire process of booking, diagnosis, prescribing and medical records management preservation. Medical institutions only need visit the Internet can use the system for the release site medical clinic management. Using the pattern of the man-machine interface complete routine outpatient medical management. While out of time and space constraints, on the other hand, it is an effective solution to the data sharing problem. Through practical show that JSP-based hospital outpatient information management system to meet the hospital in-patient management needs. Key Words: JSP; Hospital Outpatient; Information Management System 1 绪论 医院门诊信息管理系统是信息管理系统医院门诊部门中的应用。随着Internet技 术的发展,其被广泛应用与各行各业,医院门诊部门是其一个重要的应用领域。伴随着医 院的改革,医院信息化进程的加速,建立基于Web的医院门诊信息管理系统显得尤为重要 。 1.1 课题研究现状分析 随着医疗卫生事业的发展,医院改革的深入,信息的有效、高效利用,已受到人们的 关注。充分利用现代科技手段,加强各种信息的利用开发,是医院信息管理的一个重要 内容,也是当今医院的需要。目前的医院仅仅把医院的信息管理系统作为微机工具系统, 而没有发挥其管理的真正功能;系统分散设计,各部门独立实施,没有考虑信息的关联和 共享,存在信息孤岛现象;医院管理错综复杂,从而形成了医院信息管理系统数据的多样 化,数据量大等特点[1]。 通过本次医院门诊信息系统的设计,解决医院系统中各种信息管理的集成问题,使医院 系统的各种信息管理一体化。同时,了解医院门诊的流程,把握信息管理系统开发概念, 掌握动态网站技术,熟悉系统开发的进程,做到会用相关工具设计和开发相关系统,并实 现。 1.2 技术发展趋势 随着Internet技术的普及和发展基本上各种不同的操作系统平台上都有相应的We b浏览器程序,这就使得医院门诊信息管理系统具有非常广泛的平台兼容性。客户端仅需 一个Web浏览器程序,不再需
评论 8
添加红包

请填写红包祝福语或标题

红包个数最小为10个

红包金额最低5元

当前余额3.43前往充值 >
需支付:10.00
成就一亿技术人!
领取后你会自动成为博主和红包主的粉丝 规则
hope_wisdom
发出的红包

打赏作者

beyondwild

你的鼓励将是我创作的最大动力

¥1 ¥2 ¥4 ¥6 ¥10 ¥20
扫码支付:¥1
获取中
扫码支付

您的余额不足,请更换扫码支付或充值

打赏作者

实付
使用余额支付
点击重新获取
扫码支付
钱包余额 0

抵扣说明:

1.余额是钱包充值的虚拟货币,按照1:1的比例进行支付金额的抵扣。
2.余额无法直接购买下载,可以购买VIP、付费专栏及课程。

余额充值