基于javaweb+jsp的健康体检信息管理系统(JavaWeb MySQL JSP Bootstrap Servlet SSM SpringBoot)
JavaWeb JavaBean JSP MVC MySQL Tomcat JavaScript Bootstrap.
基础JSP+Servlet或JSP+SSM(Spring、SpringMVC、MyBatis)框架或JSP+SSM+Maven(pom.xml)框架或SpringBoot…均可修改
开发工具:eclipse/idea/myeclipse/sts等均可配置运行
适用
课程设计,大作业,毕业设计,项目练习,学习演示等
</update>
<!--获取-->
<select id="findById" resultMap="BaseResultMap">
SELECT <include refid="Base_Column_List" /> FROM `t_notice` WHERE `id` = #{id}
</select>
<!--列表-->
<select id="findAllSplit" parameterType="java.util.Map" resultMap="BaseResultMap">
SELECT <include refid="Base_Column_List" /> FROM `t_notice`
<where>
<if test="searchColumn != null and searchColumn != '' and keyword != null and keyword != ''">
${searchColumn} LIKE CONCAT('%',#{keyword},'%') AND
</if>
1=1
</where>
ORDER BY id ASC
<if test="startIndex != null and pageSize != null">
LIMIT #{startIndex},#{pageSize};
</tbody>
</table>
<div style="float: right;padding-right: 10px;color: #515151;"><jsp:include page="split.jsp"/></div>
</div>
</body>
<script>
function searchList() {
window.location.href = "jiancheList?searchColumn="+document.getElementById("searchColumn").value+"&keyword=" + document.getElementById("search_keyword").value;
}
</script>
</html>
<?xml version="1.0" encoding="UTF-8"?>
<!DOCTYPE mapper PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN" "http://mybatis.org/dtd/mybatis-3-mapper.dtd">
<mapper namespace="com.demo.dao.JiancheMapper">
<resultMap id="BaseResultMap" type="com.demo.vo.Jianche" >
<result column="id" property="id" />
<result column="jianche_name" property="jiancheName" />
<result column="jianche_sex" property="jiancheSex" />
<result column="jianche_age" property="jiancheAge" />
<result column="jianche_gao" property="jiancheGao" />
<result column="jianche_zhong" property="jiancheZhong" />
<result column="jianche_xietang" property="jiancheXietang" />
<result column="jianche_text" property="jiancheText" />
</resultMap>
* @param request
* @throws IOException
*/
@RequestMapping("tijianDelete")
public void delete(HttpServletResponse response, HttpServletRequest request) throws IOException {
Serializable id = Util.decode(request, "id");
tijianService.delete(Arrays.asList(id));
this.redirectList(request, response);
}
/**
* 编辑体检记录
*
* @param response
* @param request
* @throws IOException
*/
@RequestMapping("tijianEdit")
public void edit(HttpServletResponse response, HttpServletRequest request) throws IOException {
Tijian vo = new Tijian();
public String getTijianStatus() {
return tijianStatus;
}
public void setTijianStatus(String tijianStatus) {
this.tijianStatus = tijianStatus;
}
public String getTijianText() {
return tijianText;
}
public void setTijianText(String tijianText) {
this.tijianText = tijianText;
}
}
package com.demo.vo;
import java.io.Serializable;
</update>
<!--获取-->
<select id="findById" resultMap="BaseResultMap">
SELECT <include refid="Base_Column_List" /> FROM `t_user` WHERE `id` = #{id}
</select>
<!--列表-->
<select id="findAllSplit" parameterType="java.util.Map" resultMap="BaseResultMap">
SELECT <include refid="Base_Column_List" /> FROM `t_user`
<where>
<if test="searchColumn != null and searchColumn != '' and keyword != null and keyword != ''">
${searchColumn} LIKE CONCAT('%',#{keyword},'%') AND
</if>
1=1
</where>
ORDER BY id ASC
<if test="startIndex != null and pageSize != null">
LIMIT #{startIndex},#{pageSize};
return totalPage;
}
public void setTotalPage(int totalPage) {
this.totalPage = totalPage;
}
public int getStartIndex() {
return startIndex;
}
public void setStartIndex(int startIndex) {
this.startIndex = startIndex;
}
import org.springframework.stereotype.Controller;
import org.springframework.web.bind.annotation.RequestMapping;
import javax.servlet.http.HttpServletRequest;
import javax.servlet.http.HttpServletResponse;
import javax.servlet.http.HttpSession;
import java.io.IOException;
import java.io.Serializable;
import java.util.Arrays;
import java.util.HashMap;
import java.util.List;
import java.util.Map;
@Controller
@RequestMapping
public class TijianController {
@Autowired
private TijianService tijianService;
/**
* 增加体检记录
*
* @param response
public void setTotalPage(int totalPage) {
this.totalPage = totalPage;
}
public int getStartIndex() {
return startIndex;
}
public void setStartIndex(int startIndex) {
this.startIndex = startIndex;
}
public int getStart() {
vo.setId(Long.valueOf(Util.decode(request, "id")));
vo.setTijianName(Util.decode(request, "tijianName"));
vo.setTijianTime(Util.decode(request, "tijianTime"));
vo.setTijianYiyuan(Util.decode(request, "tijianYiyuan"));
vo.setTijianMing(Util.decode(request, "tijianMing"));
vo.setTijianJieguo(Util.decode(request, "tijianJieguo"));
vo.setTijianStatus(Util.decode(request, "tijianStatus"));
vo.setTijianText(Util.decode(request, "tijianText"));
tijianService.update(vo);
this.redirectList(request, response);
}
/**
* 获取体检记录的详细信息(详情页面与编辑页面要显示该体检记录的详情)并跳转回页面
*
* @param response
* @param request
* @throws IOException
*/
@RequestMapping({"tijianGet", "tijianEditPre"})
public void get(HttpServletResponse response, HttpServletRequest request) throws IOException {
Serializable id = Util.decode(request, "id");//取出主键id
Tijian vo = tijianService.get(id);
* @param response
* @param request
* @throws IOException
*/
@RequestMapping("noticeList")
public void list(HttpServletResponse response, HttpServletRequest request) throws IOException {
this.redirectList(request, response);
}
/**
* 跳转到列表页面
*
* @param request
* @param response
*/
private void redirectList(HttpServletRequest request, HttpServletResponse response) throws IOException {
//查询列和关键字
String searchColumn = Util.decode(request, "searchColumn");
String keyword = Util.decode(request, "keyword");
Map<String, Object> params = new HashMap();//用来保存控制层传进来的参数(查询条件)
params.put("searchColumn", searchColumn);//要查询的列
params.put("keyword", keyword);//查询的关键字
Map<String, Object> map = noticeService.list(params);
request.getSession().setAttribute("list", map.get("list"));
Integer totalRecord = (Integer) map.get("totalCount");//根据查询条件取出对应的总记录数,用于分页
运行环境
Java≥6、Tomcat≥7.0、MySQL≥5.5
开发工具
eclipse/idea/myeclipse/sts等均可配置运行
技术框架
JavaWeb JavaBean JSP MVC MySQL Tomcat JavaScript Bootstrap.
基础JSP+Servlet或JSP+SSM(Spring、SpringMVC、MyBatis)框架或JSP+SSM+Maven(pom.xml)框架或SpringBoot…均可修改
适用
课程设计,大作业,毕业设计,项目练习,学习演示等
功能说明
登录、注册、退出、用户模块、公告模块、健康档案模块、体检记录模块的增删改查管理