基于Spring MVC + Spring + MyBatis的【医院就诊挂号系统】

代码 代码 1597 人阅读 | 0 人回复

<
  资本下载:https://download.csdn.net/download/weixin_44893902/21727306
1、言语战情况

1.完成言语: JAVA言语。
2.情况请求: MyEclipse/Eclipse + Tomcat + MySQL。
3.利用妙技: Spring MVC + Spring + MyBatis 或 JSP + Servlet + JavaBean + JDBC。


2、完成结果

115302w784gpczgpv3008g.jpg

完成可以对患者姓名,医师种别、科室的恍惚查询,用户面击核销当前形态变成已救治。
115302b6lfqdjnj4bwfjb7.jpg

面击登记完成根本疑息的增加
115302mk2skcc0nk26n2nz.png

3、完成代码

数据库:

  1. SET FOREIGN_KEY_CHECKS=0;
  2. -- ----------------------------
  3. -- Table structure for tb_patient
  4. -- ----------------------------
  5. DROP TABLE IF EXISTS `tb_patient`;
  6. CREATE TABLE `tb_patient` (
  7.   `id` int(11) NOT NULL AUTO_INCREMENT,
  8.   `name` varchar(50) DEFAULT NULL,
  9.   `sex` varchar(10) DEFAULT NULL,
  10.   `age` int(11) DEFAULT NULL,
  11.   `phone` varchar(20) DEFAULT NULL,
  12.   `department` varchar(50) DEFAULT NULL,
  13.   `type` varchar(50) DEFAULT NULL,
  14.   `price` decimal(9,2) DEFAULT NULL,
  15.   `state` int(11) DEFAULT NULL,
  16.   `register_time` datetime DEFAULT NULL,
  17.   PRIMARY KEY (`id`)
  18. ) ENGINE=InnoDB AUTO_INCREMENT=6 DEFAULT CHARSET=utf8;
  19. -- ----------------------------
  20. -- Records of tb_patient
  21. -- ----------------------------
  22. INSERT INTO `tb_patient` VALUES (&#39;1&#39;, &#39;张蕾&#39;, &#39;女&#39;, &#39;12&#39;, &#39;13895463212&#39;, &#39;女科&#39;, &#39;专家医师&#39;, &#39;25.00&#39;, &#39;1&#39;, &#39;2021-07-18 12:23:00&#39;);
  23. INSERT INTO `tb_patient` VALUES (&#39;2&#39;, &#39;刘德明&#39;, &#39;男&#39;, &#39;28&#39;, &#39;13345623215&#39;, &#39;骨科&#39;, &#39;一般医师&#39;, &#39;8.00&#39;, &#39;0&#39;, &#39;2021-07-18 12:23:00&#39;);
  24. INSERT INTO `tb_patient` VALUES (&#39;3&#39;, &#39;李将军&#39;, &#39;男&#39;, &#39;38&#39;, &#39;13578064788&#39;, &#39;外科&#39;, &#39;专家医师&#39;, &#39;25.00&#39;, &#39;1&#39;, &#39;2021-07-17 12:23:00&#39;);
  25. INSERT INTO `tb_patient` VALUES (&#39;4&#39;, &#39;张佩佩&#39;, &#39;女&#39;, &#39;44&#39;, &#39;18214217246&#39;, &#39;中科&#39;, &#39;副主任医师&#39;, &#39;17.00&#39;, &#39;0&#39;, &#39;2021-07-16 12:23:00&#39;);
  26. INSERT INTO `tb_patient` VALUES (&#39;5&#39;, &#39;程智慧&#39;, &#39;男&#39;, &#39;29&#39;, &#39;13652645964&#39;, &#39;骨科&#39;, &#39;副主任医师&#39;, &#39;17.00&#39;, &#39;0&#39;, &#39;2021-08-08 16:21:52&#39;);
复造代码
项目Java代码:

目次构造
115303hyg6z6d6xw6c8pyy.jpg

JAR包:

115303ft231z8873y44ynl.jpg
115303fg9avvucfwbol3vc.png

代码:

=src

> com.mhys.crm.controller

HospitalContrller.java

  1. package com.mhys.crm.controller;
  2. import java.util.List;
  3. import javax.annotation.Resource;
  4. import org.springframework.stereotype.Controller;
  5. import org.springframework.ui.Model;
  6. import org.springframework.web.bind.annotation.RequestMapping;
  7. import com.mhys.crm.dao.TbPatientMapper;
  8. import com.mhys.crm.entity.TbPatient;
  9. @Controller
  10. public class HospitalContrller {
  11.         @Resource
  12.         private TbPatientMapper tbPatientMapper;
  13.         @RequestMapping("/select")
  14.         public String getList(Model model) {
  15.                 List<TbPatient> selctAll = tbPatientMapper.selectAlls();
  16.                 System.out.println(selctAll);
  17.                 model.addAttribute("selctAll", selctAll);
  18.                 return "info";
  19.         }
  20.         @RequestMapping("/list")
  21.         public String getAll(Model model, String name, String type, String dep) {
  22.                 List<TbPatient> selctAll = tbPatientMapper.selectAll(name, type, dep);
  23.                 System.out.println(name+"==="+type+"==="+dep);
  24.                 model.addAttribute("selctAll", selctAll);
  25.                 return "info";
  26.         }
  27.         @RequestMapping("/upd")
  28.         public String upDev(Model model,int id) {
  29.                 int update = tbPatientMapper.update(id);
  30.                 return "redirect:/select.do";
  31.         }
  32.        
  33.         @RequestMapping("/adds")
  34.         public String adds(Model model) {
  35.                 return "addInfo";
  36.         }
  37.        
  38.         @RequestMapping("/insert")
  39.         public String toaddDev(Model model,TbPatient tb) {
  40.                 tbPatientMapper.insert(tb);
  41.             return "redirect:/select.do";
  42.         }
  43. }
复造代码
> com.mhys.crm.dao

TbPatientMapper.java

  1. package com.mhys.crm.dao;
  2. import com.mhys.crm.entity.TbPatient;
  3. import java.util.List;
  4. import org.apache.ibatis.annotations.Param;
  5. public interface TbPatientMapper {
  6.     int deleteByPrimaryKey(Integer id);
  7.     int insert(TbPatient record);
  8.     TbPatient selectByPrimaryKey(Integer id);
  9.     List<TbPatient> selectAlls();
  10.     int updateByPrimaryKey(TbPatient record);
  11.    
  12.     int update(Integer id);
  13.    
  14.     List<TbPatient> selectAll(@Param("name")String name,@Param("type")String type,@Param("dep")String dap);
  15. }
复造代码
TbPatientMapper.xml

  1. <?xml version="1.0" encoding="UTF-8" ?>
  2. <!DOCTYPE mapper PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN" "http://mybatis.org/dtd/mybatis-3-mapper.dtd" >
  3. <mapper namespace="com.mhys.crm.dao.TbPatientMapper" >
  4.   <resultMap id="BaseResultMap" type="com.mhys.crm.entity.TbPatient" >
  5.     <id column="id" property="id" jdbcType="INTEGER" />
  6.     <result column="name" property="name" jdbcType="VARCHAR" />
  7.     <result column="sex" property="sex" jdbcType="VARCHAR" />
  8.     <result column="age" property="age" jdbcType="INTEGER" />
  9.     <result column="phone" property="phone" jdbcType="VARCHAR" />
  10.     <result column="department" property="department" jdbcType="VARCHAR" />
  11.     <result column="type" property="type" jdbcType="VARCHAR" />
  12.     <result column="price" property="price" jdbcType="DECIMAL" />
  13.     <result column="state" property="state" jdbcType="INTEGER" />
  14.     <result column="register_time" property="registerTime" jdbcType="TIMESTAMP" />
  15.   </resultMap>
  16.   <delete id="deleteByPrimaryKey" parameterType="java.lang.Integer" >
  17.     delete from tb_patient
  18.     where id = #{id,jdbcType=INTEGER}
  19.   </delete>
  20.   <insert id="insert" parameterType="com.mhys.crm.entity.TbPatient" >
  21.     insert into tb_patient (id, name, sex,
  22.       age, phone, department,
  23.       type, price, state,
  24.       register_time)
  25.     values (#{id,jdbcType=INTEGER}, #{name,jdbcType=VARCHAR}, #{sex,jdbcType=VARCHAR},
  26.       #{age,jdbcType=INTEGER}, #{phone,jdbcType=VARCHAR}, #{department,jdbcType=VARCHAR},
  27.       #{type,jdbcType=VARCHAR}, #{price,jdbcType=DECIMAL}, #{state,jdbcType=INTEGER},
  28.       #{registerTime,jdbcType=TIMESTAMP})
  29.   </insert>
  30.   <update id="updateByPrimaryKey" parameterType="com.mhys.crm.entity.TbPatient" >
  31.     update tb_patient
  32.     set name = #{name,jdbcType=VARCHAR},
  33.       sex = #{sex,jdbcType=VARCHAR},
  34.       age = #{age,jdbcType=INTEGER},
  35.       phone = #{phone,jdbcType=VARCHAR},
  36.       department = #{department,jdbcType=VARCHAR},
  37.       type = #{type,jdbcType=VARCHAR},
  38.       price = #{price,jdbcType=DECIMAL},
  39.       state = #{state,jdbcType=INTEGER},
  40.       register_time = #{registerTime,jdbcType=TIMESTAMP}
  41.     where id = #{id,jdbcType=INTEGER}
  42.   </update>
  43.   <select id="selectAlls" resultMap="BaseResultMap" >
  44.     select id, name, sex, age, phone, department, type, price, state, register_time
  45.     from tb_patient
  46.   </select>
  47.   
  48.   <select id="selectAll" resultMap="BaseResultMap" >
  49.     select id, name, sex, age, phone, department, type, price, state, register_time
  50.     from tb_patient
  51.     <where>
  52.     <if test="name!=null and name!=&#39;&#39;">
  53.             and name = #{name}
  54.     </if>
  55.         <if test="type!=null and type!=&#39;&#39;">
  56.             and type = #{type}
  57.     </if>
  58.     <if test="dep!=null and dep!=&#39;&#39;">
  59.             and department = #{dep}
  60.     </if>
  61.     </where>
  62.   </select>
  63.   
  64.   <update id="update" parameterType="com.mhys.crm.entity.TbPatient" >
  65.     update tb_patient set state=1 where id = #{id,jdbcType=INTEGER}
  66.   </update>
  67.   
  68. </mapper>
复造代码
> com.mhys.crm.entity

TbPatient.java

  1. package com.mhys.crm.entity;
  2. import java.math.BigDecimal;
  3. import java.util.Date;
  4. public class TbPatient {
  5.     private Integer id;
  6.     private String name;
  7.     private String sex;
  8.     private Integer age;
  9.     private String phone;
  10.     private String department;
  11.     private String type;
  12.     private BigDecimal price;
  13.     private Integer state;
  14.     private Date registerTime;
  15.     public Integer getId() {
  16.         return id;
  17.     }
  18.     public void setId(Integer id) {
  19.         this.id = id;
  20.     }
  21.     public String getName() {
  22.         return name;
  23.     }
  24.     public void setName(String name) {
  25.         this.name = name == null ? null : name.trim();
  26.     }
  27.     public String getSex() {
  28.         return sex;
  29.     }
  30.     public void setSex(String sex) {
  31.         this.sex = sex == null ? null : sex.trim();
  32.     }
  33.     public Integer getAge() {
  34.         return age;
  35.     }
  36.     public void setAge(Integer age) {
  37.         this.age = age;
  38.     }
  39.     public String getPhone() {
  40.         return phone;
  41.     }
  42.     public void setPhone(String phone) {
  43.         this.phone = phone == null ? null : phone.trim();
  44.     }
  45.     public String getDepartment() {
  46.         return department;
  47.     }
  48.     public void setDepartment(String department) {
  49.         this.department = department == null ? null : department.trim();
  50.     }
  51.     public String getType() {
  52.         return type;
  53.     }
  54.     public void setType(String type) {
  55.         this.type = type == null ? null : type.trim();
  56.     }
  57.     public BigDecimal getPrice() {
  58.         return price;
  59.     }
  60.     public void setPrice(BigDecimal price) {
  61.         this.price = price;
  62.     }
  63.     public Integer getState() {
  64.         return state;
  65.     }
  66.     public void setState(Integer state) {
  67.         this.state = state;
  68.     }
  69.     public Date getRegisterTime() {
  70.         return registerTime;
  71.     }
  72.     public void setRegisterTime(Date registerTime) {
  73.         this.registerTime = registerTime;
  74.     }
  75.         @Override
  76.         public String toString() {
  77.                 return "TbPatient [id=" + id + ", name=" + name + ", sex=" + sex + ", age=" + age + ", phone=" + phone
  78.                                 + ", department=" + department + ", type=" + type + ", price=" + price + ", state=" + state
  79.                                 + ", registerTime=" + registerTime + "]";
  80.         }
  81.    
  82.    
  83. }
复造代码
> com.mhys.crm.service.impl

HospitalService.java

  1. package com.mhys.crm.service.impl;
  2. import java.util.List;
  3. import javax.annotation.Resource;
  4. import org.springframework.ui.Model;
  5. import org.springframework.web.bind.annotation.RequestMapping;
  6. import com.mhys.crm.dao.TbPatientMapper;
  7. import com.mhys.crm.entity.TbPatient;
  8. public class HospitalService {
  9.         @Resource
  10.         private TbPatientMapper tbPatientMapper;
  11.         @RequestMapping("/select")
  12.         public String getList(Model model) {
  13.                 List<TbPatient> selctAll = tbPatientMapper.selectAlls();
  14.                 System.out.println(selctAll);
  15.                 model.addAttribute("selctAll", selctAll);
  16.                 return "info";
  17.         }
  18.         @RequestMapping("/list")
  19.         public String getAll(Model model, String name, String type, String dep) {
  20.                 List<TbPatient> selctAll = tbPatientMapper.selectAll(name, type, dep);
  21.                 System.out.println(name+"==="+type+"==="+dep);
  22.                 model.addAttribute("selctAll", selctAll);
  23.                 return "info";
  24.         }
  25.         @RequestMapping("/upd")
  26.         public String upDev(Model model,int id) {
  27.                 int update = tbPatientMapper.update(id);
  28.                 return "redirect:/select.do";
  29.         }
  30.        
  31.         @RequestMapping("/adds")
  32.         public String adds(Model model) {
  33.                 return "addInfo";
  34.         }
  35.        
  36.         @RequestMapping("/insert")
  37.         public String toaddDev(Model model,TbPatient tb) {
  38.                 tbPatientMapper.insert(tb);
  39.             return "redirect:/select.do";
  40.         }
  41. }
复造代码
=resource

> mybatis

SqlMapConfig.xml

  1. <?xml version="1.0" encoding="UTF-8" ?>
  2. <!DOCTYPE configuration PUBLIC "-//mybatis.org//DTD Config 3.0//EN"
  3. "http://mybatis.org/dtd/mybatis-3-config.dtd">
  4. <configuration>
  5.         <typeAliases>
  6.                 <package name="com.mhys.crm.entity"/>
  7.         </typeAliases>
  8. </configuration>
复造代码
> spring

applicationContext-dao.xml

  1. <?xml version="1.0" encoding="UTF-8"?>
  2. <beans xmlns="http://www.springframework.org/schema/beans"
  3.         xmlns:context="http://www.springframework.org/schema/context" xmlns:p="http://www.springframework.org/schema/p"
  4.         xmlns:aop="http://www.springframework.org/schema/aop" xmlns:tx="http://www.springframework.org/schema/tx"
  5.         xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
  6.         xsi:schemaLocation="http://www.springframework.org/schema/beans http://www.springframework.org/schema/beans/spring-beans-4.0.xsd
  7.         http://www.springframework.org/schema/context http://www.springframework.org/schema/context/spring-context-4.0.xsd
  8.         http://www.springframework.org/schema/aop http://www.springframework.org/schema/aop/spring-aop-4.0.xsd http://www.springframework.org/schema/tx http://www.springframework.org/schema/tx/spring-tx-4.0.xsd
  9.         http://www.springframework.org/schema/util http://www.springframework.org/schema/util/spring-util-4.0.xsd">
  10.        
  11.         <context:property-placeholder location="classpath:database.properties"></context:property-placeholder>
  12.         <bean id="dataSource" class="com.alibaba.druid.pool.DruidDataSource">
  13.                 <property name="driverClassName" value="${jdbc.driver}"></property>
  14.                 <property name="Url" value="${jdbc.url}"></property>
  15.                 <property name="username" value="${jdbc.username}"></property>
  16.                 <property name="password" value="${jdbc.password}"></property>
  17.         </bean>
  18.         <!-- 设置SqlSessionFactory -->
  19.         <bean class="org.mybatis.spring.SqlSessionFactoryBean">
  20.                 <!-- 设置MyBatis中心设置文件 -->
  21.                 <property name="configLocation" value="classpath:mybatis/SqlMapConfig.xml" />
  22.                 <!-- 设置数据源 -->
  23.                 <property name="dataSource" ref="dataSource" />
  24.         </bean>
  25.         <!-- 设置Mapper扫描 -->
  26.         <bean class="org.mybatis.spring.mapper.MapperScannerConfigurer">
  27.                 <!-- 设置Mapper扫描包 -->
  28.                 <property name="basePackage"  value="com.mhys.crm.dao" />
  29.         </bean>
  30.         <!-- 设置事件办理器 -->
  31.                 <bean id="transactionManager" class="org.springframework.jdbc.datasource.DataSourceTransactionManager">
  32.                         <property name="dataSource" ref="dataSource"></property>
  33.                 </bean>
  34.                 <!-- 开启注解方法办理AOP事件 -->
  35.                 <tx:annotation-driven transaction-manager="transactionManager" />
  36.        
  37. </beans>
复造代码
applicationContext-service.xml

  1. <?xml version="1.0" encoding="UTF-8"?>
  2. <beans xmlns="http://www.springframework.org/schema/beans"
  3.         xmlns:context="http://www.springframework.org/schema/context" xmlns:p="http://www.springframework.org/schema/p"
  4.         xmlns:aop="http://www.springframework.org/schema/aop" xmlns:tx="http://www.springframework.org/schema/tx"
  5.         xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
  6.         xsi:schemaLocation="http://www.springframework.org/schema/beans http://www.springframework.org/schema/beans/spring-beans-4.0.xsd
  7.         http://www.springframework.org/schema/context http://www.springframework.org/schema/context/spring-context-4.0.xsd
  8.         http://www.springframework.org/schema/aop http://www.springframework.org/schema/aop/spring-aop-4.0.xsd http://www.springframework.org/schema/tx http://www.springframework.org/schema/tx/spring-tx-4.0.xsd
  9.         http://www.springframework.org/schema/util http://www.springframework.org/schema/util/spring-util-4.0.xsd">
  10.     <!-- 设置Service扫描 -->
  11.         <context:component-scan base-package="com" />
  12.         <bean id="transactionManager" class="org.springframework.jdbc.datasource.DataSourceTransactionManager">
  13.                 <property name="dataSource" ref="dataSource"></property>
  14.         </bean>
  15.         <tx:annotation-driven transaction-manager="transactionManager" />
  16. </beans>
复造代码
spring-mvc.xml

  1. <?xml version="1.0" encoding="UTF-8"?>
  2. <beans xmlns="http://www.springframework.org/schema/beans"
  3.         xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xmlns:p="http://www.springframework.org/schema/p"
  4.         xmlns:context="http://www.springframework.org/schema/context"
  5.         xmlns:mvc="http://www.springframework.org/schema/mvc"
  6.         xsi:schemaLocation="http://www.springframework.org/schema/beans http://www.springframework.org/schema/beans/spring-beans-4.0.xsd
  7.         http://www.springframework.org/schema/mvc http://www.springframework.org/schema/mvc/spring-mvc-4.0.xsd
  8.         http://www.springframework.org/schema/context http://www.springframework.org/schema/context/spring-context-4.0.xsd">
  9.     <!-- 设置Controller扫描 -->
  10.         <context:component-scan base-package="com.mhys.crm.controller" />
  11.         <mvc:annotation-driven />
  12.         <bean class="org.springframework.web.servlet.view.InternalResourceViewResolver">
  13.                 <property name="prefix" value="/WEB-INF/jsp/" />
  14.                 <property name="suffix" value=".jsp" />
  15.         </bean>
  16. </beans>
复造代码
> database.properties

  1. jdbc.url=jdbc:mysql://localhost:3306/hospital_db?useUnicode=true&characterEncoding=UTF-8&useSSL=false
  2. jdbc.username=root
  3. jdbc.password=123456
  4. jdbc.driver=com.mysql.jdbc.Driver
复造代码
=JSP页里

> /WEB-INF/jsp/

addInfo.jsp

  1. <%@ page language="java" contentType="text/html; charset=utf-8"
  2.     pageEncoding="utf-8"%>
  3. <!DOCTYPE html>
  4. <html>
  5.         <head>
  6.                 <meta charset="utf-8">
  7.                 <title>登记</title>
  8.         </head>
  9.         <body>
  10.                 <form action="insert.do" method="post">
  11.                         <table border="" cellspacing="" cellpadding="">
  12.                                
  13.                                 <tr>
  14.                                         <td>姓名</td>
  15.                                         <td><input type="text" name="name" value="" /></td>
  16.                                 </tr>
  17.                                 <tr>
  18.                                         <td>性别</td>
  19.                                         <td><input type="text" name="sex" value=""/></td>
  20.                                 </tr>
  21.                                 <tr>
  22.                                         <td>年齿</td>
  23.                                         <td><input type="text" name="age" value=""/></td>
  24.                                 </tr>
  25.                                 <tr>
  26.                                         <td>德律风</td>
  27.                                         <td><input type="text" name="phone" value=""/></td>
  28.                                 </tr>
  29.                                 <tr>
  30.                                         <td>医师种别</td>
  31.                                         <td><input type="text" name="department" value=""/></td>
  32.                                 </tr>
  33.                                 <tr>
  34.                                         <td>价钱</td>
  35.                                         <td><input type="text" name="price" value=""/></td>
  36.                                 </tr>
  37.                                 <tr>
  38.                                         <td>登记工夫</td>
  39.                                         <td><input type="text" name="registerTime" value=""/></td>
  40.                                 </tr>
  41.                                
  42.                         </table>
  43.                         <input type="submit" value="肯定" />
  44.                 </form>
  45.         </body>
  46. </html>
复造代码
info.jsp

  1. <%@ page language="java" contentType="text/html; charset=UTF-8"
  2.     pageEncoding="UTF-8"%>
  3. <%@ taglib prefix="c" uri="http://java.sun.com/jsp/jstl/core"%>
  4. <%@ taglib prefix="fmt" uri="http://java.sun.com/jsp/jstl/fmt"%>
  5. <!DOCTYPE html>
  6. <html>
  7. <head>
  8. <meta charset="UTF-8">
  9. <title>病院救治登记体系</title>
  10. <style type="text/css">
  11.         form{
  12.                 padding: 20px;
  13.         }
  14.         #warp{
  15.                 margin:0 auto;
  16.                 width: 60%
  17.         }
  18. </style>
  19. </head>
  20. <body>
  21.         <h1 align="center">病院救治登记体系</h1>
  22.         <div id="warp">
  23.                 <form action="list.do">
  24.                 患者姓名:<input type="text" name="name">     
  25.                 医师种别:
  26.                                 <select name="type">
  27.                                         <option value="" >=没有限=</option>
  28.                                         <option value="专家医师" >专家医师</option>
  29.                                         <option value="一般医师" >一般医师</option>
  30.                                         <option value="副主任医师" >副主任医师</option>
  31.                                 </select>     
  32.                 科室:<input type="text" name="dep">     
  33.                 <input type="submit" value="查询">   
  34.                 <input type="button" value="登记" onclick="add()">
  35.         </form>
  36.         <table style="margin-bottom: 30px;" width="100%" border="1px" cellpadding="11" cellspacing="0">
  37.                 <tr>
  38.                         <th>编号</th>
  39.                         <th>姓名</th>
  40.                         <th>性别</th>
  41.                         <th>年齿</th>
  42.                         <th>德律风</th>
  43.                         <th>科室</th>
  44.                         <th>医师种别</th>
  45.                         <th>价钱</th>
  46.                         <th>登记工夫</th>
  47.                         <th>形态</th>
  48.                         <th>操纵</th>
  49.                 </tr>
  50.                 <c:forEach var="list" items="${selctAll }">
  51.                         <tr>
  52.                                 <td>${list.id }</td>
  53.                                 <td>${list.name }</td>
  54.                                 <td>${list.sex }</td>
  55.                                 <td>${list.age }</td>
  56.                                 <td>${list.phone }</td>
  57.                                 <td>${list.department }</td>
  58.                                 <td>${list.type }</td>
  59.                                 <td>${list.price }</td>
  60.                                 <td><fmt:formatDate value="${list.registerTime }" pattern="yyyy-MM-dd"/></td>
  61.                                 <td>
  62.                                         <c:if test="${list.state==0}">
  63.                                              已救治
  64.                                      </c:if>
  65.                                         <c:if test="${list.state==1}">
  66.                                              已救治
  67.                                      </c:if>
  68.                                 </td>
  69.                                 <td>
  70.                                         <c:if test="${list.state==0}">
  71.                                              <a href="javascript:if(confirm(&#39;的确要核销该登记疑息吗?&#39;))location=&#39;upd.do?id=${list.id }&#39;">核销</a>
  72.                                      </c:if>
  73.                                         <%-- <c:if test="${list.state==1}">
  74.                                              已救治
  75.                                      </c:if> --%>
  76.                                 </td>
  77.                         </tr>
  78.                 </c:forEach>
  79.         </table>
  80.         </div>
  81.         <script type="text/javascript">
  82.         function add() {
  83.                 location.href="adds.do";
  84.         }
  85.         </script>
  86. </body>
  87. </html>
复造代码
index.jsp

  1. <%@ page language="java" import="java.util.*" pageEncoding="UTF-8"%>
  2. <!DOCTYPE html>
  3. <%
  4. String path = request.getContextPath();
  5. String basePath = request.getScheme()+"://"+request.getServerName()+":"+request.getServerPort()+path;
  6. %>
  7. <html>
  8. <head>
  9. <meta http-equiv="Content-Type" content="text/html; charset=UTF-8">
  10. <title>XXX体系</title>
  11. </head>
  12. <body>
  13. <script>
  14.         window.location.href="<%=basePath%>/select.do";
  15. </script>
  16. </body>
  17. </html>
复造代码
免责声明:假如进犯了您的权益,请联络站少,我们会实时删除侵权内乱容,感谢协作!
1、本网站属于个人的非赢利性网站,转载的文章遵循原作者的版权声明,如果原文没有版权声明,按照目前互联网开放的原则,我们将在不通知作者的情况下,转载文章;如果原文明确注明“禁止转载”,我们一定不会转载。如果我们转载的文章不符合作者的版权声明或者作者不想让我们转载您的文章的话,请您发送邮箱:Cdnjson@163.com提供相关证明,我们将积极配合您!
2、本网站转载文章仅为传播更多信息之目的,凡在本网站出现的信息,均仅供参考。本网站将尽力确保所提供信息的准确性及可靠性,但不保证信息的正确性和完整性,且不对因信息的不正确或遗漏导致的任何损失或损害承担责任。
3、任何透过本网站网页而链接及得到的资讯、产品及服务,本网站概不负责,亦不负任何法律责任。
4、本网站所刊发、转载的文章,其版权均归原作者所有,如其他媒体、网站或个人从本网下载使用,请在转载有关文章时务必尊重该文章的著作权,保留本网注明的“稿件来源”,并自负版权等法律责任。
回复 关闭延时

使用道具 举报

 
您需要登录后才可以回帖 登录 | 立即注册

本版积分规则