Commit 52ba4a8301b536954b5e177d3da043f0ce74545a
1 parent
ae690f8590
Exists in
master
and in
8 other branches
xinle his view change
Showing 2 changed files with 26 additions and 16 deletions
platform-operate-api/src/main/java/com/lyms/hospitalapi/pojo/PregPatientinfo.java
View file @
52ba4a8
... | ... | @@ -27,6 +27,15 @@ |
27 | 27 | private String P_IDNUM; |
28 | 28 | private Date P_BIRTHDAY; |
29 | 29 | private Date CREATED; |
30 | + private String SICKTYPE; | |
31 | + | |
32 | + public String getSICKTYPE() { | |
33 | + return SICKTYPE; | |
34 | + } | |
35 | + | |
36 | + public void setSICKTYPE(String SICKTYPE) { | |
37 | + this.SICKTYPE = SICKTYPE; | |
38 | + } | |
30 | 39 | |
31 | 40 | public String getP_ID() { |
32 | 41 | return P_ID; |
platform-operate-api/src/main/java/com/lyms/hospitalapi/v2/HisService.java
View file @
52ba4a8
1 | 1 | package com.lyms.hospitalapi.v2; |
2 | 2 | |
3 | +import com.lyms.hospitalapi.pojo.PregPatientinfo; | |
3 | 4 | import com.lyms.platform.common.utils.DateUtil; |
4 | 5 | import org.apache.commons.dbutils.DbUtils; |
5 | 6 | import org.apache.commons.dbutils.QueryRunner; |
6 | 7 | |
7 | 8 | |
... | ... | @@ -26,16 +27,16 @@ |
26 | 27 | Connection conn = ConnTools.makeHisConnection(); |
27 | 28 | QueryRunner queryRunner = new QueryRunner(); |
28 | 29 | try { |
29 | - List<XinlePregPatientinfo> list = queryRunner.query(conn, "select * from v_preg_patientinfo where IC_CARD_ID = '"+cardNo+"'", new BeanListHandler<XinlePregPatientinfo>(XinlePregPatientinfo.class)); | |
30 | + List<PregPatientinfo> list = queryRunner.query(conn, "select * from v_preg_patientinfo where IC_CARD_ID = '"+cardNo+"'", new BeanListHandler<PregPatientinfo>(PregPatientinfo.class)); | |
30 | 31 | if (list.size() > 0) { |
31 | - XinlePregPatientinfo info = list.get(0); | |
32 | + PregPatientinfo info = list.get(0); | |
32 | 33 | map.put("sickType", info.getSICKTYPE()); |
33 | - map.put("sickId", info.getSICK_ID()); | |
34 | - map.put("sex", info.getSEX()); | |
35 | - map.put("name", info.getNAME()); | |
36 | - map.put("cardNo", info.getIC_CARD_ID()); | |
37 | - map.put("phone", info.getASSOCIATION_PHONE()); | |
38 | - map.put("birth", DateUtil.getyyyy_MM_dd(info.getBIRTHDATE())); | |
34 | + map.put("bhnum", info.getP_BHNUM()); | |
35 | + map.put("sex", info.getP_SEX()); | |
36 | + map.put("name", info.getP_NAME()); | |
37 | + map.put("cardNo", info.getP_CARDNO()); | |
38 | + map.put("phone", info.getP_MOBILEPHONE()); | |
39 | + map.put("birth", DateUtil.getyyyy_MM_dd(info.getP_BIRTHDAY())); | |
39 | 40 | } |
40 | 41 | DbUtils.closeQuietly(conn); |
41 | 42 | } catch (SQLException e) { |
42 | 43 | |
43 | 44 | |
... | ... | @@ -52,17 +53,17 @@ |
52 | 53 | Connection conn = ConnTools.makeHisConnection(); |
53 | 54 | QueryRunner queryRunner = new QueryRunner(); |
54 | 55 | try { |
55 | - List<XinlePregPatientinfo> list = queryRunner.query(conn, "select * from v_preg_patientinfo where IC_CARD_ID = '"+cardNo+"'", new BeanListHandler<XinlePregPatientinfo>(XinlePregPatientinfo.class)); | |
56 | + List<PregPatientinfo> list = queryRunner.query(conn, "select * from v_preg_patientinfo where P_CARDNO = '"+cardNo+"'", new BeanListHandler<PregPatientinfo>(PregPatientinfo.class)); | |
56 | 57 | if (list.size() > 0) { |
57 | - for (XinlePregPatientinfo info:list) { | |
58 | + for (PregPatientinfo info:list) { | |
58 | 59 | Map<String,Object> map = new HashMap<>(); |
59 | 60 | map.put("sickType", info.getSICKTYPE()); |
60 | - map.put("sickId", info.getSICK_ID()); | |
61 | - map.put("sex", info.getSEX()); | |
62 | - map.put("name", info.getNAME()); | |
63 | - map.put("cardNo", info.getIC_CARD_ID()); | |
64 | - map.put("phone", info.getASSOCIATION_PHONE()); | |
65 | - map.put("birth", DateUtil.getyyyy_MM_dd(info.getBIRTHDATE())); | |
61 | + map.put("bhnum", info.getP_BHNUM()); | |
62 | + map.put("sex", info.getP_SEX()); | |
63 | + map.put("name", info.getP_NAME()); | |
64 | + map.put("cardNo", info.getP_CARDNO()); | |
65 | + map.put("phone", info.getP_MOBILEPHONE()); | |
66 | + map.put("birth", DateUtil.getyyyy_MM_dd(info.getP_BIRTHDAY())); | |
66 | 67 | result.add(map); |
67 | 68 | } |
68 | 69 | } |