Commit 6b464a19 authored by lcl's avatar lcl

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

parents 0990e7c3 8108082c
...@@ -74,11 +74,25 @@ public class EnterpriseProjectController { ...@@ -74,11 +74,25 @@ public class EnterpriseProjectController {
return enterpriseProjectService.specialDebtPage(body); return enterpriseProjectService.specialDebtPage(body);
} }
/***
*@Description: 招标公告 分页列表
*@Param:
*@return: com.dsk.common.core.domain.R
*@Author: Dgm
*@date: 2023/10/9 14:41
*/
@PostMapping(value = "/bidNoticePage") @PostMapping(value = "/bidNoticePage")
public TableDataInfo bidNoticePage(@RequestBody @Valid EnterpriseProjectBidNoticePageBody body) throws Exception { public TableDataInfo bidNoticePage(@RequestBody @Valid EnterpriseProjectBidNoticePageBody body) throws Exception {
return enterpriseProjectService.bidNoticePage(body); return enterpriseProjectService.bidNoticePage(body);
} }
/***
*@Description: 招标招采阶段
*@Param:
*@return: com.dsk.common.core.domain.R
*@Author: Dgm
*@date: 2023/10/9 14:41
*/
@PostMapping(value = "/bidNoticeTenderStage") @PostMapping(value = "/bidNoticeTenderStage")
public R bidNoticeTenderStage(@RequestBody @Valid EnterpriseProjectBidNoticeTenderStageBody body) throws Exception { public R bidNoticeTenderStage(@RequestBody @Valid EnterpriseProjectBidNoticeTenderStageBody body) throws Exception {
return enterpriseProjectService.bidNoticeTenderStage(body); return enterpriseProjectService.bidNoticeTenderStage(body);
...@@ -89,6 +103,19 @@ public class EnterpriseProjectController { ...@@ -89,6 +103,19 @@ public class EnterpriseProjectController {
return enterpriseProjectService.bidNoticeArea(body); return enterpriseProjectService.bidNoticeArea(body);
} }
/***
*@Description: 招标项目类别
*@Param:
*@return: com.dsk.common.core.domain.R
*@Author: Dgm
*@date: 2023/10/9 14:41
*/
@PostMapping(value = "/bidNoticeProjectCategory")
public R bidNoticeProjectCategory(@RequestBody @Valid EnterpriseProjectBidNoticeTenderStageBody body) throws Exception {
return enterpriseProjectService.bidNoticeProjectCategory(body);
}
@PostMapping(value = "/bidNoticeDetail") @PostMapping(value = "/bidNoticeDetail")
public R bidNoticeDetail(@RequestBody @Valid EnterpriseProjectBidNoticeDetailBody body) throws Exception { public R bidNoticeDetail(@RequestBody @Valid EnterpriseProjectBidNoticeDetailBody body) throws Exception {
return enterpriseProjectService.bidNoticeDetail(body); return enterpriseProjectService.bidNoticeDetail(body);
......
...@@ -25,10 +25,15 @@ public class EnterpriseProjectBidNoticePageBody extends BasePage { ...@@ -25,10 +25,15 @@ public class EnterpriseProjectBidNoticePageBody extends BasePage {
private String keys; private String keys;
/** /**
* 类型 * 招标阶段
*/ */
private List<String> tenderStage; private List<String> tenderStage;
/**
* 项目类型
*/
private List<String> projectCategory;
/* /*
* 1金额倒序,2金额正序,3时间倒序,4时间正序 * 1金额倒序,2金额正序,3时间倒序,4时间正序
*/ */
......
...@@ -4,11 +4,13 @@ import cn.hutool.core.bean.BeanException; ...@@ -4,11 +4,13 @@ import cn.hutool.core.bean.BeanException;
import cn.hutool.core.bean.BeanUtil; import cn.hutool.core.bean.BeanUtil;
import cn.hutool.core.util.ObjectUtil; import cn.hutool.core.util.ObjectUtil;
import cn.hutool.json.JSONUtil; import cn.hutool.json.JSONUtil;
import com.dsk.acc.openapi.client.util.CommonUtils;
import com.dsk.common.core.domain.R; import com.dsk.common.core.domain.R;
import com.dsk.common.core.page.TableDataInfo; import com.dsk.common.core.page.TableDataInfo;
import com.dsk.common.utils.DskOpenApiUtil; import com.dsk.common.utils.DskOpenApiUtil;
import com.dsk.jsk.domain.*; import com.dsk.jsk.domain.*;
import com.dsk.jsk.domain.bo.EnterpriseProjectImportantListDto; import com.dsk.jsk.domain.bo.EnterpriseProjectImportantListDto;
import org.apache.commons.collections4.CollectionUtils;
import org.apache.commons.collections4.MapUtils; import org.apache.commons.collections4.MapUtils;
import org.slf4j.Logger; import org.slf4j.Logger;
import org.slf4j.LoggerFactory; import org.slf4j.LoggerFactory;
...@@ -17,6 +19,7 @@ import org.springframework.stereotype.Service; ...@@ -17,6 +19,7 @@ import org.springframework.stereotype.Service;
import java.util.ArrayList; import java.util.ArrayList;
import java.util.HashMap; import java.util.HashMap;
import java.util.List;
import java.util.Map; import java.util.Map;
@Service @Service
...@@ -90,13 +93,52 @@ public class EnterpriseProjectService { ...@@ -90,13 +93,52 @@ public class EnterpriseProjectService {
return dskOpenApiUtil.responsePage(map); return dskOpenApiUtil.responsePage(map);
} }
/***
*@Description: 招标公告 分页列表
*@Param:
*@return: com.dsk.common.core.domain.R
*@Author: Dgm
*@date: 2023/10/9 14:41
*/
public TableDataInfo bidNoticePage(EnterpriseProjectBidNoticePageBody body) throws Exception { public TableDataInfo bidNoticePage(EnterpriseProjectBidNoticePageBody body) throws Exception {
if (body.isVaildCid()) return new TableDataInfo(new ArrayList<>(), 0); if (body.isVaildCid()) {
return new TableDataInfo(new ArrayList<>(), 0);
}
Map<String, Object> map = dskOpenApiUtil.requestBody("/operate/enterpriseProject/bidNoticePage", BeanUtil.beanToMap(body, false, false)); Map<String, Object> map = dskOpenApiUtil.requestBody("/operate/enterpriseProject/bidNoticePage", BeanUtil.beanToMap(body, false, false));
Map data = MapUtils.getMap(map, "data", null);
List<Object> list = CommonUtils.assertAsArray(MapUtils.getObject(data, "list", ""));
if (CollectionUtils.isEmpty(list)) {
return new TableDataInfo(list, 0);
}
ArrayList<Long> cIds = new ArrayList<>();
for (Object dataMap : list) {
cIds.add(MapUtils.getLong(CommonUtils.assertAsMap(dataMap), "agencyId"));
}
HashMap<String, Object> paramMap = new HashMap<>();
paramMap.put("ids", cIds);
Map<String, Object> uipIdMap = dskOpenApiUtil.requestBody("/operate/enterprise/getUipIdByCid", paramMap);
Object uipIdData = uipIdMap.get("data");
List<Map<String, Object>> mapList = new ArrayList<>();
if (ObjectUtil.isNotEmpty(uipIdData)) {
mapList = (List<Map<String, Object>>)uipIdData;
}
for (Object dataMap : list) {
Map<String, Object> companyMap = CommonUtils.assertAsMap(dataMap);
Long agencyId = MapUtils.getLong(companyMap, "agencyId", 0L);
companyMap.put("uipId", null);
for (Map<String, Object> m : mapList) {
String uipId = MapUtils.getString(m, "uipId", null);
Long companyId = MapUtils.getLong(m, "companyId", 0L);
if (agencyId.equals(companyId)) {
companyMap.put("uipId", uipId);
}
}
}
return dskOpenApiUtil.responsePage(map); return dskOpenApiUtil.responsePage(map);
} }
public R bidNoticeTenderStage(EnterpriseProjectBidNoticeTenderStageBody body) throws Exception { public R bidNoticeTenderStage(EnterpriseProjectBidNoticeTenderStageBody body) throws Exception {
if (body.isVaildCid()) return R.ok(); if (body.isVaildCid()) return R.ok();
Map<String, Object> map = dskOpenApiUtil.requestBody("/operate/enterpriseProject/bidNoticeTenderStage", BeanUtil.beanToMap(body, false, false)); Map<String, Object> map = dskOpenApiUtil.requestBody("/operate/enterpriseProject/bidNoticeTenderStage", BeanUtil.beanToMap(body, false, false));
...@@ -110,6 +152,20 @@ public class EnterpriseProjectService { ...@@ -110,6 +152,20 @@ public class EnterpriseProjectService {
return BeanUtil.toBean(map, R.class); return BeanUtil.toBean(map, R.class);
} }
/***
*@Description: 招标项目类别
*@Param:
*@return: com.dsk.common.core.domain.R
*@Author: Dgm
*@date: 2023/10/9 14:41
*/
public R bidNoticeProjectCategory(EnterpriseProjectBidNoticeTenderStageBody body) throws Exception {
if (body.isVaildCid()) {
return R.ok();
}
Map<String, Object> map = dskOpenApiUtil.requestBody("/operate/enterpriseProject/bidNoticeProjectCategory", BeanUtil.beanToMap(body, false, false));
return BeanUtil.toBean(map, R.class);
}
public R bidNoticeDetail(EnterpriseProjectBidNoticeDetailBody body) throws Exception { public R bidNoticeDetail(EnterpriseProjectBidNoticeDetailBody body) throws Exception {
Map<String, Object> map = dskOpenApiUtil.requestBody("/operate/enterpriseProject/bidNoticeDetail", BeanUtil.beanToMap(body, false, false)); Map<String, Object> map = dskOpenApiUtil.requestBody("/operate/enterpriseProject/bidNoticeDetail", BeanUtil.beanToMap(body, false, false));
......
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