基于javaweb+mysql的医院挂号预约管理系统(java+SSM+HTML+JavaScript+jsp+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/ 登录请添加图片描述
    请添加图片描述
    请添加图片描述
    请添加图片描述
    请添加图片描述
    请添加图片描述
    请添加图片描述
    请添加图片描述

适用

课程设计,大作业,毕业设计,项目练习,学习演示等

			    	sectionlist2 = sectionService.selectByExample(section);
			 }else {
				 if(sectionlist.size() >0 ) {
	    			 section.setPid(sectionlist.get(0).getId());	
	    			 section.setType(2);
				     sectionlist2 = sectionService.selectByExample(section);
	    		 }
				 se1 = new   Section();
			 }
		    model.addAttribute("sectionlist2", sectionlist2);
		    model.addAttribute("se1", se1);
		    
		}
	    return "admin/doctorUptate";
	}
	    
	     	}
	         HttpSession session = request.getSession();
	         Doctor dt = (Doctor) session.getAttribute("DOCTOR");
	         if(dt != null){
	        	 messages.setDid(dt.getId());
	         }else{
	        	  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);
	       if(doctor.getId() !=  null){
	    	   if(doctor.getSid() != null) {
	    		   Section selectByPrimaryKey = sectionService.selectByPrimaryKey(doctor.getSid());
	    		   doctor.setSname(selectByPrimaryKey.getName());
	    	   }
	           doctorService.updateByPrimaryKeySelective(doctor);
	       }
	        model.addAttribute("type",1);
	        return "login";
	   }
		    
		
	    /**
	        *  管理员注册界面
	     */
	    @RequestMapping("/mimaPageUptate")
	    public String  mimaPageUptate(Integer type,Model model) {
	    	//1医生  2 管理员
	    	if(type == 1 ) {
	    		  return "doctorRegister";
	    	}
	  	  return "adminRegister";
	    }
	    
	    /**
	      *  医生注册界面
    public String sectionUptate(Section section) {
          sectionService.updateByPrimaryKeySelective(section);
          return  "redirect:/admin/sectionList";
    }
    /**
     * 修改科室下级
     */
    @RequestMapping("/sectionBelowUptate")
    public String sectionBelowUptate(Section section) {
          sectionService.updateByPrimaryKeySelective(section);
          return "redirect:/admin/sectionBelowList?id="+section.getPid();
    }
    /**
     * 删除科室下级
     */
    @RequestMapping("/sectionBelowDelect")
    public String sectionBelowUptate(Integer id) {
	    	Section section = sectionService.selectByPrimaryKey(id);
	    	Integer pid =  section.getPid();
            sectionService.deleteByPrimaryKey(section.getId());
            return "redirect:/admin/sectionBelowList?id="+pid;
    }
	             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);
	   	    	if(list.size() <= 0) {
	   	    	 model.addAttribute("message","密码错误");
        		 model.addAttribute("type",type);
        		 return "loginByPatient";
	   	    	}
	        	 session.setAttribute("PATIENT",list.get(0));
	        	 return "redirect:/api/doctorList1";
	         }
	         
				 */
	         Messages messages = new Messages();
//	         messages.setTime(new Date());
	         messages.setType(1);
	         messages.setDid(dt.getId());    
	         PageInfo<Messages> pageInfo = messagesService.selectMessagesList(messages, 1, size);
	         model.addAttribute("doctorList",pageInfo.getList());
	         model.addAttribute("pageInfo",pageInfo);
	         model.addAttribute("patient",patient);
	         return    "doctor/patientList";
	     }
	     
	    /**
    	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";
    }
    
    
    /**
     *  修改医生信息界面
     * @return
     */
	@RequestMapping("/doctorUptatePage")
	public String doctorUptatePage(Model model,Integer id) {
		if(id != null) {
			Doctor  doctor = doctorService.selectByPrimaryKey(id);
			List<Section> sectionlist2  = null;
                    char names = StringRandom.getPinYinHeadChar(sh.getName()); //名字的首字母
                    if(names == sz){
                        list2.add(sh);
                    }
                }
            }
            model.addAttribute("personList",list2);
        }else{
            model.addAttribute("personList",list);
        }
        model.addAttribute("sou",sou);
        model.addAttribute("pageInfo",pageInfo);
        model.addAttribute("person",person);
        return  "behind/admin/feiyi_personList";
    }
    *//**
	                mufile[i].transferTo(file);
	            } catch (IllegalStateException | IOException e) {
	                e.printStackTrace();
	            }
	        }
	        Banners banners = new  Banners();
	        if(id != null){
	            //修改图片路径
	            Banners  sh  = bannersService.selectByPrimaryKey(id);
	            banners.setId(id);
	            if(sh.getImg() != null ){
	                banners.setImg(sh.getImg()+path.toString());
	            }else{
	                banners.setImg(path.toString());
	            }
           return    map;
    }
    *//**
     * 后台登陆界面
     * @return
     *//*
    @RequestMapping("/afterView")
    public String afterLogin(Integer type,Model model) {
        if(type == null){
            type = 1;
        }
        model.addAttribute("type",type);
        return "behind/login";
    }
    *//**
     * 登陆验证
     * @return
     *//*
    @RequestMapping("/verificatio")
    public String signin(String username, String password, Integer type, HttpServletRequest request,Model model) {
        HttpSession session = request.getSession();
        session.setAttribute("type",type);
        //类型为1是商户后台 2是管理员
                file.delete();
            }
            videoService.deleteByPrimaryKey(id);
        }
        return  "redirect:/admin/feiyi_videoList";
    }
    *//**
     * 管理员-人物列表
     *//*
    @RequestMapping("/personList")
    public String personList(Model model,Person person,@RequestParam(value="page",defaultValue="1")Integer page,String sou) {
        PageInfo<Person> pageInfo = personService.selectPageList(person,page,size);
        List<Person> list = pageInfo.getList();
        List<Person> list2 = new ArrayList<Person>();
        //默认显示第一张图片
        for(int i =0; i<list.size();i++){
            Person sh = list.get(i);

  • 0
    点赞
  • 11
    收藏
    觉得还不错? 一键收藏
  • 1
    评论

“相关推荐”对你有帮助么?

  • 非常没帮助
  • 没帮助
  • 一般
  • 有帮助
  • 非常有帮助
提交
评论 1
添加红包

请填写红包祝福语或标题

红包个数最小为10个

红包金额最低5元

当前余额3.43前往充值 >
需支付:10.00
成就一亿技术人!
领取后你会自动成为博主和红包主的粉丝 规则
hope_wisdom
发出的红包
实付
使用余额支付
点击重新获取
扫码支付
钱包余额 0

抵扣说明:

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

余额充值