Commit 4c616061750ebbab3cc0c0b9949458a1482af5e0
1 parent
4b74aaed05
Exists in
master
and in
6 other branches
国家出生证对接:d201 接口/getMatDeliverData,处理村和门牌号截取
Showing 1 changed file with 15 additions and 2 deletions
platform-operate-api/src/main/java/com/lyms/platform/operate/web/worker/FmListWorker.java
View file @
4c61606
... | ... | @@ -100,8 +100,21 @@ |
100 | 100 | String MQZZXQ=CommonsHelper.getName1(patient.getAreaRegisterId(), basicConfigService); |
101 | 101 | result.put("MQZZXQ",MQZZXQ );//母亲住址- 县 |
102 | 102 | result.put("MQZZXZ", CommonsHelper.getName1(patient.getStreetRegisterId(), basicConfigService));//母亲住址-乡 |
103 | - result.put("MQZZCL", StringUtils.isEmpty(patient.getVillageRegister())?"":patient.getVillageRegister());//母亲住址- 村 | |
104 | - result.put("MQZZMPH", StringUtils.isEmpty(patient.getAddressRegister())?"":patient.getAddressRegister());//母亲住址-门牌号码 | |
103 | + String MQZZCL=""; | |
104 | + String MQZZMPH=""; | |
105 | + if(StringUtils.isNotEmpty(patient.getAddressRegister())){ | |
106 | + MQZZMPH=patient.getAddressRegister(); | |
107 | + } | |
108 | + //系统中村是后加字段。为了原系统展示,村和详细地址是拼接在一起的。这里要取门牌号需要截取掉村。 | |
109 | + if (StringUtils.isNotEmpty(patient.getVillageRegister())) { | |
110 | + MQZZCL=patient.getVillageRegister(); | |
111 | + if(StringUtils.isNotEmpty(patient.getAddressRegister()) && | |
112 | + patient.getAddressRegister().length()>MQZZCL.length()){ | |
113 | + MQZZMPH=patient.getAddressRegister().substring(MQZZCL.length()); | |
114 | + } | |
115 | + } | |
116 | + result.put("MQZZCL", MQZZCL);//母亲住址- 村 | |
117 | + result.put("MQZZMPH", MQZZMPH);//母亲住址-门牌号码 | |
105 | 118 | result.put("MQZZQHDM", organizationService.getAreaCode(MQZZXQ));//产妇现住地址-行政区划代码 |
106 | 119 | String YLJGMC=""; |
107 | 120 | String YLJGDZSZ=""; |