Commit e72778422199d336b626bbed16b49e1379f4e61c

Authored by hujiaqi

Merge remote-tracking branch 'origin/master'

Showing 6 changed files

platform-biz-patient-service/src/main/java/com/lyms/platform/biz/service/AntExRecordService.java View file @ e727784
... ... @@ -109,6 +109,7 @@
109 109 AntExRecordQuery antExRecordQuery = new AntExRecordQuery();
110 110 antExRecordQuery.setPid(record.getPid());
111 111 antExRecordQuery.setcId(record.getCheckDoctor());
  112 + antExRecordQuery.setfId(record.getfId());
112 113 Integer count = count(antExRecordQuery);
113 114 if (null == count || 0 == count) {
114 115 antExRecordDao.addOneRecord(record);
... ... @@ -130,6 +131,7 @@
130 131 AntExRecordQuery antExRecordQuery = new AntExRecordQuery();
131 132 antExRecordQuery.setPid(record.getPid());
132 133 antExRecordQuery.setcId(record.getCheckDoctor());
  134 + antExRecordQuery.setfId(record.getfId());
133 135 Integer count = count(antExRecordQuery);
134 136 if (null == count || 0 == count) {
135 137 antExRecordDao.addOneRecord(record);
... ... @@ -212,6 +214,7 @@
212 214 antExRecordModel.setModified(new Date());
213 215 antExRecordModel.setBarCode(antEx.getBarCode());
214 216 antExRecordModel.setNextCheckTime(antEx.getNextCheckTime());
  217 + antExRecordModel.setCheckTime(antEx.getCheckDate());
215 218 Patients patients = patientsService.findOnePatientById(antEx.getParentId());
216 219 if (null != patients) {
217 220 if (patients.getType() == 1) {
... ... @@ -219,6 +222,7 @@
219 222 } else {
220 223 antExRecordModel.setStatus(1);
221 224 }
  225 + antExRecordModel.setCardNo(patients.getCardNo());
222 226 antExRecordModel.setAddressRegister(patients.getAddressRegister());
223 227 antExRecordModel.setProvinceRegisterId(patients.getProvinceRegisterId());
224 228 antExRecordModel.setCityRegisterId(patients.getCityRegisterId());
... ... @@ -232,7 +236,7 @@
232 236 antExRecordModel.setLastMenses(patients.getLastMenses());
233 237 antExRecordModel.setDueDate(patients.getDueDate());
234 238 antExRecordModel.setName(patients.getUsername());
235   - antExRecordModel.sethScore(patients.getRiskScore());
  239 + antExRecordModel.sethScore(null==patients.getRiskScore()?0:patients.getRiskScore());
236 240 antExRecordModel.sethRisk(patients.getRiskFactorId());
237 241 antExRecordModel.sethLevel(JsonUtil.toList(patients.getRiskLevelId(), List.class));
238 242 } else {
... ... @@ -252,6 +256,7 @@
252 256 antExRecordModel.setPid(antExChuModel.getPid());
253 257 antExRecordModel.setModified(new Date());
254 258 antExRecordModel.setBarCode(antExChuModel.getBarCode());
  259 + antExRecordModel.setCheckTime(antExChuModel.getCheckTime());
255 260 antExRecordModel.setNextCheckTime(antExChuModel.getNextCheckTime());
256 261 Patients patients = patientsService.findOnePatientById(antExChuModel.getParentId());
257 262 if (null != patients) {
... ... @@ -260,6 +265,7 @@
260 265 } else {
261 266 antExRecordModel.setStatus(1);
262 267 }
  268 + antExRecordModel.setCardNo(patients.getCardNo());
263 269 antExRecordModel.setAddressRegister(patients.getAddressRegister());
264 270 antExRecordModel.setProvinceRegisterId(patients.getProvinceRegisterId());
265 271 antExRecordModel.setCityRegisterId(patients.getCityRegisterId());
... ... @@ -273,7 +279,7 @@
273 279 antExRecordModel.setLastMenses(patients.getLastMenses());
274 280 antExRecordModel.setDueDate(patients.getDueDate());
275 281 antExRecordModel.setName(patients.getUsername());
276   - antExRecordModel.sethScore(patients.getRiskScore());
  282 + antExRecordModel.sethScore(null==patients.getRiskScore()?0:patients.getRiskScore());
277 283 antExRecordModel.sethRisk(patients.getRiskFactorId());
278 284 antExRecordModel.sethLevel(JsonUtil.toList(patients.getRiskLevelId(), List.class));
279 285 } else {
platform-biz-patient-service/src/main/java/com/lyms/platform/biz/service/PatientsService.java View file @ e727784
... ... @@ -283,6 +283,15 @@
283 283 antExRecordModel.setDueDate(patients.getDueDate());
284 284 antExRecordModel.setName(patients.getUsername());
285 285 antExRecordModel.setBrith(patients.getBirth());
  286 + antExRecordModel.setPhone(patients.getPhone());
  287 + antExRecordModel.setAddressRegister(patients.getAddressRegister());
  288 + antExRecordModel.setProvinceRegisterId(patients.getProvinceRegisterId());
  289 + antExRecordModel.setCityRegisterId(patients.getCityRegisterId());
  290 + antExRecordModel.setAreaRegisterId(patients.getAreaRegisterId());
  291 + antExRecordModel.setStreetRegisterId(patients.getStreetRegisterId());
  292 + antExRecordModel.setBuildDoctor(patients.getBookbuildingDoctor());
  293 + antExRecordModel.setCardNo(patients.getCardNo());
  294 +
286 295 Patients dbPatients = findOnePatientById(patients.getId());
287 296 if(dbPatients.getType()==1){
288 297 antExRecordModel.setStatus(2);
platform-dal/src/main/java/com/lyms/platform/pojo/AntExRecordModel.java View file @ e727784
... ... @@ -24,7 +24,9 @@
24 24 private String fId;
25 25 //条码号
26 26 private String barCode;
  27 + private String cardNo;
27 28  
  29 +
28 30 private String parentId;
29 31  
30 32 private String hospitalId;
... ... @@ -70,6 +72,13 @@
70 72 private String areaRegisterId;
71 73 private String streetRegisterId;
72 74  
  75 + public String getCardNo() {
  76 + return cardNo;
  77 + }
  78 +
  79 + public void setCardNo(String cardNo) {
  80 + this.cardNo = cardNo;
  81 + }
73 82  
74 83 public String getAddressRegister() {
75 84 return addressRegister;
platform-dal/src/main/java/com/lyms/platform/query/AntExRecordQuery.java View file @ e727784
... ... @@ -220,6 +220,12 @@
220 220 if (null != parentId) {
221 221 condition = condition.and("parentId", parentId, MongoOper.IS);
222 222 }
  223 + if (null != cardNo) {
  224 + condition = condition.and("cardNo", cardNo, MongoOper.IS);
  225 + }
  226 + if (null != phone) {
  227 + condition = condition.and("phone", phone, MongoOper.IS);
  228 + }
223 229 if (null != id) {
224 230 condition = condition.and("id", id, MongoOper.IS);
225 231 }
platform-operate-api/src/main/java/com/lyms/platform/operate/web/facade/AntExRecordFacade.java View file @ e727784
... ... @@ -81,7 +81,7 @@
81 81 antExRecordQuery.setrFactor(antExManagerQueryRequest.getRiskFactorId());
82 82 antExRecordQuery.setLevelId(antExManagerQueryRequest.getLevel());
83 83 antExRecordQuery.setBarCode(antExManagerQueryRequest.getBarCode());
84   -
  84 + antExRecordQuery.setCardNo(antExManagerQueryRequest.getCardNo());
85 85 //产检日期
86 86 if (org.apache.commons.lang.StringUtils.isNotEmpty(antExManagerQueryRequest.getcTime())) {
87 87 String nextDateStr = antExManagerQueryRequest.getcTime();
platform-operate-api/src/main/java/com/lyms/platform/operate/web/result/AntExManagerResult.java View file @ e727784
... ... @@ -106,9 +106,9 @@
106 106 setCheckTime(DateUtil.getyyyy_MM_dd(e.getCheckTime()));
107 107 setName(e.getName());
108 108 setAge(DateUtil.getAge(e.getBrith()) + "");
109   - setPhone(e.getPhone());
  109 + setPhone(StringUtils.encryPhone(e.getPhone()));
110 110 setBarCode(e.getBarCode());
111   - int days = DateUtil.getDays(e.getCheckTime(), e.getLastMenses());
  111 + int days = DateUtil.getDays(e.getLastMenses(),e.getCheckTime() );
112 112 setcDueWeek(StringUtils.dueWeek(days));
113 113 setDueDate(DateUtil.getyyyy_MM_dd(e.getDueDate()));
114 114 setRiskScore(e.gethScore() + "");