Commit b65c3d2f authored by danfuman's avatar danfuman

Merge branch 'dev20230707' of http://192.168.60.201/root/dsk-operate-sys into dev20230707

parents fb59b474 cb5dbac7
...@@ -250,28 +250,32 @@ public class EnterpriseService { ...@@ -250,28 +250,32 @@ public class EnterpriseService {
} }
ArrayList<String> uipIds = new ArrayList<>(); ArrayList<String> uipIds = new ArrayList<>();
ArrayList<Long> cIds = new ArrayList<>();
for (Object dataMap : list) { for (Object dataMap : list) {
uipIds.add(MapUtils.getString(CommonUtils.assertAsMap(dataMap), "uipId")); uipIds.add(MapUtils.getString(CommonUtils.assertAsMap(dataMap), "uipId"));
cIds.add(MapUtils.getLong(CommonUtils.assertAsMap(dataMap), "companyId"));
} }
List<CustomerStatusListVo> claimStatusList = iCustomerService.selectStatusList(uipIds); List<CustomerStatusListVo> claimStatusList = iCustomerService.selectStatusList(uipIds);
//按照城投企业id合并两个list Map<String, Object> bondCreditRatingBatchMap = new HashMap<>(1);
for (Object companyObj : list) { bondCreditRatingBatchMap.put("cIds", cIds);
Map<String, Object> companyMap = CommonUtils.assertAsMap(companyObj); Map<String, Object> bondCreditRatingMap = dskOpenApiUtil.requestBody("/operate/enterprise/bondCreditRatingBatch", bondCreditRatingBatchMap);
companyMap.put("cid", MapUtils.getString(companyMap, "companyId"));
companyMap.put("bratingSubjectLevel", null);
Map<String, Object> bondCreditRatingMap = dskOpenApiUtil.requestBody("/operate/enterprise/bondCreditRating", companyMap);
Integer codeRating = MapUtils.getInteger(bondCreditRatingMap, "code", 300); Integer codeRating = MapUtils.getInteger(bondCreditRatingMap, "code", 300);
ArrayList<Map<String, Object>> objArrayList = new ArrayList(1);
if (codeRating.equals(HttpStatus.OK.value())) { if (codeRating.equals(HttpStatus.OK.value())) {
Object object = bondCreditRatingMap.get("data"); Object object = bondCreditRatingMap.get("data");
if (ObjectUtil.isNotEmpty(object)) { if (ObjectUtil.isNotEmpty(object)) {
ArrayList obj = (ArrayList)object; objArrayList = (ArrayList)object;
Map<String, Object> bondCreditRating = (Map<String, Object>)obj.get(0);
companyMap.put("bratingSubjectLevel", bondCreditRating.get("bratingSubjectLevel"));
} }
} }
//按照城投企业id合并两个list
for (Object companyObj : list) {
Map<String, Object> companyMap = CommonUtils.assertAsMap(companyObj);
companyMap.put("bratingSubjectLevel", null);
String uipId = MapUtils.getString(companyMap, "uipId"); String uipId = MapUtils.getString(companyMap, "uipId");
Long companyId = MapUtils.getLong(companyMap, "companyId");
companyMap.put("bondBalance",MapUtils.getDouble(companyMap, "bondBalance")==null?null:String.format("%.2f", MapUtils.getDouble(companyMap, "bondBalance"))); companyMap.put("bondBalance",MapUtils.getDouble(companyMap, "bondBalance")==null?null:String.format("%.2f", MapUtils.getDouble(companyMap, "bondBalance")));
companyMap.put("totalAssets",MapUtils.getDouble(companyMap, "totalAssets")==null?null:String.format("%.2f", MapUtils.getDouble(companyMap, "totalAssets"))); companyMap.put("totalAssets",MapUtils.getDouble(companyMap, "totalAssets")==null?null:String.format("%.2f", MapUtils.getDouble(companyMap, "totalAssets")));
companyMap.put("belongNetAssets",MapUtils.getDouble(companyMap, "belongNetAssets")==null?null:String.format("%.2f", MapUtils.getDouble(companyMap, "belongNetAssets"))); companyMap.put("belongNetAssets",MapUtils.getDouble(companyMap, "belongNetAssets")==null?null:String.format("%.2f", MapUtils.getDouble(companyMap, "belongNetAssets")));
...@@ -314,6 +318,12 @@ public class EnterpriseService { ...@@ -314,6 +318,12 @@ public class EnterpriseService {
companyMap.put("claimStatus", 1); companyMap.put("claimStatus", 1);
} }
} }
for (Map<String, Object> m : objArrayList) {
Long companyIdCredit = MapUtils.getLong(m, "companyId", 0L);
if (companyIdCredit.equals(companyId)) {
companyMap.put("bratingSubjectLevel", m.get("bratingSubjectLevel"));
}
}
} }
return new TableDataInfo(list, MapUtils.getInteger(data, "totalCount", 0)); return new TableDataInfo(list, MapUtils.getInteger(data, "totalCount", 0));
......
...@@ -139,24 +139,27 @@ public class BusinessInfoServiceImpl implements IBusinessInfoService { ...@@ -139,24 +139,27 @@ public class BusinessInfoServiceImpl implements IBusinessInfoService {
@Override @Override
public List<BusinessLikeProjectNameListVo> selectProjectName(BusinessListDto dto) { public List<BusinessLikeProjectNameListVo> selectProjectName(BusinessListDto dto) {
List<BusinessLikeProjectNameListVo> vos = businessInfoMapper.selectProjectName(dto); // List<BusinessLikeProjectNameListVo> vos = businessInfoMapper.selectProjectName(dto);
// List<BusinessLikeProjectNameListVo> vos = new ArrayList<>(); List<BusinessLikeProjectNameListVo> vos = new ArrayList<>();
// Map<String, Object> result = dskOpenApiUtil.requestBody("/company/bidding/newZhaoBiao/list", toRequestMap(dto)); try {
// if ("200".equals(result.get("code")) && ObjectUtil.isNotEmpty(result.get("data")) Map<String, Object> result = dskOpenApiUtil.requestBody("/nationzj/jskBid/news/findByName", toRequestMap(dto));
// && ObjectUtil.isNotEmpty(BeanUtil.beanToMap(result.get("data")).get("list"))) { if (ObjectUtil.isNotEmpty(result.get("data"))) {
// List<Map<String, Object>> list = (List<Map<String, Object>>) BeanUtil.beanToMap(result.get("data")).get("list"); List<Map<String, Object>> list = (List<Map<String, Object>>) BeanUtil.beanToMap(result.get("data")).get("list");
// if (!CollectionUtils.isEmpty(list)) { if (!CollectionUtils.isEmpty(list)) {
// for (Map<String, Object> map : list) { for (Map<String, Object> map : list) {
// BusinessLikeProjectNameListVo vo = new BusinessLikeProjectNameListVo(); BusinessLikeProjectNameListVo vo = new BusinessLikeProjectNameListVo();
// vo.setProjectName(MapUtil.getStr(map, "projectName").replace(dto.getProjectName(), "<font color='#FF204E'>" + dto.getProjectName() + "</font>")); vo.setProjectName(MapUtil.getStr(map, "projectName").replace(dto.getProjectName(), "<font color='#FF204E'>" + dto.getProjectName() + "</font>"));
// vo.setInvestmentAmount(MapUtil.getDouble(map, "bidMoney")); vo.setInvestmentAmount(Double.parseDouble(MapUtil.getStr(map, "projectContractAmount")));
// vo.setProjectLevel(MapUtil.getStr(map, "bidMoney")); vo.setProjectType(MapUtil.getStr(map, "projectType"));
// vo.setProjectStage(MapUtil.getStr(map, "tenderStage")); vo.setProjectCategory(MapUtil.getStr(map, "projectPurposes"));
// vo.setProjectType(MapUtil.getStr(map, "projectType")); vos.add(vo);
// vo.setProjectCategory(MapUtil.getStr(map, "projectType")); }
// } }
// } }
// } }catch (Exception e) {
log.error("模糊查询项目名称调用失败!");
}
return vos; return vos;
} }
......
...@@ -50,34 +50,46 @@ public class UrbanInvestmentPlatformServiceImpl implements UrbanInvestmentPlatfo ...@@ -50,34 +50,46 @@ public class UrbanInvestmentPlatformServiceImpl implements UrbanInvestmentPlatfo
} }
ArrayList<String> uipIds = new ArrayList<>(); ArrayList<String> uipIds = new ArrayList<>();
ArrayList<Long> cIds = new ArrayList<>();
for (Object dataMap : list) { for (Object dataMap : list) {
uipIds.add(MapUtils.getString(CommonUtils.assertAsMap(dataMap), "uipId")); uipIds.add(MapUtils.getString(CommonUtils.assertAsMap(dataMap), "uipId"));
cIds.add(MapUtils.getLong(CommonUtils.assertAsMap(dataMap), "companyId"));
} }
// List<String> claimStatusList = iCustomerService.selectUipIdList(uipIds); // List<String> claimStatusList = iCustomerService.selectUipIdList(uipIds);
List<CustomerStatusListVo> customerStatusListVos = iCustomerService.selectStatusList(uipIds); List<CustomerStatusListVo> customerStatusListVos = iCustomerService.selectStatusList(uipIds);
//按照城投企业id合并两个list
//按照城投企业id合并两个list Map<String, Object> bondCreditRatingBatchMap = new HashMap<>(1);
for (Object companyObj : list) { bondCreditRatingBatchMap.put("cIds", cIds);
Map<String, Object> companyMap = CommonUtils.assertAsMap(companyObj); Map<String, Object> bondCreditRatingMap = dskOpenApiUtil.requestBody("/operate/enterprise/bondCreditRatingBatch", bondCreditRatingBatchMap);
companyMap.put("bratingSubjectLevel", null);
companyMap.put("cid", MapUtils.getString(companyMap, "companyId"));
Map<String, Object> bondCreditRatingMap = dskOpenApiUtil.requestBody("/operate/enterprise/bondCreditRating", companyMap);
Integer codeRating = MapUtils.getInteger(bondCreditRatingMap, "code", 300); Integer codeRating = MapUtils.getInteger(bondCreditRatingMap, "code", 300);
ArrayList<Map<String, Object>> objArrayList = new ArrayList(1);
if (codeRating.equals(HttpStatus.OK.value())) { if (codeRating.equals(HttpStatus.OK.value())) {
Object object = bondCreditRatingMap.get("data"); Object object = bondCreditRatingMap.get("data");
if (ObjectUtil.isNotEmpty(object)) { if (ObjectUtil.isNotEmpty(object)) {
ArrayList obj = (ArrayList)object; objArrayList = (ArrayList)object;
Map<String, Object> bondCreditRating = (Map<String, Object>)obj.get(0);
companyMap.put("bratingSubjectLevel", bondCreditRating.get("bratingSubjectLevel"));
} }
} }
//按照城投企业id合并两个list
//按照城投企业id合并两个list
for (Object companyObj : list) {
Map<String, Object> companyMap = CommonUtils.assertAsMap(companyObj);
Long companyId = MapUtils.getLong(companyMap, "companyId");
String uipId = MapUtils.getString(companyMap, "uipId"); String uipId = MapUtils.getString(companyMap, "uipId");
companyMap.put("claimStatus", 0); companyMap.put("claimStatus", 0);
companyMap.put("bratingSubjectLevel", null);
for (CustomerStatusListVo vo : customerStatusListVos) { for (CustomerStatusListVo vo : customerStatusListVos) {
if (uipId.equals(vo.getUipId())) { if (uipId.equals(vo.getUipId())) {
companyMap.put("claimStatus", 1); companyMap.put("claimStatus", 1);
} }
} }
for (Map<String, Object> m : objArrayList) {
Long companyIdCredit = MapUtils.getLong(m, "companyId", 0L);
if (companyIdCredit.equals(companyId)) {
companyMap.put("bratingSubjectLevel", m.get("bratingSubjectLevel"));
}
}
} }
// for (Object companyObj : list) { // for (Object companyObj : list) {
......
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