Commit 4dc8bb0aa56370af35b3840a988eae6f832c1150

Authored by gengxiaokai
1 parent 86841a66f4

秦皇岛冠新公卫接口

Showing 1 changed file with 27 additions and 12 deletions

platform-operate-api/src/main/java/com/lyms/hospitalapi/qhdfy/QhdJbgwInterface.java View file @ 4dc8bb0
... ... @@ -463,7 +463,7 @@
463 463 map.put("GESTDAYS",String.valueOf(day));
464 464  
465 465 Map<String, Object> mapcc = new HashMap<>();
466   - findProcess(data.getProdprocess(),mapcc);
  466 + findProcess(data.getProdprocess(), mapcc);
467 467 if(StringUtils.isNotEmpty(mapcc.get("one").toString())){
468 468 int oShi = mapcc.get("one").toString().indexOf("时");
469 469 if(oShi == -1){
470 470  
471 471  
472 472  
473 473  
474 474  
... ... @@ -959,29 +959,44 @@
959 959 }else{
960 960 map.put("MOTHERBIRTHDATE",null);
961 961 }
962   - if(newbornVisit.getCheckTimeDesc() != null){
963   - int days = Integer.parseInt(newbornVisit.getCheckTimeDesc().substring(1, newbornVisit.getCheckTimeDesc().indexOf("周")));
964   - if(days < 7){
  962 + if(StringUtils.isNotEmpty(newbornVisit.getCheckTimeDesc())){
  963 + int zhou = newbornVisit.getCheckTimeDesc().indexOf("周");
  964 + if(-1 == zhou){
965 965 map.put("BIRTHGESTWEEKS",null);
966   - map.put("BIRTHGESTDAYS",String.valueOf(days));
  966 + int tian = newbornVisit.getCheckTimeDesc().indexOf("天");
  967 + if(-1 == tian){
  968 + map.put("BIRTHGESTWEEKS",null);
  969 + map.put("BIRTHGESTDAYS",null);
  970 + }else{
  971 + int day = Integer.parseInt(newbornVisit.getCheckTimeDesc().substring(0, tian));
  972 + map.put("BIRTHGESTDAYS",String.valueOf(day));
  973 + }
  974 +
967 975 }else{
968   - int week = days/7;
969   - int day = days%7;
970   - map.put("BIRTHGESTWEEKS",String.valueOf(week));
971   - map.put("BIRTHGESTDAYS",String.valueOf(day));
  976 + int days = Integer.parseInt(newbornVisit.getCheckTimeDesc().substring(0, newbornVisit.getCheckTimeDesc().indexOf("周")));
  977 + if(days < 7){
  978 + map.put("BIRTHGESTWEEKS",null);
  979 + map.put("BIRTHGESTDAYS",String.valueOf(days));
  980 + }else{
  981 + int week = days/7;
  982 + int day = days%7;
  983 + map.put("BIRTHGESTWEEKS",String.valueOf(week));
  984 + map.put("BIRTHGESTDAYS",String.valueOf(day));
  985 + }
972 986 }
  987 +
973 988 }else{
974 989 map.put("BIRTHGESTWEEKS",null);
975 990 map.put("BIRTHGESTDAYS",null);
976 991 }
977   - String fmhospital = "";
  992 + /*String fmhospital = "";
978 993 if (org.apache.commons.lang.StringUtils.isNotEmpty(model.getDeliverOrg())) {
979 994 Organization organization = organizationService.getOrganization(Integer.parseInt(model.getDeliverOrg()));
980 995 if (organization != null && organization.getYn() == YnEnums.YES.getId()) {
981 996 fmhospital = organization.getName();
982 997 }
983   - }
984   - map.put("DELIVERYORGNAME",fmhospital);
  998 + }*/
  999 + map.put("DELIVERYORGNAME",model.getDeliverOrg());
985 1000 map.put("ASPHYXIACODE","1");
986 1001 map.put("APGARSCORECODE",null);
987 1002 map.put("APGARSCORE",null);