赞
踩
1、项目介绍
java基于SSH的医院挂号管理系统、挂号管理系统,医院挂号系统主要用于实现医院的挂号,分为前台和后台管理。
前台基本功能包括:用户注册、用户登录、医院查询、挂号、取消挂号、修改个人信息、退出等。
后台基本功能包括:系统管理员登录、医院管理、科室管理、公告管理、退出系统等。
2、技术框架
编程语言:Java
系统架构:B/S
前端框架:Spring+Struts+Hibernate(SSH)
前端框架:JSP+html+js+CSS
数据库:MySQL
Maven项目:否
运行环境:JDK7+MySQL5.6+Idea+Tomcat8.5
3、演示视频
B站演示视频:
java基于SSH的医院挂号管理系统、挂号管理系统,附源码+数据库+PPT+文档,适合课程设计、毕业设计
java基于SSH的医院挂号管理系统、挂号管理系统,附源码+数据库+PPT+文档,适合课程设计、毕业设计_哔哩哔哩_bilibili
4、项目截图
4.1、首页
4.2、医生信息
4.3、医生查询
4.4、公告信息
4.5、用户注册
4.6、挂号
4.7、我的挂号信息
4.8、后台首页
4.9、医院信息管理
4.10、科室信息管理
4.11、医生信息管理
4.12、会员信息管理
4.13、系统公告管理
5、文档截图
6、代码示例
- package com.action;
-
- import java.util.Date;
- import java.util.List;
- import java.util.Map;
-
- import javax.servlet.http.HttpServletRequest;
- import javax.servlet.http.HttpSession;
-
- import org.apache.struts2.ServletActionContext;
-
- import com.dao.TGuahaoDAO;
- import com.dao.TZhuanjiaDAO;
- import com.model.TGuahao;
- import com.model.TUser;
- import com.model.TZhuanjia;
- import com.opensymphony.xwork2.ActionSupport;
-
- public class guahaoAction extends ActionSupport
- {
- private Integer id;
- private Integer zhuanjiaId;
- private Integer userId;
- private String riqi;
-
- private String jibing;
- private String xingming;
- private String lianxi;
-
- private String message;
- private String path;
-
- private TGuahaoDAO guahaoDAO;
- private TZhuanjiaDAO zhuanjiaDAO;
-
- public String guahaoAdd()
- {
- HttpServletRequest request=ServletActionContext.getRequest();
- HttpSession session=request.getSession();
- TUser user=(TUser)session.getAttribute("user");
-
-
- TGuahao guahao=new TGuahao();
-
- guahao.setZhuanjiaId(zhuanjiaId);
- guahao.setUserId(user.getUserId());
- guahao.setRiqi(riqi);
- guahao.setJibing(jibing);
-
- guahao.setXingming(xingming);
- guahao.setLianxi(lianxi);
-
- guahaoDAO.save(guahao);
-
-
- this.setMessage("成功挂号");
- this.setPath("index.action");
- return "succeed";
- }
-
-
- public String guahaoDel()
- {
- HttpServletRequest request=ServletActionContext.getRequest();
-
- TGuahao guahao=guahaoDAO.findById(id);
- guahaoDAO.delete(guahao);
-
- request.setAttribute("msg", "成功取消挂号");
- return "msg";
- }
-
-
-
- public String guahaoMana_user()
- {
- HttpServletRequest request=ServletActionContext.getRequest();
- HttpSession session=request.getSession();
- TUser user=(TUser)session.getAttribute("user");
-
- String sql="from TGuahao where userId="+user.getUserId();
- List guahaoList =guahaoDAO.getHibernateTemplate().find(sql);
- for(int i=0;i<guahaoList.size();i++)
- {
- TGuahao guahao=(TGuahao)guahaoList.get(i);
- guahao.setZhuanjia(zhuanjiaDAO.findById(guahao.getZhuanjiaId()));
- }
-
- request.setAttribute("guahaoList", guahaoList);
- return ActionSupport.SUCCESS;
- }
-
-
-
- public String guahaoMana_zhuanjia()
- {
- HttpServletRequest request=ServletActionContext.getRequest();
- HttpSession session=request.getSession();
- TZhuanjia zhuanjia=(TZhuanjia)session.getAttribute("zhuanjia");
-
- String sql="from TGuahao where zhuanjiaId="+zhuanjia.getId();
- List guahaoList =guahaoDAO.getHibernateTemplate().find(sql);
- for(int i=0;i<guahaoList.size();i++)
- {
- TGuahao guahao=(TGuahao)guahaoList.get(i);
- guahao.setZhuanjia(zhuanjiaDAO.findById(guahao.getZhuanjiaId()));
- }
-
- request.setAttribute("guahaoList", guahaoList);
- return ActionSupport.SUCCESS;
- }
-
-
- public TGuahaoDAO getGuahaoDAO()
- {
- return guahaoDAO;
- }
-
-
- public void setGuahaoDAO(TGuahaoDAO guahaoDAO)
- {
- this.guahaoDAO = guahaoDAO;
- }
-
-
- public TZhuanjiaDAO getZhuanjiaDAO()
- {
- return zhuanjiaDAO;
- }
-
-
- public String getMessage()
- {
- return message;
- }
-
-
- public void setMessage(String message)
- {
- this.message = message;
- }
-
-
- public String getPath()
- {
- return path;
- }
-
-
- public void setPath(String path)
- {
- this.path = path;
- }
-
-
- public void setZhuanjiaDAO(TZhuanjiaDAO zhuanjiaDAO)
- {
- this.zhuanjiaDAO = zhuanjiaDAO;
- }
-
-
- public Integer getId()
- {
- return id;
- }
-
-
- public void setId(Integer id)
- {
- this.id = id;
- }
-
-
- public String getJibing()
- {
- return jibing;
- }
-
-
- public void setJibing(String jibing)
- {
- this.jibing = jibing;
- }
-
-
- public String getLianxi()
- {
- return lianxi;
- }
-
-
- public void setLianxi(String lianxi)
- {
- this.lianxi = lianxi;
- }
-
-
-
-
- public String getRiqi()
- {
- return riqi;
- }
-
-
- public void setRiqi(String riqi)
- {
- this.riqi = riqi;
- }
-
-
- public Integer getUserId()
- {
- return userId;
- }
-
-
- public void setUserId(Integer userId)
- {
- this.userId = userId;
- }
-
-
- public String getXingming()
- {
- return xingming;
- }
-
-
- public void setXingming(String xingming)
- {
- this.xingming = xingming;
- }
-
-
- public Integer getZhuanjiaId()
- {
- return zhuanjiaId;
- }
-
-
- public void setZhuanjiaId(Integer zhuanjiaId)
- {
- this.zhuanjiaId = zhuanjiaId;
- }
-
- }
- package com.action;
-
- import java.util.List;
- import java.util.Map;
-
- import org.apache.struts2.ServletActionContext;
-
- import com.dao.TUserDAO;
- import com.model.TUser;
- import com.opensymphony.xwork2.ActionContext;
- import com.opensymphony.xwork2.ActionSupport;
-
- public class UserAction extends ActionSupport
- {
- private int userId;
- private String userName;
- private String userPw;
- private String userRealname;
-
- private String userAddress;
- private String userTel;
- private String userEmail;
- private String userDel;
-
-
-
-
- private String message;
- private String path;
-
- private TUserDAO userDAO;
-
-
-
- public String userReg()
- {
- TUser user=new TUser();
-
- user.setUserName(userName);
- user.setUserPw(userPw);
- user.setUserAddress(userAddress);
- user.setUserTel(userTel);
-
- user.setUserRealname(userRealname);
- user.setUserEmail(userEmail);
- user.setUserDel("no");
-
- userDAO.save(user);
-
- this.setMessage("注册成功,请登录");
- this.setPath("qiantai/default.jsp");
- return "succeed";
- }
-
-
- public String userLogin()
- {
- String sql="from TUser where userName=? and userPw=? and userDel='no'";
- Object[] con={userName,userPw};
- List userList=userDAO.getHibernateTemplate().find(sql,con);
-
- System.out.println(userList.size()+"%%");
- if(userList.size()==0)
- {
- this.setMessage("用户名或密码错误");
- this.setPath("qiantai/default.jsp");
- }
- else
- {
- Map session= ServletActionContext.getContext().getSession();
- TUser user=(TUser)userList.get(0);
- session.put("user", user);
- session.put("userType", 2);
-
- this.setMessage("成功登录");
- this.setPath("qiantai/default.jsp");
- }
-
- return "succeed";
- }
-
- public String userLogout()
- {
- Map session= ServletActionContext.getContext().getSession();
- session.put("user", null);
- session.put("userType", null);
-
- this.setMessage("安全退出系统");
- this.setPath("qiantai/default.jsp");
- return "succeed";
- }
-
- public String userEdit()
- {
- TUser user=userDAO.findById(userId);
-
- user.setUserName(userName);
- user.setUserPw(userPw);
- user.setUserAddress(userAddress);
- user.setUserTel(userTel);
-
- user.setUserRealname(userRealname);
- user.setUserEmail(userEmail);
- user.setUserDel("no");
-
- userDAO.attachDirty(user);
-
- Map request=(Map)ServletActionContext.getContext().get("request");
- request.put("msg", "修改成功,重新登陆后生效");
- return "msg";
- }
-
-
-
-
- public String userMana()
- {
- String sql="from TUser where userDel='no'";
- List userList=userDAO.getHibernateTemplate().find(sql);
-
- Map request=(Map)ServletActionContext.getContext().get("request");
- request.put("userList", userList);
- return ActionSupport.SUCCESS;
- }
-
-
-
- public String userDel()
- {
- TUser user=userDAO.findById(userId);
- user.setUserDel("yes");
-
- userDAO.attachDirty(user);
- this.setMessage("删除成功");
- this.setPath("userMana.action");
- return "succeed";
- }
-
-
-
-
-
- public int getUserId()
- {
- return userId;
- }
- public void setUserId(int userId)
- {
- this.userId = userId;
- }
- public String getUserName()
- {
- return userName;
- }
- public void setUserName(String userName)
- {
- this.userName = userName;
- }
- public String getUserPw()
- {
- return userPw;
- }
- public void setUserPw(String userPw)
- {
- this.userPw = userPw;
- }
- public String getUserRealname()
- {
- return userRealname;
- }
- public void setUserRealname(String userRealname)
- {
- this.userRealname = userRealname;
- }
- public String getUserAddress()
- {
- return userAddress;
- }
- public void setUserAddress(String userAddress)
- {
- this.userAddress = userAddress;
- }
- public String getUserTel()
- {
- return userTel;
- }
- public void setUserTel(String userTel)
- {
- this.userTel = userTel;
- }
- public String getUserEmail()
- {
- return userEmail;
- }
- public void setUserEmail(String userEmail)
- {
- this.userEmail = userEmail;
- }
- public String getUserDel()
- {
- return userDel;
- }
- public void setUserDel(String userDel)
- {
- this.userDel = userDel;
- }
- public String getMessage()
- {
- return message;
- }
- public void setMessage(String message)
- {
- this.message = message;
- }
- public String getPath()
- {
- return path;
- }
- public void setPath(String path)
- {
- this.path = path;
- }
- public TUserDAO getUserDAO()
- {
- return userDAO;
- }
- public void setUserDAO(TUserDAO userDAO)
- {
- this.userDAO = userDAO;
- }
-
- }
Copyright © 2003-2013 www.wpsshop.cn 版权所有,并保留所有权利。