@@ -0,0 +1,49 @@ | |||||
package com.ningdatech.pmapi.projectlib.enumeration; | |||||
import java.util.Objects; | |||||
import org.apache.commons.lang3.StringUtils; | |||||
import lombok.AllArgsConstructor; | |||||
import lombok.Getter; | |||||
import lombok.NoArgsConstructor; | |||||
/** | |||||
* 综合业务领域枚举 | |||||
* | |||||
* @return | |||||
* @author CMM | |||||
* @since 2023/03/16 16:27 | |||||
*/ | |||||
@Getter | |||||
@AllArgsConstructor | |||||
@NoArgsConstructor | |||||
public enum BizDomainEnum { | |||||
/** | |||||
* 项目类型 | |||||
*/ | |||||
PARTY_GOV_ORG_OVERALL(1, "党政机关整体智治"), | |||||
DIG_GOV(2, "数字政府"), | |||||
DIG_ECO(3, "数字经济"), | |||||
DIG_SOC(4, "数字社会"), | |||||
DIG_LAW(5, "数字法治"), | |||||
ALL_INTEL_PUB_DATA_PLAT(6, "一体化智能化公共数据平台"), | |||||
DIG_CUL(7, "数字文化"), | |||||
GRA_WISE(8, "基层智治"); | |||||
private Integer code; | |||||
private String desc; | |||||
public static String getDescByCode(Integer code) { | |||||
if (Objects.isNull(code)) { | |||||
return StringUtils.EMPTY; | |||||
} | |||||
for (BizDomainEnum t : BizDomainEnum.values()) { | |||||
if (code.equals(t.getCode())) { | |||||
return t.desc; | |||||
} | |||||
} | |||||
return StringUtils.EMPTY; | |||||
} | |||||
} |
@@ -78,9 +78,9 @@ public class CommonLogTask { | |||||
commonLog.setUserRole("政府工作人员"); | commonLog.setUserRole("政府工作人员"); | ||||
commonLog.setAreaCode(userInfo.getRegionCode()); | commonLog.setAreaCode(userInfo.getRegionCode()); | ||||
String description = optLog.getDescription(); | String description = optLog.getDescription(); | ||||
if (description.equals("登录")){ | |||||
if ("登陆".equals(description)){ | |||||
commonLog.setActionType(1); | commonLog.setActionType(1); | ||||
}else if (description.equals("退出登录")){ | |||||
}else if ("退出登陆".equals(description)){ | |||||
commonLog.setActionType(2); | commonLog.setActionType(2); | ||||
}else { | }else { | ||||
commonLog.setActionType(3); | commonLog.setActionType(3); | ||||
@@ -11,6 +11,8 @@ import java.util.stream.Stream; | |||||
import javax.servlet.http.HttpServletResponse; | import javax.servlet.http.HttpServletResponse; | ||||
import cn.hutool.core.util.ObjectUtil; | import cn.hutool.core.util.ObjectUtil; | ||||
import com.ningdatech.basic.exception.BizException; | |||||
import com.ningdatech.pmapi.projectlib.enumeration.BizDomainEnum; | |||||
import com.ningdatech.pmapi.todocenter.constant.TodoCenterContant; | import com.ningdatech.pmapi.todocenter.constant.TodoCenterContant; | ||||
import com.ningdatech.pmapi.todocenter.handle.PassHandle; | import com.ningdatech.pmapi.todocenter.handle.PassHandle; | ||||
import com.ningdatech.pmapi.todocenter.handle.WithDrawHandle; | import com.ningdatech.pmapi.todocenter.handle.WithDrawHandle; | ||||
@@ -493,7 +495,12 @@ public class TodoCenterManage { | |||||
Integer signType = req.getSignType(); | Integer signType = req.getSignType(); | ||||
signReq.setSignType(signType); | signReq.setSignType(signType); | ||||
// 调用盖章接口,获取盖章后返回的pdf文件字符数组 | // 调用盖章接口,获取盖章后返回的pdf文件字符数组 | ||||
byte[] signPdf = IRSAPIRequest.createSignPdf(signReq); | |||||
byte[] signPdf = new byte[0]; | |||||
try { | |||||
signPdf = IRSAPIRequest.createSignPdf(signReq); | |||||
} catch (Exception e) { | |||||
throw new BizException("调用IRS盖章接口失败,印章编号为:" + sealSn); | |||||
} | |||||
// 转换成MultipartFile | // 转换成MultipartFile | ||||
MultipartFile multipartFile = new MockMultipartFile("file", originalFileName, "application/pdf", signPdf); | MultipartFile multipartFile = new MockMultipartFile("file", originalFileName, "application/pdf", signPdf); | ||||
// 上传OSS | // 上传OSS | ||||
@@ -1139,10 +1146,19 @@ public class TodoCenterManage { | |||||
paramsMap.put("fourSystems", fourSystem); | paramsMap.put("fourSystems", fourSystem); | ||||
// 获取是否数字化改革项目 | // 获取是否数字化改革项目 | ||||
String isDigitalReform = IsOrNotEnum.getDescByCode(project.getIsDigitalReform()); | String isDigitalReform = IsOrNotEnum.getDescByCode(project.getIsDigitalReform()); | ||||
paramsMap.put("isDigitalReform", isDigitalReform); | |||||
if (IsOrNotEnum.NOT.getDesc().equals(isDigitalReform)){ | |||||
paramsMap.put("bizDomain", null); | |||||
}else { | |||||
paramsMap.put("bizDomain", BizDomainEnum.getDescByCode(project.getBizDomain())); | |||||
} | |||||
// 获取是否上云 | // 获取是否上云 | ||||
String isCloud = IsOrNotEnum.getDescByCode(project.getIsCloud()); | String isCloud = IsOrNotEnum.getDescByCode(project.getIsCloud()); | ||||
paramsMap.put("isCloud", isCloud); | paramsMap.put("isCloud", isCloud); | ||||
if (IsOrNotEnum.NOT.getDesc().equals(isCloud)){ | |||||
paramsMap.put("cloudType", null); | |||||
}else { | |||||
paramsMap.put("cloudType",project.getCloudType()); | |||||
} | |||||
// 获取本年计划投资金额 | // 获取本年计划投资金额 | ||||
BigDecimal yearPlanInvest = project.getAnnualPlanAmount(); | BigDecimal yearPlanInvest = project.getAnnualPlanAmount(); | ||||
paramsMap.put("yearPlanInvest",yearPlanInvest); | paramsMap.put("yearPlanInvest",yearPlanInvest); | ||||
@@ -203,11 +203,11 @@ provincial: | |||||
#天印服务器接口信息 | #天印服务器接口信息 | ||||
irs: | irs: | ||||
seal-platform: | seal-platform: | ||||
project-id: 1 | |||||
project-secret: 2 | |||||
access-key: 3 | |||||
secret-key: 4 | |||||
api-url: https://ibcdsg.zj.gov.cn:8443/restapi/prod/IC33000020220309000004/seal-platform/seal/v1/rest/sign/signPdf | |||||
project-id: 330001110 | |||||
project-secret: 70e512d40c8f440484db4acab181570a | |||||
access-key: 42bcb49bea174986a3bfdfba7d005566 | |||||
secret-key: bebff29877d4443abd67fc4f8fb335d8 | |||||
api-url: https://bcdsg.zj.gov.cn:8443/restapi/prod/IC33000020220309000004/seal-platform/seal/v1/rest/sign/signPdf | |||||
hostname: iZbp13nwyvib53j4j1p2xoZ | hostname: iZbp13nwyvib53j4j1p2xoZ | ||||
@@ -203,11 +203,11 @@ provincial: | |||||
#天印服务器接口信息 | #天印服务器接口信息 | ||||
irs: | irs: | ||||
seal-platform: | seal-platform: | ||||
project-id: 1 | |||||
project-secret: 2 | |||||
access-key: 3 | |||||
secret-key: 4 | |||||
api-url: https://ibcdsg.zj.gov.cn:8443/restapi/prod/IC33000020220309000004/seal-platform/seal/v1/rest/sign/signPdf | |||||
project-id: 330001110 | |||||
project-secret: 70e512d40c8f440484db4acab181570a | |||||
access-key: 42bcb49bea174986a3bfdfba7d005566 | |||||
secret-key: bebff29877d4443abd67fc4f8fb335d8 | |||||
api-url: https://bcdsg.zj.gov.cn:8443/restapi/prod/IC33000020220309000004/seal-platform/seal/v1/rest/sign/signPdf | |||||
hostname: iZ6mx01gyeodd80imxd2gbZ | hostname: iZ6mx01gyeodd80imxd2gbZ | ||||
login: | login: | ||||