Commit 0653dc25 authored by tianbo's avatar tianbo

Merge remote-tracking branch 'origin/develop_tzs_register' into develop_tzs_register

parents 2c502cf6 6fa9f161
...@@ -14,6 +14,7 @@ import com.yeejoin.amos.boot.module.jg.biz.service.impl.JgUseRegistrationManageS ...@@ -14,6 +14,7 @@ import com.yeejoin.amos.boot.module.jg.biz.service.impl.JgUseRegistrationManageS
import com.yeejoin.amos.boot.module.ymt.api.entity.IdxBizJgProjectContraption; import com.yeejoin.amos.boot.module.ymt.api.entity.IdxBizJgProjectContraption;
import io.swagger.annotations.Api; import io.swagger.annotations.Api;
import io.swagger.annotations.ApiOperation; import io.swagger.annotations.ApiOperation;
import org.apache.commons.lang3.StringUtils;
import org.springframework.beans.factory.annotation.Autowired; import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.util.ObjectUtils; import org.springframework.util.ObjectUtils;
import org.springframework.web.bind.annotation.*; import org.springframework.web.bind.annotation.*;
...@@ -199,17 +200,30 @@ public class JgUseRegistrationManageController extends BaseController { ...@@ -199,17 +200,30 @@ public class JgUseRegistrationManageController extends BaseController {
@GetMapping(value = "/list") @GetMapping(value = "/list")
@ApiOperation(httpMethod = "GET", value = "按照单位统一代码查询当前单位下的证", notes = "按照单位统一代码查询当前单位下的证") @ApiOperation(httpMethod = "GET", value = "按照单位统一代码查询当前单位下的证", notes = "按照单位统一代码查询当前单位下的证")
public ResponseModel<List<JgUseRegistrationManageDto>> queryByUseUnitCreditCode(JgUseRegistrationManageDto dto) { public ResponseModel<List<JgUseRegistrationManageDto>> queryByUseUnitCreditCode(JgUseRegistrationManageDto dto) {
CompanyBo company = getSelectedOrgInfo().getCompany(); if(StringUtils.isEmpty(dto.getReceiveCompanyCode())){
if (company.getLevel().equals(BaseController.COMPANY_TYPE_COMPANY)) { CompanyBo company = getSelectedOrgInfo().getCompany();
if (ValidationUtil.isEmpty(dto.getUseUnitCreditCode())) { if (company.getLevel().equals(BaseController.COMPANY_TYPE_COMPANY)) {
// 不传的话取当前登录单位的统一信用代码 if (ValidationUtil.isEmpty(dto.getUseUnitCreditCode())) {
// 个人主体特殊处理 // 不传的话取当前登录单位的统一信用代码
dto.setUseUnitCreditCode(CompanyTypeEnum.INDIVIDUAL.getName().equals(company.getCompanyType()) ? // 个人主体特殊处理
company.getCompanyCode().split("_")[1] : dto.setUseUnitCreditCode(CompanyTypeEnum.INDIVIDUAL.getName().equals(company.getCompanyType()) ?
company.getCompanyCode()); company.getCompanyCode().split("_")[1] :
company.getCompanyCode());
}
} else {
dto.setReceiveCompanyCode(company.getCompanyCode());
} }
} else { } else {
dto.setReceiveCompanyCode(company.getCompanyCode()); CompanyBo company = getSelectedOrgInfo().getCompany();
if (company.getLevel().equals(BaseController.COMPANY_TYPE_COMPANY)) {
if (ValidationUtil.isEmpty(dto.getUseUnitCreditCode())) {
// 不传的话取当前登录单位的统一信用代码
// 个人主体特殊处理
dto.setUseUnitCreditCode(CompanyTypeEnum.INDIVIDUAL.getName().equals(company.getCompanyType()) ?
company.getCompanyCode().split("_")[1] :
company.getCompanyCode());
}
}
} }
dto.setIsDoBusiness("1"); dto.setIsDoBusiness("1");
return ResponseHelper.buildResponse(jgUseRegistrationManageServiceImpl.queryByUseUnitCreditCode(dto)); return ResponseHelper.buildResponse(jgUseRegistrationManageServiceImpl.queryByUseUnitCreditCode(dto));
......
...@@ -1342,6 +1342,9 @@ public class JgChangeRegistrationTransferServiceImpl extends BaseService<JgChang ...@@ -1342,6 +1342,9 @@ public class JgChangeRegistrationTransferServiceImpl extends BaseService<JgChang
String newAddress = ""; String newAddress = "";
String newLongitudeLatitude = ""; String newLongitudeLatitude = "";
String useSiteCode = ""; String useSiteCode = "";
//es中的编号信息
Map<String, Map<String, Object>> resultMap = new HashMap<>();
Map<String, Object> map1 = new HashMap<>();
if (!ValidationUtil.isEmpty(newData)) { if (!ValidationUtil.isEmpty(newData)) {
JSONObject newPosition = JSON.parseObject(newData.getChangeData()); JSONObject newPosition = JSON.parseObject(newData.getChangeData());
String province = newPosition.getString("transferProvince"); String province = newPosition.getString("transferProvince");
...@@ -1352,6 +1355,14 @@ public class JgChangeRegistrationTransferServiceImpl extends BaseService<JgChang ...@@ -1352,6 +1355,14 @@ public class JgChangeRegistrationTransferServiceImpl extends BaseService<JgChang
String longitudeLatitude = newPosition.getString("longitudeLatitude"); String longitudeLatitude = newPosition.getString("longitudeLatitude");
// 使用场所 // 使用场所
useSiteCode = newPosition.getString("transferUsePlace"); useSiteCode = newPosition.getString("transferUsePlace");
// es的使用地点信息名称、code、详情地址
String orgBranchCodeName = newPosition.getString("orgBranchCode");
String orgBranchName = newPosition.getString("orgBranchName");
String[] orgBranchArray = orgBranchCodeName.split("_");
if (orgBranchArray.length > 1) {
map1.put("ORG_BRANCH_CODE", orgBranchArray[0]);
map1.put("ORG_BRANCH_NAME", StringUtil.isNotEmpty(orgBranchName) ? orgBranchName : orgBranchArray[1]);
}
// 分割省市区街道字段 // 分割省市区街道字段
if (!ObjectUtils.isEmpty(province)) { if (!ObjectUtils.isEmpty(province)) {
String[] provinceList = province.split("_"); String[] provinceList = province.split("_");
...@@ -1389,10 +1400,6 @@ public class JgChangeRegistrationTransferServiceImpl extends BaseService<JgChang ...@@ -1389,10 +1400,6 @@ public class JgChangeRegistrationTransferServiceImpl extends BaseService<JgChang
newLongitudeLatitude = longitudeLatitude; newLongitudeLatitude = longitudeLatitude;
} }
} }
//es中的编号信息
Map<String, Map<String, Object>> resultMap = new HashMap<>();
Map<String, Object> map1 = new HashMap<>();
// es的使用地点信息名称、code、详情地址
map1.put("USE_PLACE", newUsePlace); map1.put("USE_PLACE", newUsePlace);
map1.put("USE_PLACE_CODE", newUsePlaceCode); map1.put("USE_PLACE_CODE", newUsePlaceCode);
map1.put("ADDRESS", newAddress); map1.put("ADDRESS", newAddress);
......
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