Commit 00d82d47 authored by 韩桐桐's avatar 韩桐桐

fix(jg):使用登记保存接口添加使用登记表字段

parent abdc1029
......@@ -155,6 +155,7 @@ public class CommonServiceImpl implements ICommonService {
private static final String ADMINISTRATION_UNIT = "行政审批局";
// 业务通用发起——基本信息
private static final String basic = "basic";
private static final String useRegFormUpload = "useRegFormUpload";
private static final String HISTORY_EQU_TYPE = "historyEquType";
private static final String SECOND = "second";
// 业务通用发起——告知单详情
......@@ -1220,6 +1221,7 @@ public class CommonServiceImpl implements ICommonService {
Map<String, Object> basicObj = (Map<String, Object>) map.get(basic);
Map<String, Object> noticeObj = (Map<String, Object>) map.get(notice);
Map<String, Object> techInfoObj = (Map<String, Object>) map.get(techInfo);
Map<String, Object> useRegFormUploadObj = (Map<String, Object>) map.get(useRegFormUpload);
Map<String, Object> provideMap = new HashMap<>();
String type = (String) basicObj.get("type");
......@@ -1258,6 +1260,7 @@ public class CommonServiceImpl implements ICommonService {
if (submitType.equals("1")) {
jsonObject.put("submit", Boolean.TRUE);
}
jsonObject.putAll(useRegFormUploadObj);
// 判断是否为车用气瓶使用登记或者设备使用登记
return "1".equals(businessScenarios) && CylinderTypeEnum.CYLINDER.getCode().equals(code) ?
jgVehicleInformationService.save(submitType, jsonObject) : jgUseRegistrationServiceImpl.save(jsonObject);
......
......@@ -609,6 +609,12 @@ public class JgUseRegistrationServiceImpl extends BaseService<JgUseRegistrationD
});
}
jgUseRegistration.setUseAddress(jgUseRegistration.getUseAddress() + map.get("address"));
Optional.ofNullable(map.get("useRegistrationFormFile"))
.map(JSONObject::toJSONString)
.ifPresent(jgUseRegistration::setUseRegistrationFormFile);
Optional.ofNullable(map.get("useRegistrationFormUrl"))
.map(String::valueOf)
.ifPresent(jgUseRegistration::setUseRegistrationFormUrl);
if (map.containsKey("type") && "edit".equals(String.valueOf(map.get("type")))) {
jgUseRegistration.setUseUnitCreditCode(null);
jgUseRegistration.setSequenceNbr(Long.valueOf(String.valueOf(map.get("sequenceNbr"))));
......@@ -883,7 +889,13 @@ public class JgUseRegistrationServiceImpl extends BaseService<JgUseRegistrationD
// 具体地址
useRegistration.setUseAddress("陕西省" + fullAddress + map.get("address"));
useRegistration.setOriginProjectContraptionIds((String) map.get("originProjectContraptionIds"));
// 使用登记表
Optional.ofNullable(map.get("useRegistrationFormFile"))
.map(JSONObject::toJSONString)
.ifPresent(useRegistration::setUseRegistrationFormFile);
Optional.ofNullable(map.get("useRegistrationFormUrl"))
.map(String::valueOf)
.ifPresent(useRegistration::setUseRegistrationFormUrl);
// 新增或编辑保存
if (StringUtils.isEmpty(useRegistration.getSequenceNbr())) {
ResponseModel<List<String>> listResponseModel = tzsServiceFeignClient.applicationFormCode(ApplicationFormTypeEnum.getCode.get(String.valueOf(map.get("businessCode"))), 1);
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment