Commit fb7552d251c66ae40b1d50359182b374a7c1e3d9

Authored by [wangbo]
1 parent ee54c3651b

update

Showing 3 changed files with 34 additions and 6 deletions

platform-dal/src/main/java/com/lyms/platform/pojo/WxMeasureInfoModel.java View file @ fb7552d
... ... @@ -10,7 +10,6 @@
10 10 import java.util.Map;
11 11  
12 12 /**
13   - *
14 13 * @Author dongqin
15 14 * @Description 小程序孕妇宫高、腹围等/儿保一般测量信息录入
16 15 * @Date 14:34 2019/5/30
... ... @@ -50,6 +49,16 @@
50 49 private List<Map> babyInfos;
51 50  
52 51 private List<Map> yumInfos;
  52 +
  53 + private String doctorId;
  54 +
  55 + public String getDoctorId() {
  56 + return doctorId;
  57 + }
  58 +
  59 + public void setDoctorId(String doctorId) {
  60 + this.doctorId = doctorId;
  61 + }
53 62  
54 63 public String getPid() {
55 64 return pid;
platform-operate-api/src/main/java/com/lyms/platform/operate/web/controller/AntenatalExaminationController.java View file @ fb7552d
... ... @@ -433,8 +433,9 @@
433 433 @RequestParam(value = "fhr") String fhr,
434 434 @RequestParam(value = "pid") String pid,
435 435 @RequestParam(value = "hospitalId") String hospitalId,
436   - @RequestParam(value = "nextTime") String nextTime) {
437   - return antExRecordFacade.inputWxData(fuh, abdominalGirth, fhr, pid, hospitalId, nextTime);
  436 + @RequestParam(value = "nextTime") String nextTime,
  437 + @RequestParam(value = "doctorId") String doctorId) {
  438 + return antExRecordFacade.inputWxData(fuh, abdominalGirth, fhr, pid, hospitalId, nextTime, doctorId);
438 439 }
439 440  
440 441 /**
platform-operate-api/src/main/java/com/lyms/platform/operate/web/facade/AntExRecordFacade.java View file @ fb7552d
... ... @@ -84,6 +84,9 @@
84 84 @Autowired
85 85 private ModularFunctionConfigService modularFunctionConfigServcie;
86 86  
  87 + @Autowired
  88 + private AntenatalExaminationService antenatalExaminationService;
  89 +
87 90 public void syncAntRecordToList(String hospitalId) {
88 91 recordService.syncAntRecordToList(hospitalId);
89 92 }
... ... @@ -880,7 +883,7 @@
880 883 /**
881 884 * 小程序产检录入
882 885 */
883   - public BaseResponse inputWxData(String fuh, String abdominalGirth, String fhr, String pid, String hospitalId, String nextTime) {
  886 + public BaseResponse inputWxData(String fuh, String abdominalGirth, String fhr, String pid, String hospitalId, String nextTime, String doctorId) {
884 887 WxMeasureInfoModel wxMeasureInfo = new WxMeasureInfoModel();
885 888 boolean falg = true;
886 889 String value = null;
... ... @@ -903,6 +906,20 @@
903 906 for (AntenatalExaminationModel model : examinationModel) {
904 907 if (StringUtils.isNotEmpty(DateUtil.getyyyy_MM_dd(model.getCheckDate())) &&
905 908 DateUtil.getyyyy_MM_dd(new Date()).equals(DateUtil.getyyyy_MM_dd(model.getCheckDate()))) {
  909 + model.setGongGao(fuh);
  910 + model.setAbdominalCircumference(abdominalGirth);
  911 + List<String> list = JsonUtil.jkstr2Obj(fhr, List.class);
  912 + if (CollectionUtils.isNotEmpty(list)) {
  913 + List<MatDeliverAddRequest.Placenta> placentaList = new ArrayList<>();
  914 + for (String l : list) {
  915 + MatDeliverAddRequest.Placenta placenta = new MatDeliverAddRequest.Placenta();
  916 + placenta.setHeartRate(Double.parseDouble(l));
  917 + placentaList.add(placenta);
  918 + }
  919 + model.setTireData(placentaList);
  920 + model.setTireNumber(list.size() + "");
  921 + }
  922 + antenatalExaminationService.updateOneAnt(model, model.getId());
906 923 falg = false;
907 924 }
908 925 }
... ... @@ -915,7 +932,7 @@
915 932 if (null != antExChuModel) {
916 933 AntExAddRequest antExAddRequest = new AntExAddRequest();
917 934 antExAddRequest.setCheckDate(DateUtil.getyyyy_MM_dd(new Date()));
918   - antExAddRequest.setCheckDoctor("1000000185");
  935 + antExAddRequest.setCheckDoctor(doctorId);
919 936 antExAddRequest.setDiagnosisOther(DateUtil.getWeekDesc(patients.getLastMenses(), new Date()));// diagnosisOther: "29+4周妊娠 "
920 937 antExAddRequest.setCurrentDueDate(DateUtil.getWeekDesc(patients.getLastMenses(), new Date()));//currentDueDate: "孕29周+4天"
921 938 antExAddRequest.setGuide("个人卫生 受激素影响怀孕后肤质与孕前不一样,保养皮肤请做好日常清洁并避免使用刺激性的护肤品与保养品。" +
... ... @@ -941,7 +958,7 @@
941 958 antExAddRequest.setTireData(placentaList);
942 959 antExAddRequest.setTireNumber(list.size() + "");
943 960 }
944   - antenatalExaminationFacade.addOneAntEx(antExAddRequest, 1000000185);
  961 + antenatalExaminationFacade.addOneAntEx(antExAddRequest, Integer.parseInt(doctorId));
945 962 }
946 963 }
947 964 }
... ... @@ -961,6 +978,7 @@
961 978 wxMeasureInfo.setCreateTime(new Date());
962 979 wxMeasureInfo.setPid(pid);
963 980 wxMeasureInfo.setHospitalId(hospitalId);
  981 + wxMeasureInfo.setDoctorId(doctorId);
964 982 this.updateNexCheckTime(pid, yumInfosMap.get("nextTime").toString());
965 983 mongoTemplate.insert(wxMeasureInfo);
966 984 } else {