Merge branch 'develop' into 'master'
合并代码 See merge request !4
Showing
82 changed files
with
7979 additions
and
89 deletions
| ... | @@ -36,11 +36,11 @@ | ... | @@ -36,11 +36,11 @@ |
| 36 | <artifactId>csbr-cloud-base</artifactId> | 36 | <artifactId>csbr-cloud-base</artifactId> |
| 37 | <version>${cabr-package.version}</version> | 37 | <version>${cabr-package.version}</version> |
| 38 | </dependency> | 38 | </dependency> |
| 39 | <dependency> | 39 | <!-- <dependency> |
| 40 | <groupId>com.csbr.qingcloud</groupId> | 40 | <groupId>com.csbr.qingcloud</groupId> |
| 41 | <artifactId>csbr-cloud-log</artifactId> | 41 | <artifactId>csbr-cloud-log</artifactId> |
| 42 | <version>${cabr-package.version}</version> | 42 | <version>${cabr-package.version}</version> |
| 43 | </dependency> | 43 | </dependency>--> |
| 44 | <dependency> | 44 | <dependency> |
| 45 | <groupId>com.csbr.qingcloud</groupId> | 45 | <groupId>com.csbr.qingcloud</groupId> |
| 46 | <artifactId>csbr-cloud-mybatis</artifactId> | 46 | <artifactId>csbr-cloud-mybatis</artifactId> |
| ... | @@ -92,6 +92,8 @@ | ... | @@ -92,6 +92,8 @@ |
| 92 | <exclude>release/*</exclude> | 92 | <exclude>release/*</exclude> |
| 93 | <exclude>develop/*</exclude> | 93 | <exclude>develop/*</exclude> |
| 94 | <exclude>release-test/*</exclude> | 94 | <exclude>release-test/*</exclude> |
| 95 | <exclude>zq-release/*</exclude> | ||
| 96 | <exclude>enterprise-release/*</exclude> | ||
| 95 | </excludes> | 97 | </excludes> |
| 96 | <!--开启过滤器,此处不能忽略!--> | 98 | <!--开启过滤器,此处不能忽略!--> |
| 97 | <filtering>true</filtering> | 99 | <filtering>true</filtering> |
| ... | @@ -207,6 +209,78 @@ | ... | @@ -207,6 +209,78 @@ |
| 207 | <subPath>project</subPath> | 209 | <subPath>project</subPath> |
| 208 | </properties> | 210 | </properties> |
| 209 | </profile> | 211 | </profile> |
| 212 | <profile> | ||
| 213 | <id>zq-production-daop-master</id> | ||
| 214 | <properties> | ||
| 215 | <profileActive>zq-release</profileActive> | ||
| 216 | <subPath></subPath> | ||
| 217 | </properties> | ||
| 218 | </profile> | ||
| 219 | <profile> | ||
| 220 | <id>zq-production-daop-lt</id> | ||
| 221 | <properties> | ||
| 222 | <profileActive>zq-release</profileActive> | ||
| 223 | <subPath>lt</subPath> | ||
| 224 | </properties> | ||
| 225 | </profile> | ||
| 226 | <profile> | ||
| 227 | <id>zq-production-daop-zcgl</id> | ||
| 228 | <properties> | ||
| 229 | <profileActive>zq-release</profileActive> | ||
| 230 | <subPath>zcgl</subPath> | ||
| 231 | </properties> | ||
| 232 | </profile> | ||
| 233 | <profile> | ||
| 234 | <id>zq-production-daop-jgjf</id> | ||
| 235 | <properties> | ||
| 236 | <profileActive>zq-release</profileActive> | ||
| 237 | <subPath>jgjf</subPath> | ||
| 238 | </properties> | ||
| 239 | </profile> | ||
| 240 | <profile> | ||
| 241 | <id>zq-production-daop-project</id> | ||
| 242 | <properties> | ||
| 243 | <profileActive>zq-release</profileActive> | ||
| 244 | <subPath>project</subPath> | ||
| 245 | </properties> | ||
| 246 | </profile> | ||
| 247 | |||
| 248 | <profile> | ||
| 249 | <id>enterprise-production-daop-master</id> | ||
| 250 | <properties> | ||
| 251 | <profileActive>enterprise-release</profileActive> | ||
| 252 | <subPath></subPath> | ||
| 253 | </properties> | ||
| 254 | </profile> | ||
| 255 | <profile> | ||
| 256 | <id>enterprise-production-daop-lt</id> | ||
| 257 | <properties> | ||
| 258 | <profileActive>enterprise-release</profileActive> | ||
| 259 | <subPath>lt</subPath> | ||
| 260 | </properties> | ||
| 261 | </profile> | ||
| 262 | <profile> | ||
| 263 | <id>enterprise-production-daop-zcgl</id> | ||
| 264 | <properties> | ||
| 265 | <profileActive>enterprise-release</profileActive> | ||
| 266 | <subPath>zcgl</subPath> | ||
| 267 | </properties> | ||
| 268 | </profile> | ||
| 269 | <profile> | ||
| 270 | <id>enterprise-production-daop-jgjf</id> | ||
| 271 | <properties> | ||
| 272 | <profileActive>enterprise-release</profileActive> | ||
| 273 | <subPath>jgjf</subPath> | ||
| 274 | </properties> | ||
| 275 | </profile> | ||
| 276 | <profile> | ||
| 277 | <id>enterprise-production-daop-project</id> | ||
| 278 | <properties> | ||
| 279 | <profileActive>enterprise-release</profileActive> | ||
| 280 | <subPath>project</subPath> | ||
| 281 | </properties> | ||
| 282 | </profile> | ||
| 283 | |||
| 210 | </profiles> | 284 | </profiles> |
| 211 | 285 | ||
| 212 | </project> | 286 | </project> | ... | ... |
| 1 | package com.csbr.qingcloud.portal.controller; | ||
| 2 | |||
| 3 | import com.csbr.cloud.common.entity.CsbrUpdate; | ||
| 4 | import com.csbr.cloud.common.response.CommonRes; | ||
| 5 | import com.csbr.qingcloud.portal.domain.vo.*; | ||
| 6 | import csbr.cloud.entity.annotation.SystemLog; | ||
| 7 | import csbr.cloud.entity.domain.base.vo.PageListVO; | ||
| 8 | import com.csbr.cloud.workflow.domain.dto.callback.BizCallbackDTO; | ||
| 9 | import com.csbr.qingcloud.portal.service.DemandService; | ||
| 10 | import io.swagger.v3.oas.annotations.Operation; | ||
| 11 | import io.swagger.v3.oas.annotations.Parameter; | ||
| 12 | import io.swagger.v3.oas.annotations.tags.Tag; | ||
| 13 | import jakarta.annotation.Resource; | ||
| 14 | import jakarta.validation.Valid; | ||
| 15 | import org.springframework.validation.annotation.Validated; | ||
| 16 | import org.springframework.web.bind.annotation.*; | ||
| 17 | |||
| 18 | import java.util.List; | ||
| 19 | |||
| 20 | /** | ||
| 21 | * @program: D:/git/ms-data-circulation-portal-service | ||
| 22 | * @description: 数据需求-控制器 | ||
| 23 | * @author: xcq | ||
| 24 | * @create: 2024-12-31 18:46 | ||
| 25 | **/ | ||
| 26 | @RestController | ||
| 27 | @RequestMapping("/demand") | ||
| 28 | @Tag(name = "数据需求-控制器") | ||
| 29 | public class DemandController { | ||
| 30 | |||
| 31 | @Resource | ||
| 32 | private DemandService demandService; | ||
| 33 | |||
| 34 | //region 基本操作 | ||
| 35 | |||
| 36 | @PostMapping("/save") | ||
| 37 | @SystemLog(value = "数据需求-新增") | ||
| 38 | @Operation(summary = "数据需求-新增") | ||
| 39 | public CommonRes<Boolean> saveDemand(@RequestBody @Valid DemandRQVO vo) { | ||
| 40 | demandService.saveDemand(vo); | ||
| 41 | return CommonRes.success(true); | ||
| 42 | } | ||
| 43 | |||
| 44 | @PutMapping("/update") | ||
| 45 | @SystemLog(value = "数据需求-修改") | ||
| 46 | @Operation(summary = "数据需求-修改") | ||
| 47 | public CommonRes<Boolean> updateDemand(@RequestBody @Valid DemandRQVO vo) { | ||
| 48 | demandService.updateDemand(vo); | ||
| 49 | return CommonRes.success(true); | ||
| 50 | } | ||
| 51 | |||
| 52 | @PostMapping("/update-grounding-pick") | ||
| 53 | @Operation(summary= "数据需求-修改上架状态") | ||
| 54 | public CommonRes<Boolean> updateGroundingPick(@Validated(value = {CsbrUpdate.class})@RequestBody @Valid DemandRQVO vo) { | ||
| 55 | return CommonRes.success(demandService.updateGroundingPick(vo)); | ||
| 56 | } | ||
| 57 | |||
| 58 | @DeleteMapping("/delete") | ||
| 59 | @SystemLog(value = "数据需求-批量删除") | ||
| 60 | @Operation(summary = "数据需求-批量删除") | ||
| 61 | public CommonRes<Boolean> removeByGuids(@RequestBody List<String> guids) { | ||
| 62 | demandService.removeByGuids(guids); | ||
| 63 | return CommonRes.success(true); | ||
| 64 | } | ||
| 65 | |||
| 66 | @PostMapping("/page-list") | ||
| 67 | @SystemLog(value = "数据需求-分页") | ||
| 68 | @Operation(summary = "数据需求-分页") | ||
| 69 | public CommonRes<PageListVO<DemandRSVO>> pageList(@RequestBody @Valid DemandQueryVO queryVO) { | ||
| 70 | PageListVO<DemandRSVO> pageVO = demandService.pageList(queryVO); | ||
| 71 | return CommonRes.success(pageVO); | ||
| 72 | } | ||
| 73 | |||
| 74 | @PostMapping("/portal/page-list") | ||
| 75 | @SystemLog(value = "数据需求-门户分页") | ||
| 76 | @Operation(summary = "数据需求-门户分页") | ||
| 77 | public CommonRes<PageListVO<DemandPortalRSVO>> portalPageList(@RequestBody @Valid DemandPortalQueryVO queryVO) { | ||
| 78 | PageListVO<DemandPortalRSVO> pageVO = demandService.portalPageList(queryVO); | ||
| 79 | return CommonRes.success(pageVO); | ||
| 80 | } | ||
| 81 | |||
| 82 | @GetMapping("/detail") | ||
| 83 | @SystemLog(value = "数据需求-详情") | ||
| 84 | @Operation(summary = "数据需求-详情",parameters = { | ||
| 85 | @Parameter(name = "guid", description = "数据需求唯一标识", required = true)}) | ||
| 86 | public CommonRes<DemandRSVO> getDemandDetail(@RequestParam String guid) { | ||
| 87 | DemandRSVO vo = demandService.getDemandDetail(guid); | ||
| 88 | return CommonRes.success(vo); | ||
| 89 | } | ||
| 90 | |||
| 91 | @GetMapping("/detail-by-process") | ||
| 92 | @SystemLog(value = "按加工单查数据需求详情") | ||
| 93 | @Operation(summary = "按加工单查数据需求详情",parameters = { | ||
| 94 | @Parameter(name = "processOrderNo", description = "加工单单号", required = true)}) | ||
| 95 | public CommonRes<DemandRSVO> getDemandDetailByProcess(@RequestParam String processOrderNo) { | ||
| 96 | DemandRSVO vo = demandService.getDemandDetailByProcess(processOrderNo); | ||
| 97 | return CommonRes.success(vo); | ||
| 98 | } | ||
| 99 | |||
| 100 | @PostMapping("/flow-call-back") | ||
| 101 | @SystemLog(value = "数据需求-流程结束后进行业务回调") | ||
| 102 | @Operation(summary = "数据需求-流程结束后进行业务回调", hidden = true) | ||
| 103 | public CommonRes<Boolean> flowCallBack(@RequestBody @Valid BizCallbackDTO dto) { | ||
| 104 | demandService.flowCallBack(dto); | ||
| 105 | return CommonRes.success(true); | ||
| 106 | } | ||
| 107 | |||
| 108 | @PostMapping("/cross-flow-call-back") | ||
| 109 | @SystemLog(value = "数据需求-流程结束后进行业务回调(跨服务审批)") | ||
| 110 | @Operation(summary = "数据需求-流程结束后进行业务回调(跨服务审批)", hidden = true) | ||
| 111 | public CommonRes<Boolean> crossFlowCallBack(@RequestBody @Valid BizCallbackDTO dto) { | ||
| 112 | demandService.crossFlowCallBack(dto); | ||
| 113 | return CommonRes.success(true); | ||
| 114 | } | ||
| 115 | |||
| 116 | @PostMapping("/last-approve") | ||
| 117 | @SystemLog(value = "数据需求审批") | ||
| 118 | @Operation(summary = "数据需求审批-最后一个节点时调用") | ||
| 119 | public CommonRes<Boolean> lastApprove(@RequestBody DemandApproveVO dto) { | ||
| 120 | Boolean vo = demandService.lastApprove(dto); | ||
| 121 | return CommonRes.success(vo); | ||
| 122 | } | ||
| 123 | |||
| 124 | @PostMapping("/process-order-list") | ||
| 125 | @Operation(summary = "查询加工单列表") | ||
| 126 | public CommonRes<List<ProcessOrderProcessDtlRSVO>> listByProcessOrderNo() { | ||
| 127 | List<ProcessOrderProcessDtlRSVO> pageVO = demandService.listByProcessOrderNo(); | ||
| 128 | return CommonRes.success(pageVO); | ||
| 129 | } | ||
| 130 | |||
| 131 | //endregion | ||
| 132 | |||
| 133 | } |
| 1 | package com.csbr.qingcloud.portal.controller; | ||
| 2 | |||
| 3 | import com.alibaba.fastjson.JSON; | ||
| 4 | import com.alibaba.fastjson.JSONObject; | ||
| 5 | import com.csbr.cloud.common.response.CommonRes; | ||
| 6 | import com.csbr.cloud.workflow.domain.dto.appove.FlowQueryDTO; | ||
| 7 | import com.csbr.cloud.workflow.domain.dto.appove.FlowUpdateStateDTO; | ||
| 8 | import com.csbr.qingcloud.portal.domain.vo.*; | ||
| 9 | import com.csbr.qingcloud.portal.service.EnterpriseChangeApproveService; | ||
| 10 | import csbr.cloud.entity.annotation.SystemLog; | ||
| 11 | import csbr.cloud.entity.domain.base.vo.PageListVO; | ||
| 12 | import com.csbr.cloud.workflow.domain.dto.callback.BizCallbackDTO; | ||
| 13 | import com.csbr.qingcloud.portal.service.EnterpriseService; | ||
| 14 | import io.swagger.v3.oas.annotations.Operation; | ||
| 15 | import io.swagger.v3.oas.annotations.Parameter; | ||
| 16 | import io.swagger.v3.oas.annotations.tags.Tag; | ||
| 17 | import jakarta.annotation.Resource; | ||
| 18 | import jakarta.validation.Valid; | ||
| 19 | import org.springframework.validation.annotation.Validated; | ||
| 20 | import org.springframework.web.bind.annotation.*; | ||
| 21 | import java.util.List; | ||
| 22 | |||
| 23 | /** | ||
| 24 | * @program: D:/git/ms-data-circulation-portal-service | ||
| 25 | * @description: 企业信息-控制器 | ||
| 26 | * @author: xcq | ||
| 27 | * @create: 2024-12-26 16:18 | ||
| 28 | **/ | ||
| 29 | @RestController | ||
| 30 | @RequestMapping("/enterprise") | ||
| 31 | @Tag(name = "企业信息-控制器") | ||
| 32 | public class EnterpriseController { | ||
| 33 | |||
| 34 | @Resource | ||
| 35 | private EnterpriseService enterpriseService; | ||
| 36 | |||
| 37 | @Resource | ||
| 38 | private EnterpriseChangeApproveService enterpriseChangeApproveService; | ||
| 39 | |||
| 40 | //region 基本操作 | ||
| 41 | |||
| 42 | @PostMapping("/save") | ||
| 43 | @SystemLog(value = "企业信息-新增") | ||
| 44 | @Operation(summary = "企业信息-新增") | ||
| 45 | public CommonRes<Boolean> saveEnterprise(@RequestBody @Valid EnterpriseRQVO vo) { | ||
| 46 | enterpriseService.saveEnterprise(vo); | ||
| 47 | return CommonRes.success(true); | ||
| 48 | } | ||
| 49 | |||
| 50 | @PutMapping("/update") | ||
| 51 | @SystemLog(value = "企业信息-修改") | ||
| 52 | @Operation(summary = "企业信息-修改") | ||
| 53 | public CommonRes<Boolean> updateEnterprise(@RequestBody @Valid EnterpriseRQVO vo) { | ||
| 54 | enterpriseService.updateEnterprise(vo); | ||
| 55 | return CommonRes.success(true); | ||
| 56 | } | ||
| 57 | |||
| 58 | @DeleteMapping("/delete") | ||
| 59 | @SystemLog(value = "企业信息-批量删除") | ||
| 60 | @Operation(summary = "企业信息-批量删除") | ||
| 61 | public CommonRes<Boolean> removeByGuids(@RequestBody List<String> guids) { | ||
| 62 | enterpriseService.removeByGuids(guids); | ||
| 63 | return CommonRes.success(true); | ||
| 64 | } | ||
| 65 | |||
| 66 | @PostMapping("/page-list") | ||
| 67 | @SystemLog(value = "企业信息-分页") | ||
| 68 | @Operation(summary = "企业信息-分页") | ||
| 69 | public CommonRes<PageListVO<EnterpriseRSVO>> pageList(@RequestBody @Valid EnterpriseQueryVO queryVO) { | ||
| 70 | PageListVO<EnterpriseRSVO> pageVO = enterpriseService.pageList(queryVO); | ||
| 71 | return CommonRes.success(pageVO); | ||
| 72 | } | ||
| 73 | |||
| 74 | @PostMapping("/flow/page-list") | ||
| 75 | @SystemLog(value = "企业信息-分页(调用流程)") | ||
| 76 | @Operation(summary = "企业信息-分页(调用流程)") | ||
| 77 | public CommonRes<PageListVO<EnterpriseApproveRSVO>> flowPageList(@RequestBody @Valid FlowQueryDTO dto) { | ||
| 78 | PageListVO<EnterpriseApproveRSVO> pageVO = enterpriseService.flowPageList(dto); | ||
| 79 | return CommonRes.success(pageVO); | ||
| 80 | } | ||
| 81 | |||
| 82 | @GetMapping("/detail") | ||
| 83 | @SystemLog(value = "企业信息-详情") | ||
| 84 | @Operation(summary = "企业信息-详情", | ||
| 85 | parameters = {@Parameter(name = "guid", description = "企业信息唯一标识", required = true)} ) | ||
| 86 | public CommonRes<EnterpriseRSVO> getEnterpriseDetail(@RequestParam String guid) { | ||
| 87 | EnterpriseRSVO vo = enterpriseChangeApproveService.getEnterpriseChangeDetail(guid); | ||
| 88 | return CommonRes.success(vo); | ||
| 89 | } | ||
| 90 | |||
| 91 | @GetMapping("/detail-by-logonUser") | ||
| 92 | @SystemLog(value = "企业信息-根据登陆账号查询详情") | ||
| 93 | @Operation(summary = "企业信息-根据登陆账号查询详情", | ||
| 94 | parameters = {@Parameter(name = "logonUser", description = "登陆账号", required = true)} ) | ||
| 95 | public CommonRes<EnterpriseRSVO> getEnterpriseDetailByLogonUser(@RequestParam String logonUser) { | ||
| 96 | EnterpriseRSVO vo = enterpriseService.getEnterpriseDetailByLogonUser(logonUser); | ||
| 97 | return CommonRes.success(vo); | ||
| 98 | } | ||
| 99 | |||
| 100 | @GetMapping("/detail-by-name") | ||
| 101 | @SystemLog(value = "按名称查企业信息详情") | ||
| 102 | @Operation(summary = "按名称查企业信息详情", | ||
| 103 | parameters = {@Parameter(name = "tenantName", description = "企业名称", required = true)} ) | ||
| 104 | public CommonRes<EnterpriseRSVO> getEnterpriseDetailByName(@RequestParam String tenantName) { | ||
| 105 | EnterpriseRSVO vo = enterpriseService.getEnterpriseDetailByName(tenantName); | ||
| 106 | return CommonRes.success(vo); | ||
| 107 | } | ||
| 108 | |||
| 109 | @PostMapping("/flow-call-back") | ||
| 110 | @SystemLog(value = "企业信息-流程结束后进行业务回调") | ||
| 111 | @Operation(summary = "企业信息-流程结束后进行业务回调", hidden = true) | ||
| 112 | public CommonRes<Boolean> flowCallBack(@RequestBody @Valid BizCallbackDTO dto) { | ||
| 113 | enterpriseService.flowCallBack(dto); | ||
| 114 | return CommonRes.success(true); | ||
| 115 | } | ||
| 116 | |||
| 117 | @PostMapping("/cross-flow-call-back") | ||
| 118 | @SystemLog(value = "企业信息-流程结束后进行业务回调(跨服务审批)") | ||
| 119 | @Operation(summary = "企业信息-流程结束后进行业务回调(跨服务审批)", hidden = true) | ||
| 120 | public CommonRes<Boolean> crossFlowCallBack(@RequestBody @Valid BizCallbackDTO dto) { | ||
| 121 | enterpriseService.crossFlowCallBack(dto); | ||
| 122 | return CommonRes.success(true); | ||
| 123 | } | ||
| 124 | |||
| 125 | @PostMapping("/move-old-data") | ||
| 126 | @SystemLog(value = "将此账号提交的数据需求迁移到新的企业") | ||
| 127 | @Operation(summary = "将此账号提交的数据需求迁移到新的企业", hidden = true) | ||
| 128 | public CommonRes<Boolean> moveOldData(@RequestBody @Valid TenantRQVO vo) { | ||
| 129 | enterpriseService.moveOldData(vo); | ||
| 130 | return CommonRes.success(true); | ||
| 131 | } | ||
| 132 | |||
| 133 | //endregion | ||
| 134 | |||
| 135 | //region 变更申请 | ||
| 136 | |||
| 137 | /** | ||
| 138 | * 前置校验 | ||
| 139 | */ | ||
| 140 | @PostMapping("/check") | ||
| 141 | @SystemLog(value = "前置校验") | ||
| 142 | @Operation(summary = "前置校验") | ||
| 143 | public CommonRes<Boolean> check(@RequestBody EnterpriseRQVO vo) { | ||
| 144 | Boolean result = enterpriseService.check(vo); | ||
| 145 | return CommonRes.success(result); | ||
| 146 | } | ||
| 147 | |||
| 148 | @PostMapping("/change/update") | ||
| 149 | @SystemLog(value = "变更审批-最终更新") | ||
| 150 | @Operation( summary = "变更审批-最终更新" ) | ||
| 151 | public CommonRes<Boolean> changeUpdate(@RequestBody BizCallbackDTO dto) { | ||
| 152 | enterpriseChangeApproveService.changeUpdate(dto); | ||
| 153 | return CommonRes.success(true); | ||
| 154 | } | ||
| 155 | |||
| 156 | @PostMapping("/change/cross-flow-call-back") | ||
| 157 | @SystemLog(value = "变更审批-最终更新(跨平台)") | ||
| 158 | @Operation( summary = "变更审批-最终更新(跨平台)" ) | ||
| 159 | public CommonRes<Boolean> changeCrossFlowCallBack(@RequestBody BizCallbackDTO dto) { | ||
| 160 | enterpriseChangeApproveService.crossFlowCallBack(dto); | ||
| 161 | return CommonRes.success(true); | ||
| 162 | } | ||
| 163 | |||
| 164 | @PostMapping("/change/save") | ||
| 165 | @SystemLog(value = "变更申请-保存数据") | ||
| 166 | @Operation(summary = "变更申请-保存数据") | ||
| 167 | public CommonRes<Boolean> changeSave(@Validated @RequestBody ChangeApproveVO vo) { | ||
| 168 | enterpriseChangeApproveService.changeSave(vo); | ||
| 169 | return CommonRes.success(true); | ||
| 170 | } | ||
| 171 | |||
| 172 | |||
| 173 | @GetMapping("/change/detail") | ||
| 174 | @SystemLog(value = "变更申请-查询详情") | ||
| 175 | @Operation(summary = "变更申请-详情",parameters = { @Parameter(name = "guid", description = "申请唯一标识", required = true)}) | ||
| 176 | public CommonRes<ChangeApproveVO> changeDetail(@RequestParam String guid) { | ||
| 177 | return CommonRes.success(enterpriseChangeApproveService.changeDetail(guid)); | ||
| 178 | } | ||
| 179 | |||
| 180 | @DeleteMapping("/change/delete") | ||
| 181 | @SystemLog(value = "变更申请-批量删除") | ||
| 182 | @Operation(summary = "变更申请-批量删除") | ||
| 183 | public CommonRes<Boolean> changeRemoveByGuids(@RequestBody List<String> guids) { | ||
| 184 | enterpriseChangeApproveService.removeByGuids(guids); | ||
| 185 | return CommonRes.success(true); | ||
| 186 | } | ||
| 187 | |||
| 188 | @DeleteMapping("/change/cross-delete") | ||
| 189 | @SystemLog(value = "变更申请-批量删除(跨平台)") | ||
| 190 | @Operation(summary = "变更申请-批量删除(跨平台)", hidden = true) | ||
| 191 | public CommonRes<Boolean> crossRemoveByGuids(@RequestBody List<String> zqBizGuids) { | ||
| 192 | enterpriseChangeApproveService.crossRemoveByBizGuid(zqBizGuids); | ||
| 193 | return CommonRes.success(true); | ||
| 194 | } | ||
| 195 | |||
| 196 | //endregion | ||
| 197 | |||
| 198 | } |
| 1 | package com.csbr.qingcloud.portal.controller; | ||
| 2 | |||
| 3 | import com.csbr.cloud.common.response.CommonRes; | ||
| 4 | import csbr.cloud.entity.annotation.SystemLog; | ||
| 5 | import csbr.cloud.entity.domain.base.vo.PageListVO; | ||
| 6 | import com.csbr.cloud.workflow.domain.dto.callback.BizCallbackDTO; | ||
| 7 | import com.csbr.qingcloud.portal.domain.vo.ServicerMaintainQueryVO; | ||
| 8 | import com.csbr.qingcloud.portal.domain.vo.ServicerMaintainRQVO; | ||
| 9 | import com.csbr.qingcloud.portal.domain.vo.ServicerMaintainRSVO; | ||
| 10 | import com.csbr.qingcloud.portal.service.ServicerMaintainService; | ||
| 11 | import io.swagger.v3.oas.annotations.Operation; | ||
| 12 | import io.swagger.v3.oas.annotations.Parameter; | ||
| 13 | import io.swagger.v3.oas.annotations.tags.Tag; | ||
| 14 | import jakarta.annotation.Resource; | ||
| 15 | import jakarta.validation.Valid; | ||
| 16 | import org.springframework.web.bind.annotation.*; | ||
| 17 | |||
| 18 | import java.util.List; | ||
| 19 | |||
| 20 | /** | ||
| 21 | * @program: D:/git/ms-data-circulation-portal-service | ||
| 22 | * @description: 服务商维护-控制器 | ||
| 23 | * @author: xcq | ||
| 24 | * @create: 2024-12-31 18:49 | ||
| 25 | **/ | ||
| 26 | @RestController | ||
| 27 | @RequestMapping("/servicer-maintain") | ||
| 28 | @Tag(name = "服务商维护-控制器") | ||
| 29 | public class ServicerMaintainController { | ||
| 30 | |||
| 31 | @Resource | ||
| 32 | private ServicerMaintainService servicerMaintainService; | ||
| 33 | |||
| 34 | //region 基本操作 | ||
| 35 | |||
| 36 | @PostMapping("/save") | ||
| 37 | @SystemLog(value = "服务商维护-新增") | ||
| 38 | @Operation(summary = "服务商维护-新增") | ||
| 39 | public CommonRes<Boolean> saveServicerMaintain(@RequestBody @Valid ServicerMaintainRQVO vo) { | ||
| 40 | servicerMaintainService.saveServicerMaintain(vo); | ||
| 41 | return CommonRes.success(true); | ||
| 42 | } | ||
| 43 | |||
| 44 | @PutMapping("/update") | ||
| 45 | @SystemLog(value = "服务商维护-修改") | ||
| 46 | @Operation(summary = "服务商维护-修改") | ||
| 47 | public CommonRes<Boolean> updateServicerMaintain(@RequestBody @Valid ServicerMaintainRQVO vo) { | ||
| 48 | servicerMaintainService.updateServicerMaintain(vo); | ||
| 49 | return CommonRes.success(true); | ||
| 50 | } | ||
| 51 | |||
| 52 | @DeleteMapping("/delete") | ||
| 53 | @SystemLog(value = "服务商维护-批量删除") | ||
| 54 | @Operation(summary = "服务商维护-批量删除") | ||
| 55 | public CommonRes<Boolean> removeByGuids(@RequestBody List<String> guids) { | ||
| 56 | servicerMaintainService.removeByGuids(guids); | ||
| 57 | return CommonRes.success(true); | ||
| 58 | } | ||
| 59 | |||
| 60 | @PostMapping("/page-list") | ||
| 61 | @SystemLog(value = "服务商维护-分页") | ||
| 62 | @Operation(summary = "服务商维护-分页") | ||
| 63 | public CommonRes<PageListVO<ServicerMaintainRSVO>> pageList(@RequestBody @Valid ServicerMaintainQueryVO queryVO) { | ||
| 64 | PageListVO<ServicerMaintainRSVO> pageVO = servicerMaintainService.pageList(queryVO); | ||
| 65 | return CommonRes.success(pageVO); | ||
| 66 | } | ||
| 67 | |||
| 68 | @GetMapping("/detail") | ||
| 69 | @SystemLog(value = "服务商维护-详情") | ||
| 70 | @Operation( | ||
| 71 | summary = "服务商维护-详情", | ||
| 72 | parameters = { | ||
| 73 | @Parameter(name = "guid", description = "服务商维护唯一标识", required = true)} | ||
| 74 | ) | ||
| 75 | public CommonRes<ServicerMaintainRSVO> getServicerMaintainDetail(@RequestParam String guid) { | ||
| 76 | ServicerMaintainRSVO vo = servicerMaintainService.getServicerMaintainDetail(guid); | ||
| 77 | return CommonRes.success(vo); | ||
| 78 | } | ||
| 79 | |||
| 80 | @PostMapping("/flow-call-back") | ||
| 81 | @SystemLog(value = "服务商维护-流程结束后进行业务回调") | ||
| 82 | @Operation(summary = "服务商维护-流程结束后进行业务回调", hidden = true) | ||
| 83 | public CommonRes<Boolean> flowCallBack(@RequestBody @Valid BizCallbackDTO dto) { | ||
| 84 | servicerMaintainService.flowCallBack(dto); | ||
| 85 | return CommonRes.success(true); | ||
| 86 | } | ||
| 87 | |||
| 88 | //endregion | ||
| 89 | |||
| 90 | } |
| 1 | package com.csbr.qingcloud.portal.domain.vo; | ||
| 2 | |||
| 3 | import lombok.Data; | ||
| 4 | |||
| 5 | /** | ||
| 6 | * @program: ms-user-scm-service | ||
| 7 | * @description: 行政区 | ||
| 8 | * @author: yio | ||
| 9 | * @create: 2021-01-14 15:39 | ||
| 10 | **/ | ||
| 11 | @Data | ||
| 12 | public class BoroughPOJO { | ||
| 13 | private String code; | ||
| 14 | private String name; | ||
| 15 | private String parentId; | ||
| 16 | private String isPCapital; | ||
| 17 | private String isDeleted; | ||
| 18 | /** 城市等级 (0 一线城市,1 新一线城市,2 二线城市,3 三线城市,4 四线城市,5 五线城市,6 六线城市)*/ | ||
| 19 | private String areaLevel; | ||
| 20 | } |
| 1 | package com.csbr.qingcloud.portal.domain.vo; | ||
| 2 | |||
| 3 | import io.swagger.v3.oas.annotations.media.Schema; | ||
| 4 | import lombok.Data; | ||
| 5 | |||
| 6 | /** | ||
| 7 | * @program: ms-hc-workflow-service | ||
| 8 | * @description: 通用变更审批对象 | ||
| 9 | * @author: XiaoCQ | ||
| 10 | * @create: 2024-01-20 | ||
| 11 | **/ | ||
| 12 | @Data | ||
| 13 | @Schema(name = "通用变更审批对象") | ||
| 14 | public class ChangeApproveVO { | ||
| 15 | |||
| 16 | /** | ||
| 17 | * 各变更业务唯一标识 | ||
| 18 | */ | ||
| 19 | @Schema(description = "各变更业务唯一标识") | ||
| 20 | private String guid; | ||
| 21 | |||
| 22 | /** | ||
| 23 | * 审批流唯一标识 | ||
| 24 | */ | ||
| 25 | @Schema(description = "审批流唯一标识") | ||
| 26 | private String approveGuid; | ||
| 27 | |||
| 28 | @Schema(description = "业务审批状态") | ||
| 29 | private String bizApproveState; | ||
| 30 | |||
| 31 | @Schema(description = "原审批流唯一标识") | ||
| 32 | private String sourceApproveGuid; | ||
| 33 | |||
| 34 | /** | ||
| 35 | * 源数据GUID | ||
| 36 | */ | ||
| 37 | @Schema(description = "源数据GUID") | ||
| 38 | private String sourceGuid; | ||
| 39 | |||
| 40 | /** | ||
| 41 | * 业务数据 | ||
| 42 | */ | ||
| 43 | @Schema(description = "业务数据") | ||
| 44 | private String bizDataJson; | ||
| 45 | |||
| 46 | @Schema(description = "业务数据明细") | ||
| 47 | private String bizDataDetailJson; | ||
| 48 | |||
| 49 | /** | ||
| 50 | * 原业务数据 | ||
| 51 | */ | ||
| 52 | @Schema(description = "原业务数据") | ||
| 53 | private String oldBizDataJson; | ||
| 54 | |||
| 55 | @Schema(description = "原业务数据明细") | ||
| 56 | private String oldBizDataDetailJson; | ||
| 57 | |||
| 58 | private String zqName; | ||
| 59 | private String zqBizGuid; | ||
| 60 | |||
| 61 | } | ||
| ... | \ No newline at end of file | ... | \ No newline at end of file |
| 1 | package com.csbr.qingcloud.portal.domain.vo; | ||
| 2 | |||
| 3 | import io.swagger.v3.oas.annotations.media.Schema; | ||
| 4 | import lombok.Data; | ||
| 5 | |||
| 6 | /** | ||
| 7 | * @description: 审批变更检查实体 | ||
| 8 | * @author: XiaoCQ | ||
| 9 | * @create: 2025-02-20 | ||
| 10 | */ | ||
| 11 | @Data | ||
| 12 | @Schema(name = "审批变更检查实体") | ||
| 13 | public class ChangeCheckDTO { | ||
| 14 | |||
| 15 | @Schema(description = "json") | ||
| 16 | private String json; | ||
| 17 | |||
| 18 | public ChangeCheckDTO(){ | ||
| 19 | } | ||
| 20 | |||
| 21 | public ChangeCheckDTO(String json){ | ||
| 22 | this.json = json; | ||
| 23 | } | ||
| 24 | |||
| 25 | } |
| 1 | package com.csbr.qingcloud.portal.domain.vo; | ||
| 2 | |||
| 3 | import csbr.cloud.entity.domain.base.vo.CsbrBaseVO; | ||
| 4 | import io.swagger.v3.oas.annotations.media.Schema; | ||
| 5 | import lombok.Data; | ||
| 6 | import lombok.EqualsAndHashCode; | ||
| 7 | import lombok.experimental.Accessors; | ||
| 8 | |||
| 9 | import java.math.BigDecimal; | ||
| 10 | import java.time.LocalDateTime; | ||
| 11 | |||
| 12 | /** | ||
| 13 | * 变更信息视图对象类 | ||
| 14 | * | ||
| 15 | * @author xiaocq | ||
| 16 | * @date 2024-12-30 | ||
| 17 | */ | ||
| 18 | @Data | ||
| 19 | public class ChangeInfoVO extends CsbrBaseVO { | ||
| 20 | |||
| 21 | @Schema(description = "英文名称") | ||
| 22 | private String nameEn; | ||
| 23 | |||
| 24 | @Schema(description = "名称") | ||
| 25 | private String name; | ||
| 26 | |||
| 27 | @Schema(description = "日期") | ||
| 28 | private String date; | ||
| 29 | |||
| 30 | @Schema(description = "变更前") | ||
| 31 | private String before; | ||
| 32 | |||
| 33 | @Schema(description = "变更后") | ||
| 34 | private String after; | ||
| 35 | |||
| 36 | } |
| 1 | package com.csbr.qingcloud.portal.domain.vo; | ||
| 2 | |||
| 3 | import lombok.Data; | ||
| 4 | |||
| 5 | /** 对比对象 */ | ||
| 6 | @Data | ||
| 7 | public class CompareResult { | ||
| 8 | /** 字段名 */ | ||
| 9 | private String fieldName; | ||
| 10 | /** 旧值 */ | ||
| 11 | private Object oldValue; | ||
| 12 | /** 新值 */ | ||
| 13 | private Object newValue; | ||
| 14 | /** 字段中文名 */ | ||
| 15 | private String fieldComment; | ||
| 16 | } |
| 1 | package com.csbr.qingcloud.portal.domain.vo; | ||
| 2 | |||
| 3 | import com.csbr.cloud.workflow.domain.dto.appove.FlowUpdateStateDTO; | ||
| 4 | import io.swagger.v3.oas.annotations.media.Schema; | ||
| 5 | import lombok.Data; | ||
| 6 | import lombok.experimental.Accessors; | ||
| 7 | |||
| 8 | import java.math.BigDecimal; | ||
| 9 | |||
| 10 | /** | ||
| 11 | * 项目结项表 视图对象类 | ||
| 12 | * | ||
| 13 | * @author xiaocq | ||
| 14 | * @date 2024-03-04 | ||
| 15 | */ | ||
| 16 | @Data | ||
| 17 | @Accessors(chain = true) | ||
| 18 | @Schema(name = "项目结项审批传参") | ||
| 19 | public class DemandApproveVO extends FlowUpdateStateDTO { | ||
| 20 | |||
| 21 | @Schema(description = "业务唯一标识") | ||
| 22 | private String bizGuid; | ||
| 23 | |||
| 24 | @Schema(description = "合同附件") | ||
| 25 | private String contractAttachJson; | ||
| 26 | |||
| 27 | @Schema(description = "加工单位类型") | ||
| 28 | private String processCompanyType; | ||
| 29 | |||
| 30 | @Schema(description = "加工单位唯一标识") | ||
| 31 | private String processCompanyGuid; | ||
| 32 | |||
| 33 | @Schema(description = "加工单位名称") | ||
| 34 | private String processCompanyName; | ||
| 35 | |||
| 36 | |||
| 37 | } |
| 1 | package com.csbr.qingcloud.portal.domain.vo; | ||
| 2 | |||
| 3 | import com.csbr.cloud.mybatis.annotations.LikeQuery; | ||
| 4 | import com.csbr.cloud.mybatis.enums.LikeQueryEnum; | ||
| 5 | import com.csbr.cloud.workflow.domain.dto.appove.FlowBizGuidQueryDTO; | ||
| 6 | import csbr.cloud.entity.domain.base.dto.BasePageDTO; | ||
| 7 | import io.swagger.v3.oas.annotations.media.Schema; | ||
| 8 | import lombok.Data; | ||
| 9 | import lombok.EqualsAndHashCode; | ||
| 10 | |||
| 11 | import java.util.List; | ||
| 12 | |||
| 13 | /** | ||
| 14 | * @program: D:/git/ms-data-circulation-portal-service | ||
| 15 | * @description: 数据需求查询参数 | ||
| 16 | * @author: xcq | ||
| 17 | * @create: 2024-12-31 18:46 | ||
| 18 | **/ | ||
| 19 | @EqualsAndHashCode(callSuper = true) | ||
| 20 | @Data | ||
| 21 | @Schema(title = "数据需求查询参数") | ||
| 22 | public class DemandPortalQueryVO extends BasePageDTO { | ||
| 23 | |||
| 24 | @Schema(description = "数据需求名称") | ||
| 25 | @LikeQuery(type = LikeQueryEnum.ALL) | ||
| 26 | private String dataDemandName; | ||
| 27 | |||
| 28 | @Schema(description = "需求类型") | ||
| 29 | private String requirementType; | ||
| 30 | |||
| 31 | @Schema(description = "交付标的") | ||
| 32 | private String updateCycle; | ||
| 33 | |||
| 34 | } |
| 1 | package com.csbr.qingcloud.portal.domain.vo; | ||
| 2 | |||
| 3 | import com.fasterxml.jackson.annotation.JsonFormat; | ||
| 4 | import csbr.cloud.entity.domain.base.vo.BaseVO; | ||
| 5 | import io.swagger.v3.oas.annotations.media.Schema; | ||
| 6 | import lombok.Data; | ||
| 7 | |||
| 8 | import java.math.BigDecimal; | ||
| 9 | import java.util.Date; | ||
| 10 | |||
| 11 | /** | ||
| 12 | * @program: D:/git/ms-data-circulation-portal-service | ||
| 13 | * @description: 数据需求门户返回参数 | ||
| 14 | * @author: xcq | ||
| 15 | * @create: 2024-12-31 18:46 | ||
| 16 | **/ | ||
| 17 | @Data | ||
| 18 | @Schema(title = "数据需求门户返回参数") | ||
| 19 | public class DemandPortalRSVO extends BaseVO { | ||
| 20 | @Schema(description = "系统唯一标识") | ||
| 21 | private String guid; | ||
| 22 | |||
| 23 | @Schema(description = "数据需求名称") | ||
| 24 | private String dataDemandName; | ||
| 25 | |||
| 26 | @Schema(description = "需求类型") | ||
| 27 | private String requirementType; | ||
| 28 | |||
| 29 | @Schema(description = "需求开始时间") | ||
| 30 | @JsonFormat(pattern = "yyyy-MM-dd", timezone = "GMT+8") | ||
| 31 | private Date requirementTermSdate; | ||
| 32 | |||
| 33 | @Schema(description = "需求结束时间") | ||
| 34 | @JsonFormat(pattern = "yyyy-MM-dd", timezone = "GMT+8") | ||
| 35 | private Date requirementTermEdate; | ||
| 36 | |||
| 37 | @Schema(description = "最低预算") | ||
| 38 | private BigDecimal minBudget; | ||
| 39 | |||
| 40 | @Schema(description = "最高预算") | ||
| 41 | private BigDecimal maxBudget; | ||
| 42 | |||
| 43 | @Schema(description = "数据价格") | ||
| 44 | private String costSource; | ||
| 45 | |||
| 46 | @Schema(description = "需求内容") | ||
| 47 | private String requirementContent; | ||
| 48 | |||
| 49 | @Schema(description = "交付标的") | ||
| 50 | private String updateCycle; | ||
| 51 | |||
| 52 | } |
| 1 | package com.csbr.qingcloud.portal.domain.vo; | ||
| 2 | |||
| 3 | import com.csbr.cloud.mybatis.annotations.LikeQuery; | ||
| 4 | import com.csbr.cloud.mybatis.enums.LikeQueryEnum; | ||
| 5 | import com.csbr.cloud.workflow.domain.dto.appove.FlowBizGuidQueryDTO; | ||
| 6 | import io.swagger.v3.oas.annotations.media.Schema; | ||
| 7 | import lombok.EqualsAndHashCode; | ||
| 8 | import lombok.Data; | ||
| 9 | import java.math.BigDecimal; | ||
| 10 | import java.util.Date; | ||
| 11 | import java.util.List; | ||
| 12 | |||
| 13 | /** | ||
| 14 | * @program: D:/git/ms-data-circulation-portal-service | ||
| 15 | * @description: 数据需求查询参数 | ||
| 16 | * @author: xcq | ||
| 17 | * @create: 2024-12-31 18:46 | ||
| 18 | **/ | ||
| 19 | @EqualsAndHashCode(callSuper = true) | ||
| 20 | @Data | ||
| 21 | @Schema(title = "数据需求查询参数") | ||
| 22 | public class DemandQueryVO extends FlowBizGuidQueryDTO { | ||
| 23 | |||
| 24 | @LikeQuery(type = LikeQueryEnum.ALL) | ||
| 25 | @Schema(description = "数据需求名称") | ||
| 26 | private String dataDemandName; | ||
| 27 | |||
| 28 | @Schema(description = "需求类型") | ||
| 29 | private String requirementType; | ||
| 30 | |||
| 31 | @Schema(description = "需求分类【1新增 2调整】") | ||
| 32 | private String demandCategory; | ||
| 33 | |||
| 34 | @LikeQuery(type = LikeQueryEnum.ALL) | ||
| 35 | @Schema(description = "发起人") | ||
| 36 | private String createUserName; | ||
| 37 | |||
| 38 | /** | ||
| 39 | * 业务审批状态【N 草稿中,A 审批中,Y 已通过,R 驳回,C 已撤销,D 已废弃】 | ||
| 40 | */ | ||
| 41 | @Schema(description = "业务审批状态【N 草稿中,A 审批中,Y 已通过,R 驳回,C 已撤销,D 已废弃】") | ||
| 42 | private String bizApproveState; | ||
| 43 | |||
| 44 | /******** 自定义扩展 *****/ | ||
| 45 | |||
| 46 | /** | ||
| 47 | * 数据唯一标识【List集合】 | ||
| 48 | */ | ||
| 49 | @Schema(description = "数据唯一标识", hidden = true) | ||
| 50 | private List<String> guidList; | ||
| 51 | |||
| 52 | /** | ||
| 53 | * 是否调用查询的判断 | ||
| 54 | */ | ||
| 55 | @Schema(description = "是否调用查询的判断", hidden = true) | ||
| 56 | private Boolean isNeedQuery; | ||
| 57 | |||
| 58 | } |
| 1 | package com.csbr.qingcloud.portal.domain.vo; | ||
| 2 | |||
| 3 | import com.csbr.cloud.workflow.domain.vo.appove.FlowRQBaseVO; | ||
| 4 | import io.swagger.v3.oas.annotations.media.Schema; | ||
| 5 | import com.fasterxml.jackson.annotation.JsonFormat; | ||
| 6 | import jdk.jfr.Name; | ||
| 7 | import lombok.Data; | ||
| 8 | import java.math.BigDecimal; | ||
| 9 | import java.util.Date; | ||
| 10 | |||
| 11 | /** | ||
| 12 | * @program: D:/git/ms-data-circulation-portal-service | ||
| 13 | * @description: 数据需求新增、修改参数 | ||
| 14 | * @author: xcq | ||
| 15 | * @create: 2024-12-31 18:46 | ||
| 16 | **/ | ||
| 17 | @Data | ||
| 18 | @Schema(title = "数据需求新增、修改参数") | ||
| 19 | public class DemandRQVO extends FlowRQBaseVO { | ||
| 20 | |||
| 21 | /** | ||
| 22 | * 数据需求名称 | ||
| 23 | */ | ||
| 24 | @Schema(description = "数据需求名称") | ||
| 25 | private String dataDemandName; | ||
| 26 | |||
| 27 | /** | ||
| 28 | * 需求类型 | ||
| 29 | */ | ||
| 30 | @Schema(description = "需求类型") | ||
| 31 | private String requirementType; | ||
| 32 | |||
| 33 | @Schema(title = "专区名称") | ||
| 34 | private String zqName; | ||
| 35 | |||
| 36 | /** | ||
| 37 | * 需求分类【1新增 2调整】 | ||
| 38 | */ | ||
| 39 | @Schema(description = "需求分类【1新增 2调整】") | ||
| 40 | private String demandCategory; | ||
| 41 | |||
| 42 | /** | ||
| 43 | * 数据产品唯一标识 | ||
| 44 | */ | ||
| 45 | @Schema(description = "数据产品唯一标识") | ||
| 46 | private String dataProductGuid; | ||
| 47 | |||
| 48 | /** | ||
| 49 | * 需求开始时间 | ||
| 50 | */ | ||
| 51 | @Schema(description = "需求开始时间") | ||
| 52 | @JsonFormat(pattern = "yyyy-MM-dd", timezone = "GMT+8") | ||
| 53 | private Date requirementTermSdate; | ||
| 54 | |||
| 55 | /** | ||
| 56 | * 需求结束时间 | ||
| 57 | */ | ||
| 58 | @Schema(description = "需求结束时间") | ||
| 59 | @JsonFormat(pattern = "yyyy-MM-dd", timezone = "GMT+8") | ||
| 60 | private Date requirementTermEdate; | ||
| 61 | |||
| 62 | /** | ||
| 63 | * 需求内容 | ||
| 64 | */ | ||
| 65 | @Schema(description = "需求内容") | ||
| 66 | private String requirementContent; | ||
| 67 | |||
| 68 | /** | ||
| 69 | * 数据需求字段【数据格式:[{"name":"","path":""},{"name":"","path":""}]】 | ||
| 70 | */ | ||
| 71 | @Schema(description = "数据需求字段【数据格式:[{\"name\":\"\",\"path\":\"\"},{\"name\":\"\",\"path\":\"\"}]】") | ||
| 72 | private String dataDemandFieldAttachJson; | ||
| 73 | |||
| 74 | /** | ||
| 75 | * 期望交付日期 | ||
| 76 | */ | ||
| 77 | @Schema(description = "期望交付日期") | ||
| 78 | @JsonFormat(pattern = "yyyy-MM-dd", timezone = "GMT+8") | ||
| 79 | private Date deliveryTime; | ||
| 80 | |||
| 81 | /** | ||
| 82 | * 最低预算 | ||
| 83 | */ | ||
| 84 | @Schema(description = "最低预算") | ||
| 85 | private BigDecimal minBudget; | ||
| 86 | |||
| 87 | /** | ||
| 88 | * 最高预算 | ||
| 89 | */ | ||
| 90 | @Schema(description = "最高预算") | ||
| 91 | private BigDecimal maxBudget; | ||
| 92 | |||
| 93 | /** | ||
| 94 | * 费用来源 | ||
| 95 | */ | ||
| 96 | @Schema(description = "费用来源") | ||
| 97 | private String costSource; | ||
| 98 | |||
| 99 | /** | ||
| 100 | * 更新周期【取数据字典:周期,1 年度,2 半年度,3 季度,4 月度】 | ||
| 101 | */ | ||
| 102 | @Schema(description = "更新周期【取数据字典:周期,1 年度,2 半年度,3 季度,4 月度】") | ||
| 103 | private String updateCycle; | ||
| 104 | |||
| 105 | /** | ||
| 106 | * 获取路径方式 | ||
| 107 | */ | ||
| 108 | @Schema(description = "获取路径方式") | ||
| 109 | private String requestType; | ||
| 110 | |||
| 111 | /** | ||
| 112 | * 场景名称 | ||
| 113 | */ | ||
| 114 | @Schema(description = "场景名称") | ||
| 115 | private String sceneName; | ||
| 116 | |||
| 117 | /** | ||
| 118 | * 应用场景描述 | ||
| 119 | */ | ||
| 120 | @Schema(description = "应用场景描述") | ||
| 121 | private String sceneDescription; | ||
| 122 | |||
| 123 | /** | ||
| 124 | * 数据质量要求 | ||
| 125 | */ | ||
| 126 | @Schema(description = "数据质量要求") | ||
| 127 | private String qualityDemand; | ||
| 128 | |||
| 129 | /** | ||
| 130 | * 隐私合规要求 | ||
| 131 | */ | ||
| 132 | @Schema(description = "隐私合规要求") | ||
| 133 | private String privacyDemand; | ||
| 134 | |||
| 135 | /** | ||
| 136 | * 其他补充内容 | ||
| 137 | */ | ||
| 138 | @Schema(description = "其他补充内容") | ||
| 139 | private String otherContent; | ||
| 140 | |||
| 141 | /** | ||
| 142 | * 联系人 | ||
| 143 | */ | ||
| 144 | @Schema(description = "联系人") | ||
| 145 | private String contacts; | ||
| 146 | |||
| 147 | /** | ||
| 148 | * 需求单位 | ||
| 149 | */ | ||
| 150 | @Schema(description = "需求单位") | ||
| 151 | private String requirementUnit; | ||
| 152 | |||
| 153 | /** | ||
| 154 | * 联系方式 | ||
| 155 | */ | ||
| 156 | @Schema(description = "联系方式") | ||
| 157 | private String contactInformation; | ||
| 158 | |||
| 159 | /** | ||
| 160 | * 业务审批状态【N 草稿中,A 审批中,Y 已通过,R 驳回,C 已撤销,D 已废弃; 默认 N】 | ||
| 161 | */ | ||
| 162 | @Schema(description = "业务审批状态【N 草稿中,A 审批中,Y 已通过,R 驳回,C 已撤销,D 已废弃; 默认 N】") | ||
| 163 | private String bizApproveState; | ||
| 164 | |||
| 165 | /** | ||
| 166 | * 加工单生成时间 | ||
| 167 | */ | ||
| 168 | @Schema(description = "加工单生成时间") | ||
| 169 | @JsonFormat(pattern = "yyyy-MM-dd HH:mm:ss", timezone = "GMT+8") | ||
| 170 | private Date processingGenerateTime; | ||
| 171 | |||
| 172 | /** | ||
| 173 | * 验收完成时间 | ||
| 174 | */ | ||
| 175 | @Schema(description = "验收完成时间") | ||
| 176 | @JsonFormat(pattern = "yyyy-MM-dd", timezone = "GMT+8") | ||
| 177 | private Date acceptFinishTime; | ||
| 178 | |||
| 179 | /** | ||
| 180 | * 完成周期 | ||
| 181 | */ | ||
| 182 | @Schema(description = "完成周期") | ||
| 183 | private Integer finishCycle; | ||
| 184 | |||
| 185 | /** | ||
| 186 | * 资源获取状态【N未开始 A进行中 Y已完成】 | ||
| 187 | */ | ||
| 188 | @Schema(description = "资源获取状态【N未开始 A进行中 Y已完成】") | ||
| 189 | private String resourceAcquisitionState; | ||
| 190 | |||
| 191 | /** | ||
| 192 | * 产品加工状态【N未开始 A进行中 Y已完成】 | ||
| 193 | */ | ||
| 194 | @Schema(description = "产品加工状态【N未开始 A进行中 Y已完成】") | ||
| 195 | private String productProcessingState; | ||
| 196 | |||
| 197 | /** | ||
| 198 | * 产品交付状态【N未开始 A进行中 Y已完成】 | ||
| 199 | */ | ||
| 200 | @Schema(description = "产品交付状态【N未开始 A进行中 Y已完成】") | ||
| 201 | private String productDeliveryState; | ||
| 202 | |||
| 203 | /** | ||
| 204 | * 产品验收状态【N未开始 A进行中 Y已完成】 | ||
| 205 | */ | ||
| 206 | @Schema(description = "产品验收状态【N未开始 A进行中 Y已完成】") | ||
| 207 | private String productAcceptState; | ||
| 208 | |||
| 209 | /******** 库表存储属性 需处理 *****/ | ||
| 210 | |||
| 211 | /******** 自定义扩展 *****/ | ||
| 212 | |||
| 213 | @Schema(description = "合同附件") | ||
| 214 | private String contractAttachJson; | ||
| 215 | |||
| 216 | @Schema(description = "加工单位类型") | ||
| 217 | private String processCompanyType; | ||
| 218 | |||
| 219 | @Schema(description = "加工单位唯一标识") | ||
| 220 | private String processCompanyGuid; | ||
| 221 | |||
| 222 | @Schema(description = "加工单位名称") | ||
| 223 | private String processCompanyName; | ||
| 224 | |||
| 225 | @Schema(title = "上架状态(Y 上架 N 下架)") | ||
| 226 | private String listingStatus; | ||
| 227 | |||
| 228 | /******** 子对象 *****/ | ||
| 229 | |||
| 230 | } |
| 1 | package com.csbr.qingcloud.portal.domain.vo; | ||
| 2 | |||
| 3 | import com.csbr.cloud.workflow.domain.vo.appove.BizApproveVO; | ||
| 4 | import com.fasterxml.jackson.annotation.JsonFormat; | ||
| 5 | import io.swagger.v3.oas.annotations.media.Schema; | ||
| 6 | import lombok.Data; | ||
| 7 | |||
| 8 | import java.math.BigDecimal; | ||
| 9 | import java.util.Date; | ||
| 10 | |||
| 11 | /** | ||
| 12 | * @program: D:/git/ms-data-circulation-portal-service | ||
| 13 | * @description: 数据需求返回参数 | ||
| 14 | * @author: xcq | ||
| 15 | * @create: 2024-12-31 18:46 | ||
| 16 | **/ | ||
| 17 | @Data | ||
| 18 | @Schema(title = "数据需求返回参数") | ||
| 19 | public class DemandRSVO { | ||
| 20 | |||
| 21 | /** | ||
| 22 | * 系统唯一标识 | ||
| 23 | */ | ||
| 24 | @Schema(description = "系统唯一标识") | ||
| 25 | private String guid; | ||
| 26 | |||
| 27 | /** | ||
| 28 | * 数据需求名称 | ||
| 29 | */ | ||
| 30 | @Schema(description = "数据需求名称") | ||
| 31 | private String dataDemandName; | ||
| 32 | |||
| 33 | /** | ||
| 34 | * 需求类型 | ||
| 35 | */ | ||
| 36 | @Schema(description = "需求类型") | ||
| 37 | private String requirementType; | ||
| 38 | |||
| 39 | /** | ||
| 40 | * 需求分类【1新增 2调整】 | ||
| 41 | */ | ||
| 42 | @Schema(description = "需求分类【1新增 2调整】") | ||
| 43 | private String demandCategory; | ||
| 44 | |||
| 45 | /** | ||
| 46 | * 数据产品唯一标识 | ||
| 47 | */ | ||
| 48 | @Schema(description = "数据产品唯一标识") | ||
| 49 | private String dataProductGuid; | ||
| 50 | |||
| 51 | /** | ||
| 52 | * 需求开始时间 | ||
| 53 | */ | ||
| 54 | @Schema(description = "需求开始时间") | ||
| 55 | @JsonFormat(pattern = "yyyy-MM-dd", timezone = "GMT+8") | ||
| 56 | private Date requirementTermSdate; | ||
| 57 | |||
| 58 | /** | ||
| 59 | * 需求结束时间 | ||
| 60 | */ | ||
| 61 | @Schema(description = "需求结束时间") | ||
| 62 | @JsonFormat(pattern = "yyyy-MM-dd", timezone = "GMT+8") | ||
| 63 | private Date requirementTermEdate; | ||
| 64 | |||
| 65 | /** | ||
| 66 | * 需求内容 | ||
| 67 | */ | ||
| 68 | @Schema(description = "需求内容") | ||
| 69 | private String requirementContent; | ||
| 70 | |||
| 71 | /** | ||
| 72 | * 数据需求字段【数据格式:[{"name":"","path":""},{"name":"","path":""}]】 | ||
| 73 | */ | ||
| 74 | @Schema(description = "数据需求字段【数据格式:[{\"name\":\"\",\"path\":\"\"},{\"name\":\"\",\"path\":\"\"}]】") | ||
| 75 | private String dataDemandFieldAttachJson; | ||
| 76 | |||
| 77 | /** | ||
| 78 | * 期望交付时间 | ||
| 79 | */ | ||
| 80 | @Schema(description = "期望交付时间") | ||
| 81 | @JsonFormat(pattern = "yyyy-MM-dd", timezone = "GMT+8") | ||
| 82 | private Date deliveryTime; | ||
| 83 | |||
| 84 | /** | ||
| 85 | * 最低预算 | ||
| 86 | */ | ||
| 87 | @Schema(description = "最低预算") | ||
| 88 | private BigDecimal minBudget; | ||
| 89 | |||
| 90 | /** | ||
| 91 | * 最高预算 | ||
| 92 | */ | ||
| 93 | @Schema(description = "最高预算") | ||
| 94 | private BigDecimal maxBudget; | ||
| 95 | |||
| 96 | /** | ||
| 97 | * 费用来源 | ||
| 98 | */ | ||
| 99 | @Schema(description = "费用来源") | ||
| 100 | private String costSource; | ||
| 101 | |||
| 102 | /** | ||
| 103 | * 更新周期【取数据字典:周期,1 年度,2 半年度,3 季度,4 月度】 | ||
| 104 | */ | ||
| 105 | @Schema(description = "更新周期【取数据字典:周期,1 年度,2 半年度,3 季度,4 月度】") | ||
| 106 | private String updateCycle; | ||
| 107 | |||
| 108 | /** | ||
| 109 | * 获取路径方式 | ||
| 110 | */ | ||
| 111 | @Schema(description = "获取路径方式") | ||
| 112 | private String requestType; | ||
| 113 | |||
| 114 | /** | ||
| 115 | * 场景名称 | ||
| 116 | */ | ||
| 117 | @Schema(description = "场景名称") | ||
| 118 | private String sceneName; | ||
| 119 | |||
| 120 | /** | ||
| 121 | * 应用场景描述 | ||
| 122 | */ | ||
| 123 | @Schema(description = "应用场景描述") | ||
| 124 | private String sceneDescription; | ||
| 125 | |||
| 126 | /** | ||
| 127 | * 数据质量要求 | ||
| 128 | */ | ||
| 129 | @Schema(description = "数据质量要求") | ||
| 130 | private String qualityDemand; | ||
| 131 | |||
| 132 | /** | ||
| 133 | * 隐私合规要求 | ||
| 134 | */ | ||
| 135 | @Schema(description = "隐私合规要求") | ||
| 136 | private String privacyDemand; | ||
| 137 | |||
| 138 | /** | ||
| 139 | * 其他补充内容 | ||
| 140 | */ | ||
| 141 | @Schema(description = "其他补充内容") | ||
| 142 | private String otherContent; | ||
| 143 | |||
| 144 | /** | ||
| 145 | * 联系人 | ||
| 146 | */ | ||
| 147 | @Schema(description = "联系人") | ||
| 148 | private String contacts; | ||
| 149 | |||
| 150 | /** | ||
| 151 | * 需求单位 | ||
| 152 | */ | ||
| 153 | @Schema(description = "需求单位") | ||
| 154 | private String requirementUnit; | ||
| 155 | |||
| 156 | /** | ||
| 157 | * 联系方式 | ||
| 158 | */ | ||
| 159 | @Schema(description = "联系方式") | ||
| 160 | private String contactInformation; | ||
| 161 | |||
| 162 | /** | ||
| 163 | * 业务审批状态【N 草稿中,A 审批中,Y 已通过,R 驳回,C 已撤销,D 已废弃; 默认 N】 | ||
| 164 | */ | ||
| 165 | @Schema(description = "业务审批状态【N 草稿中,A 审批中,Y 已通过,R 驳回,C 已撤销,D 已废弃; 默认 N】") | ||
| 166 | private String bizApproveState; | ||
| 167 | |||
| 168 | /** | ||
| 169 | * 加工单生成时间 | ||
| 170 | */ | ||
| 171 | @Schema(description = "加工单生成时间") | ||
| 172 | @JsonFormat(pattern = "yyyy-MM-dd", timezone = "GMT+8") | ||
| 173 | private Date processingGenerateTime; | ||
| 174 | |||
| 175 | /** | ||
| 176 | * 验收完成时间 | ||
| 177 | */ | ||
| 178 | @Schema(description = "验收完成时间") | ||
| 179 | @JsonFormat(pattern = "yyyy-MM-dd", timezone = "GMT+8") | ||
| 180 | private Date acceptFinishTime; | ||
| 181 | |||
| 182 | /** | ||
| 183 | * 完成周期 | ||
| 184 | */ | ||
| 185 | @Schema(description = "完成周期") | ||
| 186 | private Integer finishCycle; | ||
| 187 | |||
| 188 | /** | ||
| 189 | * 资源获取状态【N未开始 A进行中 Y已完成】 | ||
| 190 | */ | ||
| 191 | @Schema(description = "资源获取状态【N未开始 A进行中 Y已完成】") | ||
| 192 | private String resourceAcquisitionState; | ||
| 193 | |||
| 194 | /** | ||
| 195 | * 产品加工状态【N未开始 A进行中 Y已完成】 | ||
| 196 | */ | ||
| 197 | @Schema(description = "产品加工状态【N未开始 A进行中 Y已完成】") | ||
| 198 | private String productProcessingState; | ||
| 199 | |||
| 200 | /** | ||
| 201 | * 产品交付状态【N未开始 A进行中 Y已完成】 | ||
| 202 | */ | ||
| 203 | @Schema(description = "产品交付状态【N未开始 A进行中 Y已完成】") | ||
| 204 | private String productDeliveryState; | ||
| 205 | |||
| 206 | /** | ||
| 207 | * 产品验收状态【N未开始 A进行中 Y已完成】 | ||
| 208 | */ | ||
| 209 | @Schema(description = "产品验收状态【N未开始 A进行中 Y已完成】") | ||
| 210 | private String productAcceptState; | ||
| 211 | |||
| 212 | @Schema(description = "合同附件") | ||
| 213 | private String contractAttachJson; | ||
| 214 | |||
| 215 | @Schema(description = "加工单位类型") | ||
| 216 | private String processCompanyType; | ||
| 217 | |||
| 218 | @Schema(description = "加工单位唯一标识") | ||
| 219 | private String processCompanyGuid; | ||
| 220 | |||
| 221 | @Schema(description = "加工单位名称") | ||
| 222 | private String processCompanyName; | ||
| 223 | |||
| 224 | @Schema(description = "发起人") | ||
| 225 | private String createUserName; | ||
| 226 | |||
| 227 | @Schema(description = "提交时间") | ||
| 228 | private Date createTime; | ||
| 229 | |||
| 230 | @Schema(description = "需求单编号") | ||
| 231 | private String requirementOrderNo; | ||
| 232 | |||
| 233 | @Schema(description = "加工单编号") | ||
| 234 | private String processOrderNo; | ||
| 235 | |||
| 236 | @Schema(title = "专区名称") | ||
| 237 | private String zqName; | ||
| 238 | |||
| 239 | @Schema(description ="业务名称") | ||
| 240 | private String bizName; | ||
| 241 | |||
| 242 | /** | ||
| 243 | * 跨平台审批状态(N 初始 A 审批中 Y 已通过 R 驳回 C 已撤销) | ||
| 244 | */ | ||
| 245 | @Schema(title = "跨平台审批状态(N 初始 A 审批中 Y 已通过 R 驳回 C 已撤销)") | ||
| 246 | private String crossPlatformApproveState; | ||
| 247 | |||
| 248 | @Schema(title = "上架状态(Y 上架 N 下架)") | ||
| 249 | private String listingStatus; | ||
| 250 | |||
| 251 | /******** 库表存储属性 需处理 *****/ | ||
| 252 | |||
| 253 | /******** 自定义扩展 *****/ | ||
| 254 | |||
| 255 | /** | ||
| 256 | * 审批信息 | ||
| 257 | */ | ||
| 258 | @Schema(description = "审批信息") | ||
| 259 | private BizApproveVO approveVO; | ||
| 260 | |||
| 261 | /******** 子对象 *****/ | ||
| 262 | |||
| 263 | } |
| 1 | package com.csbr.qingcloud.portal.domain.vo; | ||
| 2 | |||
| 3 | import com.fasterxml.jackson.annotation.JsonFormat; | ||
| 4 | import io.swagger.v3.oas.annotations.media.Schema; | ||
| 5 | import lombok.Data; | ||
| 6 | |||
| 7 | import java.util.Date; | ||
| 8 | import java.util.List; | ||
| 9 | |||
| 10 | /** | ||
| 11 | * @program: D:/git/ms-data-circulation-portal-service | ||
| 12 | * @description: 数据需求状态修改参数 | ||
| 13 | * @author: xcq | ||
| 14 | * @create: 2025-02-10 | ||
| 15 | **/ | ||
| 16 | @Data | ||
| 17 | @Schema(title = "数据需求状态修改参数") | ||
| 18 | public class DemandUpdateStateVO { | ||
| 19 | |||
| 20 | @Schema(description = "加工单位唯一标识列表") | ||
| 21 | private List<String> processCompanyGuidList; | ||
| 22 | |||
| 23 | @Schema(description = "加工单位唯一标识") | ||
| 24 | private String processOrderGuid; | ||
| 25 | |||
| 26 | @Schema(description = "资源获取状态【N未开始 A进行中 Y已完成】") | ||
| 27 | private String resourceAcquisitionState; | ||
| 28 | |||
| 29 | @Schema(description = "产品加工状态【N未开始 A进行中 Y已完成】") | ||
| 30 | private String productProcessingState; | ||
| 31 | |||
| 32 | @Schema(description = "产品交付状态【N未开始 A进行中 Y已完成】") | ||
| 33 | private String productDeliveryState; | ||
| 34 | |||
| 35 | @Schema(description = "产品验收状态【N未开始 A进行中 Y已完成】") | ||
| 36 | private String productAcceptState; | ||
| 37 | |||
| 38 | @Schema(description ="产品验收验收完成时间") | ||
| 39 | @JsonFormat(pattern = "yyyy-MM-dd", timezone = "GMT+8") | ||
| 40 | private Date acceptFinishTime; | ||
| 41 | |||
| 42 | @Schema(description ="业务名称") | ||
| 43 | private String bizName; | ||
| 44 | |||
| 45 | } |
| 1 | package com.csbr.qingcloud.portal.domain.vo; | ||
| 2 | |||
| 3 | import com.csbr.cloud.workflow.domain.vo.appove.ApproveVO; | ||
| 4 | import com.csbr.cloud.workflow.domain.vo.appove.BizApproveVO; | ||
| 5 | import com.fasterxml.jackson.annotation.JsonFormat; | ||
| 6 | import io.swagger.v3.oas.annotations.media.Schema; | ||
| 7 | import lombok.Data; | ||
| 8 | |||
| 9 | import java.math.BigDecimal; | ||
| 10 | import java.util.Date; | ||
| 11 | import java.util.List; | ||
| 12 | |||
| 13 | /** | ||
| 14 | * @program: D:/git/ms-data-circulation-portal-service | ||
| 15 | * @description: 企业信息返回参数 | ||
| 16 | * @author: xcq | ||
| 17 | * @create: 2024-12-26 16:18 | ||
| 18 | **/ | ||
| 19 | @Data | ||
| 20 | @Schema(title = "企业信息返回参数") | ||
| 21 | public class EnterpriseApproveRSVO extends ApproveVO { | ||
| 22 | |||
| 23 | @Schema(description = "跨平台审批状态(N 初始 A 审批中 Y 已通过 R 驳回 C 已撤销)") | ||
| 24 | private String crossPlatformApproveState; | ||
| 25 | |||
| 26 | @Schema(description = "专区名称") | ||
| 27 | private String zqName; | ||
| 28 | |||
| 29 | /******** 子对象 *****/ | ||
| 30 | |||
| 31 | } |
| 1 | package com.csbr.qingcloud.portal.domain.vo; | ||
| 2 | |||
| 3 | import com.csbr.cloud.mybatis.annotations.LikeQuery; | ||
| 4 | import com.csbr.cloud.mybatis.enums.LikeQueryEnum; | ||
| 5 | import com.csbr.cloud.workflow.domain.dto.appove.FlowBizGuidQueryDTO; | ||
| 6 | import io.swagger.v3.oas.annotations.media.Schema; | ||
| 7 | import lombok.EqualsAndHashCode; | ||
| 8 | import lombok.Data; | ||
| 9 | import java.math.BigDecimal; | ||
| 10 | import java.util.Date; | ||
| 11 | import java.util.List; | ||
| 12 | |||
| 13 | /** | ||
| 14 | * @program: D:/git/ms-data-circulation-portal-service | ||
| 15 | * @description: 企业信息查询参数 | ||
| 16 | * @author: xcq | ||
| 17 | * @create: 2024-12-26 16:18 | ||
| 18 | **/ | ||
| 19 | @EqualsAndHashCode(callSuper = true) | ||
| 20 | @Data | ||
| 21 | @Schema(title = "企业信息查询参数") | ||
| 22 | public class EnterpriseQueryVO extends FlowBizGuidQueryDTO { | ||
| 23 | |||
| 24 | @Schema(description = "企业名称") | ||
| 25 | @LikeQuery(type = LikeQueryEnum.ALL) | ||
| 26 | private String tenantName; | ||
| 27 | |||
| 28 | @Schema(description = "企业类型【选择平台字典【公司类型】的选项】") | ||
| 29 | private String tenantType; | ||
| 30 | |||
| 31 | /** | ||
| 32 | * 业务审批状态【N 草稿中,A 审批中,Y 已通过,R 驳回,C 已撤销,D 已废弃】 | ||
| 33 | */ | ||
| 34 | @Schema(description = "业务审批状态【N 草稿中,A 审批中,Y 已通过,R 驳回,C 已撤销,D 已废弃;B 变更中;】") | ||
| 35 | private String bizApproveState; | ||
| 36 | |||
| 37 | @Schema(description = "排除业务审批状态【N 草稿中,A 审批中,Y 已通过,R 驳回,C 已撤销,D 已废弃;B 变更中;】") | ||
| 38 | private List<String> bizApproveStateNotList; | ||
| 39 | |||
| 40 | @Schema(description = "创建人姓名") | ||
| 41 | private String createUserName; | ||
| 42 | |||
| 43 | @Schema(description = "登录账号") | ||
| 44 | private String logonUser; | ||
| 45 | |||
| 46 | /******** 自定义扩展 *****/ | ||
| 47 | |||
| 48 | /** | ||
| 49 | * 数据唯一标识【List集合】 | ||
| 50 | */ | ||
| 51 | @Schema(description = "数据唯一标识", hidden = true) | ||
| 52 | private List<String> guidList; | ||
| 53 | |||
| 54 | /** | ||
| 55 | * 是否调用查询的判断 | ||
| 56 | */ | ||
| 57 | @Schema(description = "是否调用查询的判断", hidden = true) | ||
| 58 | private Boolean isNeedQuery; | ||
| 59 | |||
| 60 | } |
| 1 | package com.csbr.qingcloud.portal.domain.vo; | ||
| 2 | |||
| 3 | import com.csbr.cloud.workflow.domain.vo.appove.FlowRQBaseVO; | ||
| 4 | import io.swagger.v3.oas.annotations.media.Schema; | ||
| 5 | import com.fasterxml.jackson.annotation.JsonFormat; | ||
| 6 | import lombok.Data; | ||
| 7 | import java.math.BigDecimal; | ||
| 8 | import java.util.Date; | ||
| 9 | |||
| 10 | /** | ||
| 11 | * @program: D:/git/ms-data-circulation-portal-service | ||
| 12 | * @description: 企业信息新增、修改参数 | ||
| 13 | * @author: xcq | ||
| 14 | * @create: 2024-12-26 16:18 | ||
| 15 | **/ | ||
| 16 | @Data | ||
| 17 | @Schema(title = "企业信息新增、修改参数") | ||
| 18 | public class EnterpriseRQVO extends FlowRQBaseVO { | ||
| 19 | |||
| 20 | @Schema(description = "会员GUID") | ||
| 21 | private String tenantGuid; | ||
| 22 | /** | ||
| 23 | * 公司名称 | ||
| 24 | */ | ||
| 25 | @Schema(description = "公司名称") | ||
| 26 | private String tenantName; | ||
| 27 | |||
| 28 | @Schema(title = "专区名称") | ||
| 29 | private String zqName; | ||
| 30 | |||
| 31 | /** | ||
| 32 | * 统一社会信用代码 | ||
| 33 | */ | ||
| 34 | @Schema(description = "统一社会信用代码") | ||
| 35 | private String socialCreditCode; | ||
| 36 | |||
| 37 | /** | ||
| 38 | * 企业类型【选择平台字典【公司类型】的选项】 | ||
| 39 | */ | ||
| 40 | @Schema(description = "企业类型【选择平台字典【公司类型】的选项】") | ||
| 41 | private String tenantType; | ||
| 42 | |||
| 43 | /** | ||
| 44 | * 注册日期 | ||
| 45 | */ | ||
| 46 | @Schema(description = "注册日期") | ||
| 47 | @JsonFormat(pattern = "yyyy-MM-dd", timezone = "GMT+8") | ||
| 48 | private Date registrationDate; | ||
| 49 | |||
| 50 | /** | ||
| 51 | * 注册资本【(万元)】 | ||
| 52 | */ | ||
| 53 | @Schema(description = "注册资本【(万元)】") | ||
| 54 | private BigDecimal registeredCapital; | ||
| 55 | |||
| 56 | /** | ||
| 57 | * 税号 | ||
| 58 | */ | ||
| 59 | @Schema(description = "税号") | ||
| 60 | private String bankTaxNo; | ||
| 61 | |||
| 62 | /** | ||
| 63 | * 省 | ||
| 64 | */ | ||
| 65 | @Schema(description = "省") | ||
| 66 | private String province; | ||
| 67 | |||
| 68 | /** | ||
| 69 | * 市 | ||
| 70 | */ | ||
| 71 | @Schema(description = "市") | ||
| 72 | private String city; | ||
| 73 | |||
| 74 | /** | ||
| 75 | * 区 | ||
| 76 | */ | ||
| 77 | @Schema(description = "区") | ||
| 78 | private String district; | ||
| 79 | |||
| 80 | /** | ||
| 81 | * 营业期限【1 长期有效;2 自定义】 | ||
| 82 | */ | ||
| 83 | @Schema(description = "营业期限【1 长期有效;2 自定义】") | ||
| 84 | private String businessLicenseTerm; | ||
| 85 | |||
| 86 | /** | ||
| 87 | * 营业开始日期 | ||
| 88 | */ | ||
| 89 | @Schema(description = "营业开始日期") | ||
| 90 | @JsonFormat(pattern = "yyyy-MM-dd", timezone = "GMT+8") | ||
| 91 | private Date businessLicenseStartDate; | ||
| 92 | |||
| 93 | /** | ||
| 94 | * 营业结束日期 | ||
| 95 | */ | ||
| 96 | @Schema(description = "营业结束日期") | ||
| 97 | @JsonFormat(pattern = "yyyy-MM-dd", timezone = "GMT+8") | ||
| 98 | private Date businessLicenseEndDate; | ||
| 99 | |||
| 100 | /** | ||
| 101 | * 营业执照 | ||
| 102 | */ | ||
| 103 | @Schema(description = "营业执照") | ||
| 104 | private String businessLicenseJson; | ||
| 105 | |||
| 106 | /** | ||
| 107 | * 营业执照经营范围 | ||
| 108 | */ | ||
| 109 | @Schema(description = "营业执照经营范围") | ||
| 110 | private String businessLicenseScope; | ||
| 111 | |||
| 112 | /** | ||
| 113 | * 公司法人 | ||
| 114 | */ | ||
| 115 | @Schema(description = "公司法人") | ||
| 116 | private String juridicalPerson; | ||
| 117 | |||
| 118 | /** | ||
| 119 | * 法人证件类型 | ||
| 120 | */ | ||
| 121 | @Schema(description = "法人证件类型") | ||
| 122 | private String juridicalPersonIdType; | ||
| 123 | |||
| 124 | /** | ||
| 125 | * 法人证件号 | ||
| 126 | */ | ||
| 127 | @Schema(description = "法人证件号") | ||
| 128 | private String juridicalPersonId; | ||
| 129 | |||
| 130 | /** | ||
| 131 | * 法人证件照 | ||
| 132 | */ | ||
| 133 | @Schema(description = "法人证件照") | ||
| 134 | private String juridicalPersonIdPhotoJson; | ||
| 135 | |||
| 136 | /** | ||
| 137 | * 登录账号 | ||
| 138 | */ | ||
| 139 | @Schema(description = "登录账号") | ||
| 140 | private String logonUser; | ||
| 141 | |||
| 142 | /** | ||
| 143 | * 联系人 | ||
| 144 | */ | ||
| 145 | @Schema(description = "联系人") | ||
| 146 | private String contacts; | ||
| 147 | |||
| 148 | /** | ||
| 149 | * 联系人电话 | ||
| 150 | */ | ||
| 151 | @Schema(description = "联系人电话") | ||
| 152 | private String contactTel; | ||
| 153 | |||
| 154 | /** | ||
| 155 | * 管理员证件号 | ||
| 156 | */ | ||
| 157 | @Schema(description = "管理员证件号") | ||
| 158 | private String managerPersonId; | ||
| 159 | |||
| 160 | /** | ||
| 161 | * 管理员证件照 | ||
| 162 | */ | ||
| 163 | @Schema(description = "管理员证件照") | ||
| 164 | private String managerPersonIdPhotoJson; | ||
| 165 | |||
| 166 | /** | ||
| 167 | * 授权委托书 | ||
| 168 | */ | ||
| 169 | @Schema(description = "授权委托书") | ||
| 170 | private String authorizationLetter; | ||
| 171 | |||
| 172 | /** | ||
| 173 | * 业务审批状态【N 草稿中,A 审批中,Y 已通过,R 驳回,C 已撤销,D 已废弃; 默认 N】 | ||
| 174 | */ | ||
| 175 | @Schema(description = "业务审批状态【N 草稿中,A 审批中,Y 已通过,R 驳回,C 已撤销,D 已废弃;B 变更中; 默认 N】") | ||
| 176 | private String bizApproveState; | ||
| 177 | |||
| 178 | /******** 库表存储属性 需处理 *****/ | ||
| 179 | |||
| 180 | /******** 自定义扩展 *****/ | ||
| 181 | |||
| 182 | /******** 子对象 *****/ | ||
| 183 | |||
| 184 | } |
| 1 | package com.csbr.qingcloud.portal.domain.vo; | ||
| 2 | |||
| 3 | import io.swagger.v3.oas.annotations.media.Schema; | ||
| 4 | import com.fasterxml.jackson.annotation.JsonFormat; | ||
| 5 | import lombok.Data; | ||
| 6 | import com.csbr.cloud.workflow.domain.vo.appove.BizApproveVO; | ||
| 7 | import java.math.BigDecimal; | ||
| 8 | import java.util.Date; | ||
| 9 | import java.util.List; | ||
| 10 | |||
| 11 | /** | ||
| 12 | * @program: D:/git/ms-data-circulation-portal-service | ||
| 13 | * @description: 企业信息返回参数 | ||
| 14 | * @author: xcq | ||
| 15 | * @create: 2024-12-26 16:18 | ||
| 16 | **/ | ||
| 17 | @Data | ||
| 18 | @Schema(title = "企业信息返回参数") | ||
| 19 | public class EnterpriseRSVO { | ||
| 20 | |||
| 21 | /** | ||
| 22 | * 系统唯一标识 | ||
| 23 | */ | ||
| 24 | @Schema(description = "系统唯一标识") | ||
| 25 | private String guid; | ||
| 26 | |||
| 27 | @Schema(description = "会员GUID") | ||
| 28 | private String tenantGuid; | ||
| 29 | |||
| 30 | /** | ||
| 31 | * 公司名称 | ||
| 32 | */ | ||
| 33 | @Schema(description = "公司名称") | ||
| 34 | private String tenantName; | ||
| 35 | |||
| 36 | /** | ||
| 37 | * 统一社会信用代码 | ||
| 38 | */ | ||
| 39 | @Schema(description = "统一社会信用代码") | ||
| 40 | private String socialCreditCode; | ||
| 41 | |||
| 42 | /** | ||
| 43 | * 企业类型【选择平台字典【公司类型】的选项】 | ||
| 44 | */ | ||
| 45 | @Schema(description = "企业类型【选择平台字典【公司类型】的选项】") | ||
| 46 | private String tenantType; | ||
| 47 | |||
| 48 | /** | ||
| 49 | * 注册日期 | ||
| 50 | */ | ||
| 51 | @Schema(description = "注册日期") | ||
| 52 | @JsonFormat(pattern = "yyyy-MM-dd", timezone = "GMT+8") | ||
| 53 | private Date registrationDate; | ||
| 54 | |||
| 55 | /** | ||
| 56 | * 注册资本【(万元)】 | ||
| 57 | */ | ||
| 58 | @Schema(description = "注册资本【(万元)】") | ||
| 59 | private BigDecimal registeredCapital; | ||
| 60 | |||
| 61 | /** | ||
| 62 | * 税号 | ||
| 63 | */ | ||
| 64 | @Schema(description = "税号") | ||
| 65 | private String bankTaxNo; | ||
| 66 | |||
| 67 | /** | ||
| 68 | * 省 | ||
| 69 | */ | ||
| 70 | @Schema(description = "省") | ||
| 71 | private String province; | ||
| 72 | |||
| 73 | /** | ||
| 74 | * 市 | ||
| 75 | */ | ||
| 76 | @Schema(description = "市") | ||
| 77 | private String city; | ||
| 78 | |||
| 79 | /** | ||
| 80 | * 区 | ||
| 81 | */ | ||
| 82 | @Schema(description = "区") | ||
| 83 | private String district; | ||
| 84 | |||
| 85 | @Schema(description = "注册地") | ||
| 86 | private String venue; | ||
| 87 | |||
| 88 | /** | ||
| 89 | * 营业期限【1 长期有效;2 自定义】 | ||
| 90 | */ | ||
| 91 | @Schema(description = "营业期限【1 长期有效;2 自定义】") | ||
| 92 | private String businessLicenseTerm; | ||
| 93 | |||
| 94 | /** | ||
| 95 | * 营业开始日期 | ||
| 96 | */ | ||
| 97 | @Schema(description = "营业开始日期") | ||
| 98 | @JsonFormat(pattern = "yyyy-MM-dd", timezone = "GMT+8") | ||
| 99 | private Date businessLicenseStartDate; | ||
| 100 | |||
| 101 | /** | ||
| 102 | * 营业结束日期 | ||
| 103 | */ | ||
| 104 | @Schema(description = "营业结束日期") | ||
| 105 | @JsonFormat(pattern = "yyyy-MM-dd", timezone = "GMT+8") | ||
| 106 | private Date businessLicenseEndDate; | ||
| 107 | |||
| 108 | @Schema(description = "营业日期范围") | ||
| 109 | private String businessLicenseStartEnd; | ||
| 110 | |||
| 111 | /** | ||
| 112 | * 营业执照 | ||
| 113 | */ | ||
| 114 | @Schema(description = "营业执照") | ||
| 115 | private String businessLicenseJson; | ||
| 116 | |||
| 117 | /** | ||
| 118 | * 营业执照经营范围 | ||
| 119 | */ | ||
| 120 | @Schema(description = "营业执照经营范围") | ||
| 121 | private String businessLicenseScope; | ||
| 122 | |||
| 123 | /** | ||
| 124 | * 公司法人 | ||
| 125 | */ | ||
| 126 | @Schema(description = "公司法人") | ||
| 127 | private String juridicalPerson; | ||
| 128 | |||
| 129 | /** | ||
| 130 | * 法人证件类型 | ||
| 131 | */ | ||
| 132 | @Schema(description = "法人证件类型") | ||
| 133 | private String juridicalPersonIdType; | ||
| 134 | |||
| 135 | /** | ||
| 136 | * 法人证件号 | ||
| 137 | */ | ||
| 138 | @Schema(description = "法人证件号") | ||
| 139 | private String juridicalPersonId; | ||
| 140 | |||
| 141 | /** | ||
| 142 | * 法人证件照 | ||
| 143 | */ | ||
| 144 | @Schema(description = "法人证件照") | ||
| 145 | private String juridicalPersonIdPhotoJson; | ||
| 146 | |||
| 147 | /** | ||
| 148 | * 登录账号 | ||
| 149 | */ | ||
| 150 | @Schema(description = "登录账号") | ||
| 151 | private String logonUser; | ||
| 152 | |||
| 153 | /** | ||
| 154 | * 联系人 | ||
| 155 | */ | ||
| 156 | @Schema(description = "联系人") | ||
| 157 | private String contacts; | ||
| 158 | |||
| 159 | /** | ||
| 160 | * 联系人电话 | ||
| 161 | */ | ||
| 162 | @Schema(description = "联系人电话") | ||
| 163 | private String contactTel; | ||
| 164 | |||
| 165 | /** | ||
| 166 | * 管理员证件号 | ||
| 167 | */ | ||
| 168 | @Schema(description = "管理员证件号") | ||
| 169 | private String managerPersonId; | ||
| 170 | |||
| 171 | /** | ||
| 172 | * 管理员证件照 | ||
| 173 | */ | ||
| 174 | @Schema(description = "管理员证件照") | ||
| 175 | private String managerPersonIdPhotoJson; | ||
| 176 | |||
| 177 | /** | ||
| 178 | * 授权委托书 | ||
| 179 | */ | ||
| 180 | @Schema(description = "授权委托书") | ||
| 181 | private String authorizationLetter; | ||
| 182 | |||
| 183 | /** | ||
| 184 | * 业务审批状态【N 草稿中,A 审批中,Y 已通过,R 驳回,C 已撤销,D 已废弃; 默认 N】 | ||
| 185 | */ | ||
| 186 | @Schema(description = "业务审批状态【N 草稿中,A 审批中,Y 已通过,R 驳回,C 已撤销,D 已废弃;B 变更中; 默认 N】") | ||
| 187 | private String bizApproveState; | ||
| 188 | |||
| 189 | @Schema(description = "提交时间") | ||
| 190 | private Date createTime; | ||
| 191 | |||
| 192 | @Schema(title = "专区名称") | ||
| 193 | private String zqName; | ||
| 194 | |||
| 195 | /** | ||
| 196 | * 跨平台审批状态(N 初始 A 审批中 Y 已通过 R 驳回 C 已撤销) | ||
| 197 | */ | ||
| 198 | @Schema(title = "跨平台审批状态(N 初始 A 审批中 Y 已通过 R 驳回 C 已撤销)") | ||
| 199 | private String crossPlatformApproveState; | ||
| 200 | |||
| 201 | /******** 库表存储属性 需处理 *****/ | ||
| 202 | |||
| 203 | /******** 自定义扩展 *****/ | ||
| 204 | |||
| 205 | /** | ||
| 206 | * 审批信息 | ||
| 207 | */ | ||
| 208 | @Schema(description = "审批信息") | ||
| 209 | private BizApproveVO approveVO; | ||
| 210 | |||
| 211 | @Schema(description = "变更信息列表") | ||
| 212 | private List<ChangeInfoVO> changeList; | ||
| 213 | |||
| 214 | @Schema(description = "变更前信息列表") | ||
| 215 | private List<ChangeInfoVO> beforeChangeList; | ||
| 216 | |||
| 217 | /******** 子对象 *****/ | ||
| 218 | |||
| 219 | } |
| 1 | package com.csbr.qingcloud.portal.domain.vo; | ||
| 2 | |||
| 3 | import com.csbr.cloud.workflow.domain.dto.appove.FlowUpdateStateDTO; | ||
| 4 | import io.swagger.v3.oas.annotations.media.Schema; | ||
| 5 | import lombok.Data; | ||
| 6 | import org.springframework.util.MultiValueMap; | ||
| 7 | |||
| 8 | /** | ||
| 9 | * @description: 审批变更检查实体 | ||
| 10 | * @author: XiaoCQ | ||
| 11 | * @create: 2025-02-20 | ||
| 12 | */ | ||
| 13 | @Data | ||
| 14 | @Schema(name = "审批变更检查实体") | ||
| 15 | public class KafkaApproveDTO { | ||
| 16 | |||
| 17 | @Schema(description = "审批流参数") | ||
| 18 | private FlowUpdateStateDTO updateStateDTO; | ||
| 19 | |||
| 20 | @Schema(description = "请求头") | ||
| 21 | private MultiValueMap<String, String> header; | ||
| 22 | |||
| 23 | } |
| 1 | package com.csbr.qingcloud.portal.domain.vo; | ||
| 2 | |||
| 3 | import com.fasterxml.jackson.annotation.JsonFormat; | ||
| 4 | import io.swagger.v3.oas.annotations.media.Schema; | ||
| 5 | import lombok.Data; | ||
| 6 | |||
| 7 | import java.util.Date; | ||
| 8 | |||
| 9 | /** | ||
| 10 | * @program: | ||
| 11 | * @description: 加工单加工明细返回参数 | ||
| 12 | * @author: xup | ||
| 13 | * @create: 2025-02-10 17:57 | ||
| 14 | **/ | ||
| 15 | @Data | ||
| 16 | @Schema(title = "加工单加工明细返回参数") | ||
| 17 | public class ProcessOrderProcessDtlRSVO { | ||
| 18 | |||
| 19 | /** | ||
| 20 | * 系统唯一标识 | ||
| 21 | */ | ||
| 22 | @Schema(description = "系统唯一标识") | ||
| 23 | private String guid; | ||
| 24 | |||
| 25 | /** | ||
| 26 | * 会员Guid | ||
| 27 | */ | ||
| 28 | @Schema(description = "会员Guid") | ||
| 29 | private String tenantGuid; | ||
| 30 | |||
| 31 | /** | ||
| 32 | * 加工单Guid | ||
| 33 | */ | ||
| 34 | @Schema(description = "加工单Guid") | ||
| 35 | private String processOrderGuid; | ||
| 36 | |||
| 37 | /** | ||
| 38 | * 加工单号 | ||
| 39 | */ | ||
| 40 | @Schema(description = "加工单号") | ||
| 41 | private String processOrderNo; | ||
| 42 | |||
| 43 | /** | ||
| 44 | * 加工单名称 | ||
| 45 | */ | ||
| 46 | @Schema(description = "加工单名称") | ||
| 47 | private String processOrderName; | ||
| 48 | |||
| 49 | /** | ||
| 50 | * 加工方式(1 数据服务;2 需求申请) | ||
| 51 | */ | ||
| 52 | @Schema(description = "加工方式(1 数据服务;2 需求申请)") | ||
| 53 | private Integer processType; | ||
| 54 | |||
| 55 | /** | ||
| 56 | * 业务Guid | ||
| 57 | */ | ||
| 58 | @Schema(description = "业务Guid") | ||
| 59 | private String bizGuid; | ||
| 60 | |||
| 61 | /** | ||
| 62 | * 业务名称 | ||
| 63 | */ | ||
| 64 | @Schema(description = "业务名称") | ||
| 65 | private String bizName; | ||
| 66 | |||
| 67 | /** | ||
| 68 | * 加工状态(N 未开始;A 进行中;Y 已完成) | ||
| 69 | */ | ||
| 70 | @Schema(description = "加工状态(N 未开始;A 进行中;Y 已完成)") | ||
| 71 | private String processState; | ||
| 72 | |||
| 73 | /** | ||
| 74 | * 加工时间 | ||
| 75 | */ | ||
| 76 | @Schema(description = "加工时间") | ||
| 77 | @JsonFormat(pattern = "yyyy-MM-dd HH:mm:ss", timezone = "GMT+8") | ||
| 78 | private Date processTime; | ||
| 79 | |||
| 80 | /** | ||
| 81 | * 交付时间 | ||
| 82 | */ | ||
| 83 | @Schema(description = "交付时间") | ||
| 84 | @JsonFormat(pattern = "yyyy-MM-dd HH:mm:ss", timezone = "GMT+8") | ||
| 85 | private Date deliverTime; | ||
| 86 | |||
| 87 | /******** 库表存储属性 需处理 *****/ | ||
| 88 | |||
| 89 | /******** 自定义扩展 *****/ | ||
| 90 | |||
| 91 | /******** 子对象 *****/ | ||
| 92 | |||
| 93 | } |
| 1 | package com.csbr.qingcloud.portal.domain.vo; | ||
| 2 | |||
| 3 | import com.fasterxml.jackson.annotation.JsonFormat; | ||
| 4 | import io.swagger.v3.oas.annotations.media.Schema; | ||
| 5 | import lombok.Data; | ||
| 6 | |||
| 7 | import java.util.Date; | ||
| 8 | |||
| 9 | /** | ||
| 10 | * @program: | ||
| 11 | * @description: 加工单管理新增、修改参数 | ||
| 12 | * @author: makejava | ||
| 13 | * @create: 2024-12-06 15:41 | ||
| 14 | **/ | ||
| 15 | @Data | ||
| 16 | @Schema(title = "加工单管理新增、修改参数") | ||
| 17 | public class ProcessOrderRQVO { | ||
| 18 | |||
| 19 | /** | ||
| 20 | * 系统唯一标识 | ||
| 21 | */ | ||
| 22 | @Schema(description = "系统唯一标识") | ||
| 23 | private String guid; | ||
| 24 | |||
| 25 | /** | ||
| 26 | * 企业唯一标识 | ||
| 27 | */ | ||
| 28 | @Schema(description = "企业唯一标识") | ||
| 29 | private String tenantGuid; | ||
| 30 | |||
| 31 | @Schema(description = "加工单位唯一标识") | ||
| 32 | private String processCompanyGuid; | ||
| 33 | |||
| 34 | @Schema(description = "加工人员唯一标识") | ||
| 35 | private String processStaffGuid; | ||
| 36 | |||
| 37 | /** | ||
| 38 | * 公司名称 | ||
| 39 | */ | ||
| 40 | @Schema(description = "公司名称") | ||
| 41 | private String tenantName; | ||
| 42 | |||
| 43 | /** | ||
| 44 | * 加工单编号 | ||
| 45 | */ | ||
| 46 | @Schema(description = "加工单编号") | ||
| 47 | private String processOrderNo; | ||
| 48 | |||
| 49 | /** | ||
| 50 | * 受理单编号 | ||
| 51 | */ | ||
| 52 | @Schema(description = "受理单编号") | ||
| 53 | private String acceptanceOrderNo; | ||
| 54 | |||
| 55 | /** | ||
| 56 | * 需求单编号 | ||
| 57 | */ | ||
| 58 | @Schema(description = "需求单编号") | ||
| 59 | private String requirementOrderNo; | ||
| 60 | |||
| 61 | /** | ||
| 62 | * 需求单名称 | ||
| 63 | */ | ||
| 64 | @Schema(description = "需求单名称") | ||
| 65 | private String requirementOrderName; | ||
| 66 | |||
| 67 | /** | ||
| 68 | * 需求单位 | ||
| 69 | */ | ||
| 70 | @Schema(description = "需求单位") | ||
| 71 | private String requirementUnit; | ||
| 72 | |||
| 73 | /** | ||
| 74 | * 需求开始时间 | ||
| 75 | */ | ||
| 76 | @Schema(description = "需求开始时间") | ||
| 77 | @JsonFormat(pattern = "yyyy-MM-dd", timezone = "GMT+8") | ||
| 78 | private Date requirementTermSdate; | ||
| 79 | |||
| 80 | /** | ||
| 81 | * 需求结束时间 | ||
| 82 | */ | ||
| 83 | @Schema(description = "需求结束时间") | ||
| 84 | @JsonFormat(pattern = "yyyy-MM-dd", timezone = "GMT+8") | ||
| 85 | private Date requirementTermEdate; | ||
| 86 | |||
| 87 | /** | ||
| 88 | * 更新周期【取数据字典:周期,1 年度,2 半年度,3 季度,4 月度】 | ||
| 89 | */ | ||
| 90 | @Schema(description = "更新周期【取数据字典:周期,1 年度,2 半年度,3 季度,4 月度】") | ||
| 91 | private String updateCycle; | ||
| 92 | |||
| 93 | /** | ||
| 94 | * 获取路径【API路径】 | ||
| 95 | */ | ||
| 96 | @Schema(description = "获取路径【API路径】") | ||
| 97 | private String requestPath; | ||
| 98 | |||
| 99 | /** | ||
| 100 | * 需求内容 | ||
| 101 | */ | ||
| 102 | @Schema(description = "需求内容") | ||
| 103 | private String requirementContent; | ||
| 104 | |||
| 105 | /** | ||
| 106 | * 需求附件【数据格式:[{"name":"","path":""},{"name":"","path":""}]】 | ||
| 107 | */ | ||
| 108 | @Schema(description = "需求附件【数据格式:[{\"name\":\"\",\"path\":\"\"},{\"name\":\"\",\"path\":\"\"}]】") | ||
| 109 | private String fileUrl; | ||
| 110 | |||
| 111 | /** | ||
| 112 | * 应用场景说明 | ||
| 113 | */ | ||
| 114 | @Schema(description = "应用场景说明") | ||
| 115 | private String applicationSceneDesc; | ||
| 116 | |||
| 117 | /** | ||
| 118 | * 受理原因 | ||
| 119 | */ | ||
| 120 | @Schema(description = "受理原因") | ||
| 121 | private String acceptanceReason; | ||
| 122 | |||
| 123 | /** | ||
| 124 | * 加工状态(N 未分派;A 处理中;J 已交付;Y 已验收) | ||
| 125 | */ | ||
| 126 | @Schema(description = "加工状态(N 未分派;A 处理中;J 已交付;Y 已验收)") | ||
| 127 | private String processState; | ||
| 128 | |||
| 129 | /** | ||
| 130 | * 联系人 | ||
| 131 | */ | ||
| 132 | @Schema(description = "联系人") | ||
| 133 | private String contacts; | ||
| 134 | |||
| 135 | /** | ||
| 136 | * 联系人电话 | ||
| 137 | */ | ||
| 138 | @Schema(description = "联系人电话") | ||
| 139 | private String contactTel; | ||
| 140 | |||
| 141 | /** | ||
| 142 | * 受理日期 | ||
| 143 | */ | ||
| 144 | @Schema(description = "受理日期") | ||
| 145 | @JsonFormat(pattern = "yyyy-MM-dd", timezone = "GMT+8") | ||
| 146 | private Date acceptanceDate; | ||
| 147 | |||
| 148 | /** | ||
| 149 | * 接收人 | ||
| 150 | */ | ||
| 151 | @Schema(description = "接收人") | ||
| 152 | private String acceptanceName; | ||
| 153 | |||
| 154 | /** | ||
| 155 | * 接收人唯一标识 | ||
| 156 | */ | ||
| 157 | @Schema(description = "接收人唯一标识") | ||
| 158 | private String acceptanceNameGuid; | ||
| 159 | |||
| 160 | /** | ||
| 161 | * 关联合同信息 | ||
| 162 | */ | ||
| 163 | @Schema(description = "关联合同信息") | ||
| 164 | private String linkContractInfoJson; | ||
| 165 | |||
| 166 | @Schema(description = "加工单位类型") | ||
| 167 | private String processCompanyType; | ||
| 168 | |||
| 169 | /** | ||
| 170 | * 负责人姓名 | ||
| 171 | */ | ||
| 172 | @Schema(description = "负责人姓名") | ||
| 173 | private String chargeStaffName; | ||
| 174 | |||
| 175 | /** | ||
| 176 | * 负责人GUID | ||
| 177 | */ | ||
| 178 | @Schema(description = "负责人GUID") | ||
| 179 | private String chargeStaffGuid; | ||
| 180 | |||
| 181 | /** | ||
| 182 | * 加加工成员【数据格式:[{"guid":"","name":""}]】 | ||
| 183 | */ | ||
| 184 | @Schema(description = "加工成员【数据格式:[{‘guid’:‘’,‘name’:‘’}]") | ||
| 185 | private String processMemberJson; | ||
| 186 | |||
| 187 | /** | ||
| 188 | * 最后操作人唯一标识 | ||
| 189 | */ | ||
| 190 | @Schema(description = "最后操作人唯一标识") | ||
| 191 | private String lastOperatorUserId; | ||
| 192 | |||
| 193 | /** | ||
| 194 | * 最后操作人姓名 | ||
| 195 | */ | ||
| 196 | @Schema(description = "最后操作人姓名") | ||
| 197 | private String lastOperatorUserName; | ||
| 198 | |||
| 199 | /** | ||
| 200 | * 指派时间 | ||
| 201 | */ | ||
| 202 | @Schema(description = "指派时间") | ||
| 203 | @JsonFormat(pattern = "yyyy-MM-dd", timezone = "GMT+8") | ||
| 204 | private Date assignDay; | ||
| 205 | |||
| 206 | /** | ||
| 207 | * 加工时间 | ||
| 208 | */ | ||
| 209 | @Schema(description = "加工时间") | ||
| 210 | @JsonFormat(pattern = "yyyy-MM-dd", timezone = "GMT+8") | ||
| 211 | private Date processTime; | ||
| 212 | |||
| 213 | /** | ||
| 214 | * 交付时间 | ||
| 215 | */ | ||
| 216 | @Schema(description = "交付时间") | ||
| 217 | @JsonFormat(pattern = "yyyy-MM-dd", timezone = "GMT+8") | ||
| 218 | private Date deliverTime; | ||
| 219 | |||
| 220 | /** | ||
| 221 | * 分库标识 | ||
| 222 | */ | ||
| 223 | @Schema(description = "分库标识") | ||
| 224 | private String shardingFlag; | ||
| 225 | |||
| 226 | /******** 库表存储属性 需处理 *****/ | ||
| 227 | |||
| 228 | /******** 自定义扩展 *****/ | ||
| 229 | |||
| 230 | /******** 子对象 *****/ | ||
| 231 | |||
| 232 | } |
| 1 | package com.csbr.qingcloud.portal.domain.vo; | ||
| 2 | |||
| 3 | import lombok.Data; | ||
| 4 | import lombok.experimental.Accessors; | ||
| 5 | |||
| 6 | /** | ||
| 7 | * @program: common-admin-platform-auth-service | ||
| 8 | * @description: 订单编号DTO | ||
| 9 | * @author: Huanglh | ||
| 10 | * @create: 2020-08-14 09:41 | ||
| 11 | **/ | ||
| 12 | @Data | ||
| 13 | @Accessors(chain = true) | ||
| 14 | public class RuleDTO { | ||
| 15 | /** 规则名称 */ | ||
| 16 | private String ruleName; | ||
| 17 | |||
| 18 | /** 规则类型 */ | ||
| 19 | private String ruleType; | ||
| 20 | } |
| 1 | package com.csbr.qingcloud.portal.domain.vo; | ||
| 2 | |||
| 3 | import com.csbr.cloud.mybatis.annotations.LikeQuery; | ||
| 4 | import com.csbr.cloud.mybatis.enums.LikeQueryEnum; | ||
| 5 | import com.csbr.cloud.workflow.domain.dto.appove.FlowBizGuidQueryDTO; | ||
| 6 | import io.swagger.v3.oas.annotations.media.Schema; | ||
| 7 | import lombok.EqualsAndHashCode; | ||
| 8 | import lombok.Data; | ||
| 9 | import java.util.Date; | ||
| 10 | import java.util.List; | ||
| 11 | |||
| 12 | /** | ||
| 13 | * @program: D:/git/ms-data-circulation-portal-service | ||
| 14 | * @description: 服务商维护查询参数 | ||
| 15 | * @author: xcq | ||
| 16 | * @create: 2024-12-31 18:49 | ||
| 17 | **/ | ||
| 18 | @EqualsAndHashCode(callSuper = true) | ||
| 19 | @Data | ||
| 20 | @Schema(title = "服务商维护查询参数") | ||
| 21 | public class ServicerMaintainQueryVO extends FlowBizGuidQueryDTO { | ||
| 22 | |||
| 23 | @Schema(description = "公司名称") | ||
| 24 | @LikeQuery(type = LikeQueryEnum.ALL) | ||
| 25 | private String tenantName; | ||
| 26 | |||
| 27 | @Schema(description = "企业类型【选择平台字典【公司类型】的选项】") | ||
| 28 | private String tenantType; | ||
| 29 | |||
| 30 | @Schema(description = "能否继续合作【Y 能;N 不能;】") | ||
| 31 | private String canContinueCollaborate; | ||
| 32 | |||
| 33 | /** | ||
| 34 | * 业务审批状态【N 草稿中,A 审批中,Y 已通过,R 驳回,C 已撤销,D 已废弃】 | ||
| 35 | */ | ||
| 36 | @Schema(description = "业务审批状态【N 草稿中,A 审批中,Y 已通过,R 驳回,C 已撤销,D 已废弃】") | ||
| 37 | private String bizApproveState; | ||
| 38 | |||
| 39 | /******** 自定义扩展 *****/ | ||
| 40 | |||
| 41 | /** | ||
| 42 | * 数据唯一标识【List集合】 | ||
| 43 | */ | ||
| 44 | @Schema(description = "数据唯一标识", hidden = true) | ||
| 45 | private List<String> guidList; | ||
| 46 | |||
| 47 | /** | ||
| 48 | * 是否调用查询的判断 | ||
| 49 | */ | ||
| 50 | @Schema(description = "是否调用查询的判断", hidden = true) | ||
| 51 | private Boolean isNeedQuery; | ||
| 52 | |||
| 53 | } |
| 1 | package com.csbr.qingcloud.portal.domain.vo; | ||
| 2 | |||
| 3 | import com.csbr.cloud.workflow.domain.vo.appove.FlowRQBaseVO; | ||
| 4 | import io.swagger.v3.oas.annotations.media.Schema; | ||
| 5 | import com.fasterxml.jackson.annotation.JsonFormat; | ||
| 6 | import lombok.Data; | ||
| 7 | import java.util.Date; | ||
| 8 | |||
| 9 | /** | ||
| 10 | * @program: D:/git/ms-data-circulation-portal-service | ||
| 11 | * @description: 服务商维护新增、修改参数 | ||
| 12 | * @author: xcq | ||
| 13 | * @create: 2024-12-31 18:49 | ||
| 14 | **/ | ||
| 15 | @Data | ||
| 16 | @Schema(title = "服务商维护新增、修改参数") | ||
| 17 | public class ServicerMaintainRQVO extends FlowRQBaseVO { | ||
| 18 | |||
| 19 | /** | ||
| 20 | * 企业唯一标识 | ||
| 21 | */ | ||
| 22 | @Schema(description = "企业唯一标识") | ||
| 23 | private String tenantGuid; | ||
| 24 | |||
| 25 | /** | ||
| 26 | * 公司名称 | ||
| 27 | */ | ||
| 28 | @Schema(description = "公司名称") | ||
| 29 | private String tenantName; | ||
| 30 | |||
| 31 | /** | ||
| 32 | * 企业类型【选择平台字典【公司类型】的选项】 | ||
| 33 | */ | ||
| 34 | @Schema(description = "企业类型【选择平台字典【公司类型】的选项】") | ||
| 35 | private String tenantType; | ||
| 36 | |||
| 37 | /** | ||
| 38 | * 提交时间 | ||
| 39 | */ | ||
| 40 | @Schema(description = "提交时间") | ||
| 41 | @JsonFormat(pattern = "yyyy-MM-dd HH:mm:ss", timezone = "GMT+8") | ||
| 42 | private Date submitTime; | ||
| 43 | |||
| 44 | /** | ||
| 45 | * 联系人 | ||
| 46 | */ | ||
| 47 | @Schema(description = "联系人") | ||
| 48 | private String contacts; | ||
| 49 | |||
| 50 | /** | ||
| 51 | * 联系人电话 | ||
| 52 | */ | ||
| 53 | @Schema(description = "联系人电话") | ||
| 54 | private String contactTel; | ||
| 55 | |||
| 56 | /** | ||
| 57 | * 业务审批状态【N 草稿中,A 审批中,Y 已通过,R 驳回,C 已撤销,D 已废弃; 默认 N】 | ||
| 58 | */ | ||
| 59 | @Schema(description = "业务审批状态(传Y表示不走审批流)【N 草稿中,A 审批中,Y 已通过,R 驳回,C 已撤销,D 已废弃; 默认 N】") | ||
| 60 | private String bizApproveState; | ||
| 61 | |||
| 62 | /** | ||
| 63 | * 能否继续合作【Y 能;N 不能;】 | ||
| 64 | */ | ||
| 65 | @Schema(description = "能否继续合作【Y 能;N 不能;】") | ||
| 66 | private String canContinueCollaborate; | ||
| 67 | |||
| 68 | /** | ||
| 69 | * 维护信息 | ||
| 70 | */ | ||
| 71 | @Schema(description = "维护信息") | ||
| 72 | private String maintainJson; | ||
| 73 | |||
| 74 | /******** 库表存储属性 需处理 *****/ | ||
| 75 | |||
| 76 | /******** 自定义扩展 *****/ | ||
| 77 | |||
| 78 | /******** 子对象 *****/ | ||
| 79 | |||
| 80 | } |
| 1 | package com.csbr.qingcloud.portal.domain.vo; | ||
| 2 | |||
| 3 | import io.swagger.v3.oas.annotations.media.Schema; | ||
| 4 | import com.fasterxml.jackson.annotation.JsonFormat; | ||
| 5 | import lombok.Data; | ||
| 6 | import com.csbr.cloud.workflow.domain.vo.appove.BizApproveVO; | ||
| 7 | import java.util.Date; | ||
| 8 | |||
| 9 | /** | ||
| 10 | * @program: D:/git/ms-data-circulation-portal-service | ||
| 11 | * @description: 服务商维护返回参数 | ||
| 12 | * @author: xcq | ||
| 13 | * @create: 2024-12-31 18:49 | ||
| 14 | **/ | ||
| 15 | @Data | ||
| 16 | @Schema(title = "服务商维护返回参数") | ||
| 17 | public class ServicerMaintainRSVO { | ||
| 18 | |||
| 19 | /** | ||
| 20 | * 系统唯一标识 | ||
| 21 | */ | ||
| 22 | @Schema(description = "系统唯一标识") | ||
| 23 | private String guid; | ||
| 24 | |||
| 25 | /** | ||
| 26 | * 企业唯一标识 | ||
| 27 | */ | ||
| 28 | @Schema(description = "企业唯一标识") | ||
| 29 | private String tenantGuid; | ||
| 30 | |||
| 31 | /** | ||
| 32 | * 公司名称 | ||
| 33 | */ | ||
| 34 | @Schema(description = "公司名称") | ||
| 35 | private String tenantName; | ||
| 36 | |||
| 37 | /** | ||
| 38 | * 企业类型【选择平台字典【公司类型】的选项】 | ||
| 39 | */ | ||
| 40 | @Schema(description = "企业类型【选择平台字典【公司类型】的选项】") | ||
| 41 | private String tenantType; | ||
| 42 | |||
| 43 | /** | ||
| 44 | * 提交时间 | ||
| 45 | */ | ||
| 46 | @Schema(description = "提交时间") | ||
| 47 | @JsonFormat(pattern = "yyyy-MM-dd HH:mm:ss", timezone = "GMT+8") | ||
| 48 | private Date submitTime; | ||
| 49 | |||
| 50 | /** | ||
| 51 | * 联系人 | ||
| 52 | */ | ||
| 53 | @Schema(description = "联系人") | ||
| 54 | private String contacts; | ||
| 55 | |||
| 56 | /** | ||
| 57 | * 联系人电话 | ||
| 58 | */ | ||
| 59 | @Schema(description = "联系人电话") | ||
| 60 | private String contactTel; | ||
| 61 | |||
| 62 | /** | ||
| 63 | * 业务审批状态【N 草稿中,A 审批中,Y 已通过,R 驳回,C 已撤销,D 已废弃; 默认 N】 | ||
| 64 | */ | ||
| 65 | @Schema(description = "业务审批状态【N 草稿中,A 审批中,Y 已通过,R 驳回,C 已撤销,D 已废弃; 默认 N】") | ||
| 66 | private String bizApproveState; | ||
| 67 | |||
| 68 | /** | ||
| 69 | * 能否继续合作【Y 能;N 不能;】 | ||
| 70 | */ | ||
| 71 | @Schema(description = "能否继续合作【Y 能;N 不能;】") | ||
| 72 | private String canContinueCollaborate; | ||
| 73 | |||
| 74 | /** | ||
| 75 | * 维护信息 | ||
| 76 | */ | ||
| 77 | @Schema(description = "维护信息") | ||
| 78 | private String maintainJson; | ||
| 79 | |||
| 80 | @Schema(description = "创建人") | ||
| 81 | private String createUserName; | ||
| 82 | |||
| 83 | @Schema(description = "创建时间") | ||
| 84 | private Date createTime; | ||
| 85 | |||
| 86 | /******** 库表存储属性 需处理 *****/ | ||
| 87 | |||
| 88 | /******** 自定义扩展 *****/ | ||
| 89 | |||
| 90 | @Schema(description = "企业类型名称") | ||
| 91 | private String tenantTypeName; | ||
| 92 | |||
| 93 | /** | ||
| 94 | * 审批信息 | ||
| 95 | */ | ||
| 96 | @Schema(description = "审批信息") | ||
| 97 | private BizApproveVO approveVO; | ||
| 98 | |||
| 99 | /******** 子对象 *****/ | ||
| 100 | |||
| 101 | } |
| 1 | package com.csbr.qingcloud.portal.domain.vo; | ||
| 2 | |||
| 3 | import csbr.cloud.entity.domain.base.vo.CsbrBaseVO; | ||
| 4 | import csbr.cloud.entity.domain.common.CommonJson; | ||
| 5 | import io.swagger.v3.oas.annotations.media.Schema; | ||
| 6 | import jdk.jfr.Name; | ||
| 7 | import lombok.Data; | ||
| 8 | import lombok.EqualsAndHashCode; | ||
| 9 | import lombok.experimental.Accessors; | ||
| 10 | import java.util.List; | ||
| 11 | |||
| 12 | /** | ||
| 13 | * 人员表 视图对象类 | ||
| 14 | * | ||
| 15 | * @author xiaocq | ||
| 16 | * @date 2023-12-19 | ||
| 17 | */ | ||
| 18 | @Data | ||
| 19 | @Accessors(chain = true) | ||
| 20 | @EqualsAndHashCode(callSuper = true) | ||
| 21 | @Schema(name = "人员详情返回实体") | ||
| 22 | public class StaffRSVO extends CsbrBaseVO { | ||
| 23 | |||
| 24 | /** | ||
| 25 | * 上级guid | ||
| 26 | */ | ||
| 27 | @Schema(description = "上级guid") | ||
| 28 | private String leaderGuid; | ||
| 29 | |||
| 30 | /** | ||
| 31 | * 用户guid | ||
| 32 | */ | ||
| 33 | @Schema(description = "用户guid") | ||
| 34 | private String userGuid; | ||
| 35 | |||
| 36 | /** | ||
| 37 | * 微信小程序openId | ||
| 38 | */ | ||
| 39 | @Schema(description = "微信小程序openId") | ||
| 40 | private String wechatOpenId; | ||
| 41 | |||
| 42 | /** | ||
| 43 | * 微信公众号openId | ||
| 44 | */ | ||
| 45 | @Name("微信公众号openId") | ||
| 46 | @Schema(description = "微信公众号openId") | ||
| 47 | private String openId; | ||
| 48 | |||
| 49 | /** | ||
| 50 | * 微信唯一码 | ||
| 51 | */ | ||
| 52 | @Name("微信唯一码") | ||
| 53 | @Schema(description = "微信唯一码") | ||
| 54 | private String unionId; | ||
| 55 | |||
| 56 | /** | ||
| 57 | * 工作地 | ||
| 58 | */ | ||
| 59 | @Schema(description = "工作地") | ||
| 60 | private String workAddress; | ||
| 61 | |||
| 62 | /** | ||
| 63 | * 是否部门负责人 | ||
| 64 | */ | ||
| 65 | @Schema(description = "是否部门负责人") | ||
| 66 | private String isLeader; | ||
| 67 | |||
| 68 | /** | ||
| 69 | * 公司邮箱 | ||
| 70 | */ | ||
| 71 | @Schema(description = "公司邮箱") | ||
| 72 | private String companyEmail; | ||
| 73 | |||
| 74 | /** | ||
| 75 | * 姓名 | ||
| 76 | */ | ||
| 77 | @Schema(description = "姓名") | ||
| 78 | private String staffName; | ||
| 79 | |||
| 80 | |||
| 81 | /** | ||
| 82 | * 工号 | ||
| 83 | */ | ||
| 84 | @Schema(description = "工号") | ||
| 85 | private String staffNo; | ||
| 86 | |||
| 87 | /** | ||
| 88 | * 手机号码 | ||
| 89 | */ | ||
| 90 | @Schema(description = "手机号码") | ||
| 91 | private String mobileNo; | ||
| 92 | |||
| 93 | /** | ||
| 94 | * 身份证号 | ||
| 95 | */ | ||
| 96 | @Schema(description = "身份证号") | ||
| 97 | private String idCode; | ||
| 98 | |||
| 99 | /** | ||
| 100 | * 企业guid | ||
| 101 | */ | ||
| 102 | @Schema(description = "企业guid") | ||
| 103 | private String tenantGuid; | ||
| 104 | |||
| 105 | |||
| 106 | /** | ||
| 107 | * 部门guidJson | ||
| 108 | */ | ||
| 109 | @Schema(description = "部门guidJson") | ||
| 110 | private String organisationGuidJson; | ||
| 111 | |||
| 112 | /** | ||
| 113 | * 组织架构guid列表 | ||
| 114 | */ | ||
| 115 | @Schema(description = "组织架构guid列表") | ||
| 116 | private String organisationRelGuidJson; | ||
| 117 | |||
| 118 | /** | ||
| 119 | * 岗位guidJson | ||
| 120 | */ | ||
| 121 | @Schema(description = "岗位guidJson") | ||
| 122 | private String postGuidJson; | ||
| 123 | |||
| 124 | @Schema(description = "是否管理员") | ||
| 125 | private String isAdmin; | ||
| 126 | |||
| 127 | /********非库表存储属性*****/ | ||
| 128 | |||
| 129 | |||
| 130 | /** 职级名称 */ | ||
| 131 | @Schema(description = "上级名称") | ||
| 132 | private String leaderName; | ||
| 133 | |||
| 134 | /** 企业名称 */ | ||
| 135 | @Schema(description = "企业名称") | ||
| 136 | private String tenantName; | ||
| 137 | |||
| 138 | @Schema(description = "状态Y 期用;S 停用") | ||
| 139 | private String bizState; | ||
| 140 | |||
| 141 | /** 部门guid列表 */ | ||
| 142 | @Schema(description = "部门guid列表") | ||
| 143 | private List<String> organisationGuidList; | ||
| 144 | |||
| 145 | /** 部门列表名称 */ | ||
| 146 | @Schema(description = "部门列表名称") | ||
| 147 | private List<String> organisationNameList; | ||
| 148 | |||
| 149 | /** 岗位guid列表 */ | ||
| 150 | @Schema(description = "岗位guid列表") | ||
| 151 | private List<String> postGuidList; | ||
| 152 | |||
| 153 | /** 岗位列表名称 */ | ||
| 154 | @Schema(description = "岗位列表名称") | ||
| 155 | private List<String> postNameList; | ||
| 156 | |||
| 157 | /********字典类*****/ | ||
| 158 | |||
| 159 | /********实体类、用户单选、组织机构单选*****/ | ||
| 160 | |||
| 161 | /********范围查询*****/ | ||
| 162 | |||
| 163 | /********自定义扩展*****/ | ||
| 164 | |||
| 165 | /********子对象*****/ | ||
| 166 | |||
| 167 | @Schema(description = "菜单模板") | ||
| 168 | private List<CommonJson> funcPermissionTemplateJson; | ||
| 169 | |||
| 170 | |||
| 171 | } |
| 1 | package com.csbr.qingcloud.portal.domain.vo; | ||
| 2 | |||
| 3 | import csbr.cloud.entity.domain.base.vo.CsbrBaseVO; | ||
| 4 | import io.swagger.v3.oas.annotations.media.Schema; | ||
| 5 | import lombok.Data; | ||
| 6 | import lombok.EqualsAndHashCode; | ||
| 7 | import lombok.experimental.Accessors; | ||
| 8 | |||
| 9 | /** | ||
| 10 | * 企业证照表 视图对象类 | ||
| 11 | * | ||
| 12 | * @author xiaocq | ||
| 13 | * @date 2023-12-19 | ||
| 14 | */ | ||
| 15 | @Data | ||
| 16 | @Accessors(chain = true) | ||
| 17 | @EqualsAndHashCode(callSuper = true) | ||
| 18 | @Schema(name = "企业证照表") | ||
| 19 | public class TenantLicRQVO extends CsbrBaseVO { | ||
| 20 | /** | ||
| 21 | * 企业唯一标识 | ||
| 22 | */ | ||
| 23 | @Schema(description = "企业唯一标识") | ||
| 24 | private String tenantGuid; | ||
| 25 | |||
| 26 | /** | ||
| 27 | * 证照类型 | ||
| 28 | */ | ||
| 29 | @Schema(description = "证照类型") | ||
| 30 | private String licenseType; | ||
| 31 | |||
| 32 | /** | ||
| 33 | * 图片内容 | ||
| 34 | */ | ||
| 35 | @Schema(description = "图片内容") | ||
| 36 | private String pictContentJson; | ||
| 37 | |||
| 38 | |||
| 39 | /********非库表存储属性*****/ | ||
| 40 | |||
| 41 | |||
| 42 | |||
| 43 | /********字典类*****/ | ||
| 44 | |||
| 45 | /********实体类、用户单选、组织机构单选*****/ | ||
| 46 | |||
| 47 | /********范围查询*****/ | ||
| 48 | |||
| 49 | /********自定义扩展*****/ | ||
| 50 | |||
| 51 | /********子对象*****/ | ||
| 52 | |||
| 53 | |||
| 54 | |||
| 55 | |||
| 56 | } |
| 1 | package com.csbr.qingcloud.portal.domain.vo; | ||
| 2 | |||
| 3 | import csbr.cloud.entity.domain.base.vo.CsbrBaseVO; | ||
| 4 | import io.swagger.v3.oas.annotations.media.Schema; | ||
| 5 | import lombok.Data; | ||
| 6 | import lombok.EqualsAndHashCode; | ||
| 7 | import lombok.experimental.Accessors; | ||
| 8 | |||
| 9 | import java.math.BigDecimal; | ||
| 10 | import java.time.LocalDateTime; | ||
| 11 | import java.util.List; | ||
| 12 | |||
| 13 | /** | ||
| 14 | * 企业表 视图对象类 | ||
| 15 | * | ||
| 16 | * @author xiaocq | ||
| 17 | * @date 2023-12-19 | ||
| 18 | */ | ||
| 19 | @Data | ||
| 20 | @Accessors(chain = true) | ||
| 21 | @EqualsAndHashCode(callSuper = true) | ||
| 22 | @Schema(name = "企业表") | ||
| 23 | public class TenantRQVO extends CsbrBaseVO { | ||
| 24 | |||
| 25 | @Schema(description = "上级企业GUID") | ||
| 26 | private String parentGuid; | ||
| 27 | |||
| 28 | /** | ||
| 29 | * 公司编号 | ||
| 30 | */ | ||
| 31 | @Schema(description = "公司编号") | ||
| 32 | private String tenantCode; | ||
| 33 | |||
| 34 | /** | ||
| 35 | * 公司名称 | ||
| 36 | */ | ||
| 37 | @Schema(description = "公司名称") | ||
| 38 | private String tenantName; | ||
| 39 | |||
| 40 | /** | ||
| 41 | * 公司简称 | ||
| 42 | */ | ||
| 43 | @Schema(description = "公司简称") | ||
| 44 | private String abbreviation; | ||
| 45 | |||
| 46 | @Schema(description = "企业类型") | ||
| 47 | private String tenantType; | ||
| 48 | |||
| 49 | /** | ||
| 50 | * 公司法人 | ||
| 51 | */ | ||
| 52 | @Schema(description = "公司法人") | ||
| 53 | private String personIncharge; | ||
| 54 | |||
| 55 | /** | ||
| 56 | * 注册日期 | ||
| 57 | */ | ||
| 58 | @Schema(description = "注册日期") | ||
| 59 | private LocalDateTime registrationDate; | ||
| 60 | |||
| 61 | /** | ||
| 62 | * 注册资本 | ||
| 63 | */ | ||
| 64 | @Schema(description = "注册资本") | ||
| 65 | private BigDecimal registeredCapital; | ||
| 66 | |||
| 67 | /** | ||
| 68 | * 税号 | ||
| 69 | */ | ||
| 70 | @Schema(description = "税号") | ||
| 71 | private String bankTaxNo; | ||
| 72 | |||
| 73 | /** | ||
| 74 | * 单位地址 | ||
| 75 | */ | ||
| 76 | @Schema(description = "单位地址") | ||
| 77 | private String companyAddress; | ||
| 78 | |||
| 79 | /** | ||
| 80 | * 状态 | ||
| 81 | */ | ||
| 82 | @Schema(description = "状态 N草稿 Y正常 S停用") | ||
| 83 | private String bizState; | ||
| 84 | |||
| 85 | /** | ||
| 86 | * 营业执照经营范围 | ||
| 87 | */ | ||
| 88 | @Schema(description = "营业执照经营范围") | ||
| 89 | private String businessLicenseScope; | ||
| 90 | |||
| 91 | /** | ||
| 92 | * 联系人 | ||
| 93 | */ | ||
| 94 | @Schema(description = "联系人") | ||
| 95 | private String contacts; | ||
| 96 | |||
| 97 | /** | ||
| 98 | * 联系人电话 | ||
| 99 | */ | ||
| 100 | @Schema(description = "联系人电话") | ||
| 101 | private String contactTel; | ||
| 102 | |||
| 103 | /** | ||
| 104 | * 公司电话 | ||
| 105 | */ | ||
| 106 | @Schema(description = "公司电话") | ||
| 107 | private String enterprisePhone; | ||
| 108 | |||
| 109 | /** | ||
| 110 | * 省 | ||
| 111 | */ | ||
| 112 | @Schema(description = "省") | ||
| 113 | private String province; | ||
| 114 | |||
| 115 | /** | ||
| 116 | * 市 | ||
| 117 | */ | ||
| 118 | @Schema(description = "市") | ||
| 119 | private String city; | ||
| 120 | |||
| 121 | /** | ||
| 122 | * 区 | ||
| 123 | */ | ||
| 124 | @Schema(description = "区") | ||
| 125 | private String district; | ||
| 126 | |||
| 127 | /** | ||
| 128 | * 地址 | ||
| 129 | */ | ||
| 130 | @Schema(description = "地址") | ||
| 131 | private String venue; | ||
| 132 | |||
| 133 | /** | ||
| 134 | * 详细地址 | ||
| 135 | */ | ||
| 136 | @Schema(description = "详细地址") | ||
| 137 | private String address; | ||
| 138 | |||
| 139 | /** | ||
| 140 | * 登录账号 | ||
| 141 | */ | ||
| 142 | @Schema(description = "登录账号") | ||
| 143 | private String logonUser; | ||
| 144 | |||
| 145 | @Schema(description = "会员状态 来自字典") | ||
| 146 | private String memberStatus; | ||
| 147 | |||
| 148 | @Schema(description = "持股类型 来自字典") | ||
| 149 | private String holdType; | ||
| 150 | |||
| 151 | |||
| 152 | /********非库表存储属性*****/ | ||
| 153 | |||
| 154 | @Schema(description = "token后台赋值") | ||
| 155 | private String token; | ||
| 156 | |||
| 157 | @Schema(description = "业务唯一标识") | ||
| 158 | private String bizGuid; | ||
| 159 | |||
| 160 | /********字典类*****/ | ||
| 161 | |||
| 162 | /********实体类、用户单选、组织机构单选*****/ | ||
| 163 | |||
| 164 | /********范围查询*****/ | ||
| 165 | |||
| 166 | /********自定义扩展*****/ | ||
| 167 | |||
| 168 | /********子对象*****/ | ||
| 169 | |||
| 170 | @Schema(description = "企业证照列表") | ||
| 171 | private List<TenantLicRQVO> tenantLicList; | ||
| 172 | |||
| 173 | @Schema(hidden = true,description = "分库标识") | ||
| 174 | private String shardingFlag; | ||
| 175 | } |
| 1 | package com.csbr.qingcloud.portal.domain.vo; | ||
| 2 | |||
| 3 | import com.csbr.cloud.mybatis.annotations.LikeQuery; | ||
| 4 | import com.csbr.cloud.mybatis.enums.LikeQueryEnum; | ||
| 5 | import csbr.cloud.entity.domain.base.dto.BasePageDTO; | ||
| 6 | import io.swagger.v3.oas.annotations.media.Schema; | ||
| 7 | import jakarta.validation.constraints.Pattern; | ||
| 8 | import lombok.Data; | ||
| 9 | |||
| 10 | import java.util.List; | ||
| 11 | |||
| 12 | /** | ||
| 13 | * @program: common-admin-platform-auth-service | ||
| 14 | * @description: 用户查询参数 | ||
| 15 | * @author: yio | ||
| 16 | * @create: 2020-07-28 13:47 | ||
| 17 | **/ | ||
| 18 | @Data | ||
| 19 | @Schema(name = "用户查询参数") | ||
| 20 | public class UserQueryDTO extends BasePageDTO { | ||
| 21 | /** 系统唯一标识 */ | ||
| 22 | @Schema(name = "guid",title = "系统唯一标识") | ||
| 23 | private String guid; | ||
| 24 | |||
| 25 | /** 锁定(Y 是;N 否) */ | ||
| 26 | @Schema(name = "guid",title = "锁定(Y 是;N 否)") | ||
| 27 | @Pattern(regexp = "^Y|N$", message = "锁定应该为Y、N中的值。") | ||
| 28 | private String isLocked; | ||
| 29 | |||
| 30 | /** 登录账号 */ | ||
| 31 | @Schema(name = "guid",title = "登录账号") | ||
| 32 | @LikeQuery(type = LikeQueryEnum.ALL) | ||
| 33 | private String logonUser; | ||
| 34 | |||
| 35 | /** 登录账号(多个) */ | ||
| 36 | @Schema(name = "guid",title = "登录账号(多个)") | ||
| 37 | private List<String> logonUserList; | ||
| 38 | |||
| 39 | /** 手机号 */ | ||
| 40 | @Schema(name = "guid",title = "手机号") | ||
| 41 | @LikeQuery(type = LikeQueryEnum.ALL) | ||
| 42 | private String mobileNo; | ||
| 43 | |||
| 44 | /** 手机号 */ | ||
| 45 | @Schema(name = "guid",title = "手机号(多个)") | ||
| 46 | @LikeQuery(type = LikeQueryEnum.ALL) | ||
| 47 | private List<String> mobileNoList; | ||
| 48 | |||
| 49 | /** 姓名 */ | ||
| 50 | @Schema(name = "guid",title = "姓名") | ||
| 51 | @LikeQuery(type = LikeQueryEnum.ALL) | ||
| 52 | private String name; | ||
| 53 | |||
| 54 | /** 平台GUID */ | ||
| 55 | @Schema(name = "guid",title = "平台GUID") | ||
| 56 | private String platformGuid; | ||
| 57 | |||
| 58 | /** 业务状态(Y 有效;S 停用) */ | ||
| 59 | @Schema(name = "guid",title = "业务状态(Y 有效;S 停用)") | ||
| 60 | @Pattern(regexp = "^Y|S$", message = "业务状态应该为Y、S中的值。") | ||
| 61 | private String bizState; | ||
| 62 | |||
| 63 | } |
| 1 | package com.csbr.qingcloud.portal.domain.vo; | ||
| 2 | |||
| 3 | import com.baomidou.mybatisplus.annotation.TableLogic; | ||
| 4 | import io.swagger.v3.oas.annotations.media.Schema; | ||
| 5 | import lombok.Data; | ||
| 6 | |||
| 7 | import java.sql.Timestamp; | ||
| 8 | |||
| 9 | /** | ||
| 10 | * @program: common-admin-platform-auth-service | ||
| 11 | * @description: 获取用户查询的返回值对象 | ||
| 12 | * @author: yio | ||
| 13 | * @create: 2020-07-28 14:46 | ||
| 14 | **/ | ||
| 15 | @Data | ||
| 16 | @Schema(name = "获取用户查询的返回值对象") | ||
| 17 | public class UserVO { | ||
| 18 | |||
| 19 | /** 业务状态(Y 有效;S 停用) */ | ||
| 20 | @Schema(name = "guid",title = "业务状态(Y 有效;S 停用)") | ||
| 21 | private String bizState; | ||
| 22 | |||
| 23 | /** 创建时间 */ | ||
| 24 | @Schema(name = "guid",title = "创建时间") | ||
| 25 | private Timestamp createTime; | ||
| 26 | |||
| 27 | /** 创建人 */ | ||
| 28 | @Schema(name = "guid",title = "创建人") | ||
| 29 | private String createUserId; | ||
| 30 | |||
| 31 | /** 创建人姓名 */ | ||
| 32 | @Schema(name = "guid",title = "创建人姓名") | ||
| 33 | private String createUserName; | ||
| 34 | |||
| 35 | /** 系统唯一标识 */ | ||
| 36 | @Schema(name = "guid",title = "系统唯一标识") | ||
| 37 | private String guid; | ||
| 38 | |||
| 39 | /** 是否删除(null 是;N 否 默认 N) */ | ||
| 40 | @Schema(name = "guid",title = "是否删除(Y 是;N 否 默认 N)") | ||
| 41 | @TableLogic | ||
| 42 | private String isDeleted; | ||
| 43 | |||
| 44 | /** 锁定(Y 是;N 否) */ | ||
| 45 | @Schema(name = "guid",title = "锁定(Y 是;N 否)") | ||
| 46 | private String isLocked; | ||
| 47 | |||
| 48 | /** 最后登录时间 */ | ||
| 49 | @Schema(name = "guid",title = "最后登录时间") | ||
| 50 | private Timestamp lastLoginTime; | ||
| 51 | |||
| 52 | /** 登录失败次数 */ | ||
| 53 | @Schema(name = "guid",title = "登录失败次数") | ||
| 54 | private Integer loginErrorCount; | ||
| 55 | |||
| 56 | /** 登录账号 */ | ||
| 57 | @Schema(name = "guid",title = "登录账号") | ||
| 58 | private String logonUser; | ||
| 59 | |||
| 60 | /** 手机号 */ | ||
| 61 | @Schema(name = "guid",title = "手机号") | ||
| 62 | private String mobileNo; | ||
| 63 | |||
| 64 | /** 姓名 */ | ||
| 65 | @Schema(name = "guid",title = "姓名") | ||
| 66 | private String name; | ||
| 67 | |||
| 68 | /** 平台GUID */ | ||
| 69 | @Schema(name = "guid",title = "平台GUID") | ||
| 70 | private String platformGuid; | ||
| 71 | |||
| 72 | /** 密码 */ | ||
| 73 | @Schema(name = "guid",title = "密码") | ||
| 74 | private String pwd; | ||
| 75 | |||
| 76 | /** 修改时间 */ | ||
| 77 | @Schema(name = "guid",title = "修改时间") | ||
| 78 | private Timestamp updateTime; | ||
| 79 | |||
| 80 | /** 修改人 */ | ||
| 81 | @Schema(name = "guid",title = "修改人") | ||
| 82 | private String updateUserId; | ||
| 83 | |||
| 84 | /** 修改姓名 */ | ||
| 85 | @Schema(name = "guid",title = "修改姓名") | ||
| 86 | private String updateUserName; | ||
| 87 | |||
| 88 | @Schema(name = "guid",title = "微信授权认证的unionId") | ||
| 89 | private String unionId; | ||
| 90 | } |
| 1 | package com.csbr.qingcloud.portal.feign; | ||
| 2 | |||
| 3 | import com.csbr.cloud.common.config.FastCallFeignConfiguration; | ||
| 4 | import com.csbr.cloud.common.entity.DictModel; | ||
| 5 | import com.csbr.cloud.common.entity.DictionaryVO; | ||
| 6 | import com.csbr.cloud.common.response.CommonRes; | ||
| 7 | import com.csbr.qingcloud.portal.domain.vo.BoroughPOJO; | ||
| 8 | import com.csbr.qingcloud.portal.domain.vo.RuleDTO; | ||
| 9 | import com.netflix.hystrix.contrib.javanica.annotation.HystrixCommand; | ||
| 10 | import com.netflix.hystrix.contrib.javanica.annotation.HystrixProperty; | ||
| 11 | import jakarta.validation.Valid; | ||
| 12 | import org.springframework.cloud.openfeign.FeignClient; | ||
| 13 | import org.springframework.http.MediaType; | ||
| 14 | import org.springframework.web.bind.annotation.*; | ||
| 15 | import java.util.List; | ||
| 16 | |||
| 17 | /** | ||
| 18 | * @author Xiaocq | ||
| 19 | */ | ||
| 20 | @FeignClient(value = "ms-daop-configure-service", configuration = FastCallFeignConfiguration.class) | ||
| 21 | |||
| 22 | public interface ConfigureFeign { | ||
| 23 | |||
| 24 | /** | ||
| 25 | * 通过字典类型获取字典数据 | ||
| 26 | */ | ||
| 27 | @HystrixCommand(fallbackMethod = "CommonUtil.sleepFallback", commandProperties = | ||
| 28 | { | ||
| 29 | @HystrixProperty(name = "execution.isolation.thread.timeoutInMilliseconds", value = "1500") | ||
| 30 | }) | ||
| 31 | @RequestMapping(value = "/dict/data/get-by-dictType", method = RequestMethod.GET) | ||
| 32 | CommonRes<List<DictModel>> getDictListByType(@RequestParam String dictType); | ||
| 33 | |||
| 34 | |||
| 35 | /** | ||
| 36 | * 获取全部字典 | ||
| 37 | */ | ||
| 38 | @GetMapping(value = "/dict/data/get-all",produces = MediaType.APPLICATION_JSON_VALUE, consumes = MediaType.APPLICATION_JSON_VALUE) | ||
| 39 | CommonRes<List<DictionaryVO>> getAll(); | ||
| 40 | |||
| 41 | /** | ||
| 42 | * 编码生成 | ||
| 43 | */ | ||
| 44 | @PostMapping(value = "/rule/new-code",produces = MediaType.APPLICATION_JSON_VALUE, consumes = MediaType.APPLICATION_JSON_VALUE) | ||
| 45 | CommonRes<String> newCode(@RequestBody RuleDTO dto); | ||
| 46 | |||
| 47 | @GetMapping(value = "/borough/get-borough",produces = MediaType.APPLICATION_JSON_VALUE, consumes = MediaType.APPLICATION_JSON_VALUE) | ||
| 48 | CommonRes<List<BoroughPOJO>> getBoroughCodeName(); | ||
| 49 | |||
| 50 | |||
| 51 | } |
| 1 | package com.csbr.qingcloud.portal.feign; | ||
| 2 | |||
| 3 | import com.csbr.cloud.common.config.FastCallFeignConfiguration; | ||
| 4 | import com.csbr.cloud.common.response.CommonRes; | ||
| 5 | import com.csbr.qingcloud.portal.domain.vo.DemandUpdateStateVO; | ||
| 6 | import com.csbr.qingcloud.portal.domain.vo.ProcessOrderProcessDtlRSVO; | ||
| 7 | import com.csbr.qingcloud.portal.domain.vo.ProcessOrderRQVO; | ||
| 8 | import jakarta.validation.Valid; | ||
| 9 | import org.springframework.cloud.openfeign.FeignClient; | ||
| 10 | import org.springframework.http.MediaType; | ||
| 11 | import org.springframework.web.bind.annotation.PostMapping; | ||
| 12 | import org.springframework.web.bind.annotation.RequestBody; | ||
| 13 | import java.util.List; | ||
| 14 | import java.util.Map; | ||
| 15 | |||
| 16 | /** | ||
| 17 | * @author Xiaocq | ||
| 18 | */ | ||
| 19 | @FeignClient(value = "ms-data-process-basic-service",url = "${dataProcessUrl}", configuration = FastCallFeignConfiguration.class) | ||
| 20 | public interface DataProcessBasicFeign { | ||
| 21 | |||
| 22 | @PostMapping(value = "/process-order/saveOrUpdate", produces = MediaType.APPLICATION_JSON_VALUE, consumes = MediaType.APPLICATION_JSON_VALUE) | ||
| 23 | CommonRes<Boolean> saveProcessOrder(@RequestBody @Valid ProcessOrderRQVO vo); | ||
| 24 | |||
| 25 | @PostMapping(value = "/process-order-process-dtl/get-order-state", produces = MediaType.APPLICATION_JSON_VALUE, consumes = MediaType.APPLICATION_JSON_VALUE) | ||
| 26 | CommonRes<Map<String, DemandUpdateStateVO>> getOrderState(@RequestBody List<String> processOrderGuids); | ||
| 27 | |||
| 28 | @PostMapping(value = "/process-order-process-dtl/process-order-list", produces = MediaType.APPLICATION_JSON_VALUE, consumes = MediaType.APPLICATION_JSON_VALUE) | ||
| 29 | CommonRes<List<ProcessOrderProcessDtlRSVO>> processOrderList(@RequestBody List<String> processOrderGuids); | ||
| 30 | |||
| 31 | @PostMapping(value = "/process-order-process-dtl/get-order-state-and-name", produces = MediaType.APPLICATION_JSON_VALUE, consumes = MediaType.APPLICATION_JSON_VALUE) | ||
| 32 | CommonRes<Map<String, DemandUpdateStateVO>> getOrderStateAndBizName(@RequestBody List<String> bizGuids); | ||
| 33 | |||
| 34 | } |
| 1 | package com.csbr.qingcloud.portal.feign; | ||
| 2 | |||
| 3 | import com.csbr.cloud.common.config.FastCallFeignConfiguration; | ||
| 4 | import com.csbr.cloud.common.response.CommonRes; | ||
| 5 | import com.csbr.qingcloud.portal.domain.vo.StaffRSVO; | ||
| 6 | import com.csbr.qingcloud.portal.domain.vo.TenantRQVO; | ||
| 7 | import org.springframework.cloud.openfeign.FeignClient; | ||
| 8 | import org.springframework.http.MediaType; | ||
| 9 | import org.springframework.validation.annotation.Validated; | ||
| 10 | import org.springframework.web.bind.annotation.*; | ||
| 11 | |||
| 12 | import java.util.Map; | ||
| 13 | |||
| 14 | /** | ||
| 15 | * @author Xiaocq | ||
| 16 | */ | ||
| 17 | @FeignClient(value = "ms-daop-personel-service", configuration = FastCallFeignConfiguration.class) | ||
| 18 | public interface PersonelFeign { | ||
| 19 | |||
| 20 | @PostMapping(value = "/tenant/auth", produces = MediaType.APPLICATION_JSON_VALUE, consumes = MediaType.APPLICATION_JSON_VALUE) | ||
| 21 | CommonRes<TenantRQVO> authTenant(@RequestBody TenantRQVO vo); | ||
| 22 | |||
| 23 | @PutMapping(value = "/tenant/update", produces = MediaType.APPLICATION_JSON_VALUE, consumes = MediaType.APPLICATION_JSON_VALUE) | ||
| 24 | CommonRes<String> updateTenant(@RequestBody TenantRQVO vo); | ||
| 25 | |||
| 26 | @PutMapping(value = "/tenant/change-update", produces = MediaType.APPLICATION_JSON_VALUE, consumes = MediaType.APPLICATION_JSON_VALUE) | ||
| 27 | CommonRes<Boolean> changeUpdate(@RequestBody TenantRQVO vo); | ||
| 28 | |||
| 29 | @GetMapping(value = "/tenant/get-all-tenant-guid-name-map", produces = MediaType.APPLICATION_JSON_VALUE, consumes = MediaType.APPLICATION_JSON_VALUE) | ||
| 30 | CommonRes<Map<String, String>> getAllTenantGuidNameMap(); | ||
| 31 | |||
| 32 | @PostMapping(value = "/tenant/check", produces = MediaType.APPLICATION_JSON_VALUE, consumes = MediaType.APPLICATION_JSON_VALUE) | ||
| 33 | CommonRes<Boolean> checkTenant(@Validated @RequestBody TenantRQVO vo); | ||
| 34 | |||
| 35 | @GetMapping(value = "/staff/getByUserGuid", produces = MediaType.APPLICATION_JSON_VALUE, consumes = MediaType.APPLICATION_JSON_VALUE) | ||
| 36 | CommonRes<StaffRSVO> getByUserGuid(@RequestParam String userGuid); | ||
| 37 | |||
| 38 | } |
| 1 | package com.csbr.qingcloud.portal.feign; | ||
| 2 | |||
| 3 | import com.csbr.cloud.common.config.FastCallFeignConfiguration; | ||
| 4 | import com.csbr.cloud.common.response.CommonRes; | ||
| 5 | import com.csbr.qingcloud.portal.domain.vo.UserQueryDTO; | ||
| 6 | import com.csbr.qingcloud.portal.domain.vo.UserVO; | ||
| 7 | import csbr.cloud.entity.domain.base.vo.PageListVO; | ||
| 8 | import org.springframework.cloud.openfeign.FeignClient; | ||
| 9 | import org.springframework.http.MediaType; | ||
| 10 | import org.springframework.web.bind.annotation.*; | ||
| 11 | import java.util.List; | ||
| 12 | |||
| 13 | /** | ||
| 14 | * @author Xiaocq | ||
| 15 | */ | ||
| 16 | @FeignClient(value = "ms-daop-user-service", configuration = FastCallFeignConfiguration.class) | ||
| 17 | public interface UserFeign { | ||
| 18 | |||
| 19 | @PostMapping(value = "/user/data/get-some-info", produces = MediaType.APPLICATION_JSON_VALUE, consumes = MediaType.APPLICATION_JSON_VALUE) | ||
| 20 | CommonRes<PageListVO<UserVO>> getUserSomeInfo(@RequestBody UserQueryDTO dto); | ||
| 21 | |||
| 22 | /** | ||
| 23 | * 通过手机查用户 | ||
| 24 | */ | ||
| 25 | @PostMapping(value = "/user/data/get/mobile", produces = MediaType.APPLICATION_JSON_VALUE, consumes = MediaType.APPLICATION_JSON_VALUE) | ||
| 26 | CommonRes<List<UserVO>> getUserByMobileOrIdCode(@RequestBody UserQueryDTO dto); | ||
| 27 | |||
| 28 | } |
| 1 | package com.csbr.qingcloud.portal.feign; | ||
| 2 | |||
| 3 | import com.csbr.cloud.common.config.FastCallFeignConfiguration; | ||
| 4 | import com.csbr.cloud.common.response.CommonRes; | ||
| 5 | import com.csbr.cloud.workflow.domain.dto.appove.FlowQueryDTO; | ||
| 6 | import com.csbr.cloud.workflow.domain.dto.appove.FlowUpdateStateDTO; | ||
| 7 | import com.csbr.cloud.workflow.domain.vo.appove.ApproveVO; | ||
| 8 | import com.netflix.hystrix.contrib.javanica.annotation.HystrixCommand; | ||
| 9 | import com.netflix.hystrix.contrib.javanica.annotation.HystrixProperty; | ||
| 10 | import csbr.cloud.entity.domain.base.vo.PageListVO; | ||
| 11 | import jakarta.validation.Valid; | ||
| 12 | import org.springframework.cloud.openfeign.FeignClient; | ||
| 13 | import org.springframework.http.MediaType; | ||
| 14 | import org.springframework.util.MultiValueMap; | ||
| 15 | import org.springframework.web.bind.annotation.RequestBody; | ||
| 16 | import org.springframework.web.bind.annotation.RequestHeader; | ||
| 17 | import org.springframework.web.bind.annotation.RequestMapping; | ||
| 18 | import org.springframework.web.bind.annotation.RequestMethod; | ||
| 19 | |||
| 20 | /** | ||
| 21 | * @author Xiaocq | ||
| 22 | */ | ||
| 23 | @FeignClient(value = "ms-daop-workflow-service", configuration = FastCallFeignConfiguration.class) | ||
| 24 | public interface WorkflowFeign { | ||
| 25 | |||
| 26 | /** 动态业务处理 */ | ||
| 27 | @HystrixCommand(fallbackMethod = "CommonUtil.sleepFallback", commandProperties = { | ||
| 28 | @HystrixProperty(name = "execution.isolation.thread.timeoutInMilliseconds", value = "4500")}) | ||
| 29 | @RequestMapping(value = "/work-flow/data/allow-flow-core", method = RequestMethod.POST, produces = MediaType.APPLICATION_JSON_VALUE, consumes = MediaType.APPLICATION_JSON_VALUE) | ||
| 30 | CommonRes<Boolean> allowFlowCore(@RequestBody FlowUpdateStateDTO dto, @RequestHeader(required = false) MultiValueMap<String, String> headers); | ||
| 31 | |||
| 32 | @HystrixCommand(fallbackMethod = "CommonUtil.sleepFallback", commandProperties = { | ||
| 33 | @HystrixProperty(name = "execution.isolation.thread.timeoutInMilliseconds", value = "4500")}) | ||
| 34 | @RequestMapping(value = "/work-flow/data/get-flow-list-tenant", method = RequestMethod.POST, produces = MediaType.APPLICATION_JSON_VALUE, consumes = MediaType.APPLICATION_JSON_VALUE) | ||
| 35 | CommonRes<PageListVO<ApproveVO>> getFlowListCrossTenant(@RequestBody @Valid FlowQueryDTO dto); | ||
| 36 | |||
| 37 | } |
| 1 | package com.csbr.qingcloud.portal.mybatis.entity; | ||
| 2 | |||
| 3 | import com.baomidou.mybatisplus.annotation.FieldStrategy; | ||
| 4 | import com.baomidou.mybatisplus.annotation.TableField; | ||
| 5 | import csbr.cloud.entity.domain.base.dao.BaseShardingDO; | ||
| 6 | import jdk.jfr.Name; | ||
| 7 | import lombok.Data; | ||
| 8 | import lombok.EqualsAndHashCode; | ||
| 9 | import lombok.experimental.Accessors; | ||
| 10 | import java.math.BigDecimal; | ||
| 11 | import java.util.Date; | ||
| 12 | |||
| 13 | /** | ||
| 14 | * @program: D:/git/ms-data-circulation-portal-service | ||
| 15 | * @description: 数据需求实体 | ||
| 16 | * @author: xcq | ||
| 17 | * @create: 2024-12-31 18:46 | ||
| 18 | **/ | ||
| 19 | @Data | ||
| 20 | @EqualsAndHashCode(callSuper = true) | ||
| 21 | @Accessors(chain = true) | ||
| 22 | @Name("数据需求") | ||
| 23 | public class MfDemand extends BaseShardingDO { | ||
| 24 | |||
| 25 | /** | ||
| 26 | * 数据需求名称 | ||
| 27 | */ | ||
| 28 | @Name("数据需求名称") | ||
| 29 | private String dataDemandName; | ||
| 30 | |||
| 31 | /** | ||
| 32 | * 需求类型 | ||
| 33 | */ | ||
| 34 | @Name("需求类型") | ||
| 35 | private String requirementType; | ||
| 36 | |||
| 37 | /** | ||
| 38 | * 需求分类【1新增 2调整】 | ||
| 39 | */ | ||
| 40 | @Name("需求分类【1新增 2调整】") | ||
| 41 | private String demandCategory; | ||
| 42 | |||
| 43 | /** | ||
| 44 | * 数据产品唯一标识 | ||
| 45 | */ | ||
| 46 | @Name("数据产品唯一标识") | ||
| 47 | private String dataProductGuid; | ||
| 48 | |||
| 49 | /** | ||
| 50 | * 需求开始时间 | ||
| 51 | */ | ||
| 52 | @Name("需求开始时间") | ||
| 53 | private Date requirementTermSdate; | ||
| 54 | |||
| 55 | /** | ||
| 56 | * 需求结束时间 | ||
| 57 | */ | ||
| 58 | @Name("需求结束时间") | ||
| 59 | private Date requirementTermEdate; | ||
| 60 | |||
| 61 | /** | ||
| 62 | * 需求内容 | ||
| 63 | */ | ||
| 64 | @Name("需求内容") | ||
| 65 | private String requirementContent; | ||
| 66 | |||
| 67 | /** | ||
| 68 | * 数据需求字段【数据格式:[{"name":"","path":""},{"name":"","path":""}]】 | ||
| 69 | */ | ||
| 70 | @Name("数据需求字段【数据格式:[{\"name\":\"\",\"path\":\"\"},{\"name\":\"\",\"path\":\"\"}]】") | ||
| 71 | @TableField(updateStrategy = FieldStrategy.ALWAYS) | ||
| 72 | private String dataDemandFieldAttachJson; | ||
| 73 | |||
| 74 | /** | ||
| 75 | * 期望交付时间 | ||
| 76 | */ | ||
| 77 | @Name("期望交付时间") | ||
| 78 | private Date deliveryTime; | ||
| 79 | |||
| 80 | /** | ||
| 81 | * 最低预算 | ||
| 82 | */ | ||
| 83 | @Name("最低预算") | ||
| 84 | private BigDecimal minBudget; | ||
| 85 | |||
| 86 | /** | ||
| 87 | * 最高预算 | ||
| 88 | */ | ||
| 89 | @Name("最高预算") | ||
| 90 | private BigDecimal maxBudget; | ||
| 91 | |||
| 92 | /** | ||
| 93 | * 费用来源 | ||
| 94 | */ | ||
| 95 | @Name("费用来源") | ||
| 96 | private String costSource; | ||
| 97 | |||
| 98 | /** | ||
| 99 | * 更新周期【取数据字典:周期,1 年度,2 半年度,3 季度,4 月度】 | ||
| 100 | */ | ||
| 101 | @Name("更新周期【取数据字典:周期,1 年度,2 半年度,3 季度,4 月度】") | ||
| 102 | private String updateCycle; | ||
| 103 | |||
| 104 | /** | ||
| 105 | * 获取路径方式 | ||
| 106 | */ | ||
| 107 | @Name("获取路径方式") | ||
| 108 | private String requestType; | ||
| 109 | |||
| 110 | /** | ||
| 111 | * 场景名称 | ||
| 112 | */ | ||
| 113 | @Name("场景名称") | ||
| 114 | private String sceneName; | ||
| 115 | |||
| 116 | /** | ||
| 117 | * 应用场景描述 | ||
| 118 | */ | ||
| 119 | @Name("应用场景描述") | ||
| 120 | private String sceneDescription; | ||
| 121 | |||
| 122 | /** | ||
| 123 | * 数据质量要求 | ||
| 124 | */ | ||
| 125 | @Name("数据质量要求") | ||
| 126 | private String qualityDemand; | ||
| 127 | |||
| 128 | /** | ||
| 129 | * 隐私合规要求 | ||
| 130 | */ | ||
| 131 | @Name("隐私合规要求") | ||
| 132 | private String privacyDemand; | ||
| 133 | |||
| 134 | /** | ||
| 135 | * 其他补充内容 | ||
| 136 | */ | ||
| 137 | @Name("其他补充内容") | ||
| 138 | private String otherContent; | ||
| 139 | |||
| 140 | /** | ||
| 141 | * 联系人 | ||
| 142 | */ | ||
| 143 | @Name("联系人") | ||
| 144 | private String contacts; | ||
| 145 | |||
| 146 | /** | ||
| 147 | * 需求单位 | ||
| 148 | */ | ||
| 149 | @Name("需求单位") | ||
| 150 | private String requirementUnit; | ||
| 151 | |||
| 152 | /** | ||
| 153 | * 联系方式 | ||
| 154 | */ | ||
| 155 | @Name("联系方式") | ||
| 156 | private String contactInformation; | ||
| 157 | |||
| 158 | /** | ||
| 159 | * 业务审批状态【N 草稿中,A 审批中,Y 已通过,R 驳回,C 已撤销,D 已废弃; 默认 N】 | ||
| 160 | */ | ||
| 161 | @Name("业务审批状态【N 草稿中,A 审批中,Y 已通过,R 驳回,C 已撤销,D 已废弃; 默认 N】") | ||
| 162 | private String bizApproveState; | ||
| 163 | |||
| 164 | /** | ||
| 165 | * 加工单生成时间 | ||
| 166 | */ | ||
| 167 | @Name("加工单生成时间") | ||
| 168 | private Date processingGenerateTime; | ||
| 169 | |||
| 170 | /** | ||
| 171 | * 验收完成时间 | ||
| 172 | */ | ||
| 173 | @Name("验收完成时间") | ||
| 174 | private Date acceptFinishTime; | ||
| 175 | |||
| 176 | /** | ||
| 177 | * 完成周期 | ||
| 178 | */ | ||
| 179 | @Name("完成周期") | ||
| 180 | private Integer finishCycle; | ||
| 181 | |||
| 182 | /** | ||
| 183 | * 资源获取状态【N未开始 A进行中 Y已完成】 | ||
| 184 | */ | ||
| 185 | @Name("资源获取状态【N未开始 A进行中 Y已完成】") | ||
| 186 | private String resourceAcquisitionState; | ||
| 187 | |||
| 188 | /** | ||
| 189 | * 产品加工状态【N未开始 A进行中 Y已完成】 | ||
| 190 | */ | ||
| 191 | @Name("产品加工状态【N未开始 A进行中 Y已完成】") | ||
| 192 | private String productProcessingState; | ||
| 193 | |||
| 194 | /** | ||
| 195 | * 产品交付状态【N未开始 A进行中 Y已完成】 | ||
| 196 | */ | ||
| 197 | @Name("产品交付状态【N未开始 A进行中 Y已完成】") | ||
| 198 | private String productDeliveryState; | ||
| 199 | |||
| 200 | /** | ||
| 201 | * 产品验收状态【N未开始 A进行中 Y已完成】 | ||
| 202 | */ | ||
| 203 | @Name("产品验收状态【N未开始 A进行中 Y已完成】") | ||
| 204 | private String productAcceptState; | ||
| 205 | |||
| 206 | @Name("合同附件") | ||
| 207 | private String contractAttachJson; | ||
| 208 | |||
| 209 | @Name("加工单位类型") | ||
| 210 | private String processCompanyType; | ||
| 211 | |||
| 212 | @Name("加工单位唯一标识") | ||
| 213 | private String processCompanyGuid; | ||
| 214 | |||
| 215 | @Name("加工单位名称") | ||
| 216 | private String processCompanyName; | ||
| 217 | |||
| 218 | @Name("需求单编号") | ||
| 219 | private String requirementOrderNo; | ||
| 220 | |||
| 221 | @Name("加工单编号") | ||
| 222 | private String processOrderNo; | ||
| 223 | |||
| 224 | @Name("资产Guid") | ||
| 225 | private String zqBizGuid; | ||
| 226 | |||
| 227 | @Name("专区名称") | ||
| 228 | private String zqName; | ||
| 229 | |||
| 230 | @Name("审批状态(N 初始 A 审批中 Y 已通过 R 驳回 C 已撤销)") | ||
| 231 | private String crossPlatformApproveState; | ||
| 232 | |||
| 233 | @Name("上架状态(Y 上架 N 下架)") | ||
| 234 | private String listingStatus; | ||
| 235 | |||
| 236 | } |
| 1 | package com.csbr.qingcloud.portal.mybatis.entity; | ||
| 2 | |||
| 3 | import com.baomidou.mybatisplus.annotation.FieldStrategy; | ||
| 4 | import com.baomidou.mybatisplus.annotation.TableField; | ||
| 5 | import csbr.cloud.entity.domain.base.dao.BaseDO; | ||
| 6 | import jdk.jfr.Name; | ||
| 7 | import lombok.Data; | ||
| 8 | import lombok.EqualsAndHashCode; | ||
| 9 | import lombok.experimental.Accessors; | ||
| 10 | import java.math.BigDecimal; | ||
| 11 | import java.util.Date; | ||
| 12 | |||
| 13 | /** | ||
| 14 | * @program: D:/git/ms-data-circulation-portal-service | ||
| 15 | * @description: 企业信息实体 | ||
| 16 | * @author: xcq | ||
| 17 | * @create: 2024-12-26 16:18 | ||
| 18 | **/ | ||
| 19 | @Data | ||
| 20 | @EqualsAndHashCode(callSuper = true) | ||
| 21 | @Accessors(chain = true) | ||
| 22 | @Name("企业信息") | ||
| 23 | public class MfEnterprise extends BaseDO { | ||
| 24 | |||
| 25 | @Name("会员GUID") | ||
| 26 | private String tenantGuid; | ||
| 27 | |||
| 28 | /** | ||
| 29 | * 公司名称 | ||
| 30 | */ | ||
| 31 | @Name("公司名称") | ||
| 32 | private String tenantName; | ||
| 33 | |||
| 34 | /** | ||
| 35 | * 统一社会信用代码 | ||
| 36 | */ | ||
| 37 | @Name("统一社会信用代码") | ||
| 38 | private String socialCreditCode; | ||
| 39 | |||
| 40 | /** | ||
| 41 | * 企业类型【选择平台字典【公司类型】的选项】 | ||
| 42 | */ | ||
| 43 | @Name("企业类型") | ||
| 44 | private String tenantType; | ||
| 45 | |||
| 46 | /** | ||
| 47 | * 注册日期 | ||
| 48 | */ | ||
| 49 | @Name("注册日期") | ||
| 50 | private Date registrationDate; | ||
| 51 | |||
| 52 | /** | ||
| 53 | * 注册资本【(万元)】 | ||
| 54 | */ | ||
| 55 | @Name("注册资本") | ||
| 56 | private BigDecimal registeredCapital; | ||
| 57 | |||
| 58 | /** | ||
| 59 | * 税号 | ||
| 60 | */ | ||
| 61 | @Name("税号") | ||
| 62 | private String bankTaxNo; | ||
| 63 | |||
| 64 | /** | ||
| 65 | * 省 | ||
| 66 | */ | ||
| 67 | @Name("省") | ||
| 68 | private String province; | ||
| 69 | |||
| 70 | /** | ||
| 71 | * 市 | ||
| 72 | */ | ||
| 73 | @Name("市") | ||
| 74 | private String city; | ||
| 75 | |||
| 76 | /** | ||
| 77 | * 区 | ||
| 78 | */ | ||
| 79 | @Name("区") | ||
| 80 | private String district; | ||
| 81 | |||
| 82 | /** | ||
| 83 | * 营业期限【1 长期有效;2 自定义】 | ||
| 84 | */ | ||
| 85 | @Name("营业期限") | ||
| 86 | private String businessLicenseTerm; | ||
| 87 | |||
| 88 | /** | ||
| 89 | * 营业开始日期 | ||
| 90 | */ | ||
| 91 | @Name("营业开始日期") | ||
| 92 | private Date businessLicenseStartDate; | ||
| 93 | |||
| 94 | /** | ||
| 95 | * 营业结束日期 | ||
| 96 | */ | ||
| 97 | @Name("营业结束日期") | ||
| 98 | private Date businessLicenseEndDate; | ||
| 99 | |||
| 100 | /** | ||
| 101 | * 营业执照 | ||
| 102 | */ | ||
| 103 | @Name("营业执照") | ||
| 104 | @TableField(updateStrategy = FieldStrategy.ALWAYS) | ||
| 105 | private String businessLicenseJson; | ||
| 106 | |||
| 107 | /** | ||
| 108 | * 经营范围 | ||
| 109 | */ | ||
| 110 | @Name("经营范围") | ||
| 111 | private String businessLicenseScope; | ||
| 112 | |||
| 113 | /** | ||
| 114 | * 公司法人 | ||
| 115 | */ | ||
| 116 | @Name("公司法人") | ||
| 117 | private String juridicalPerson; | ||
| 118 | |||
| 119 | /** | ||
| 120 | * 法人证件类型 | ||
| 121 | */ | ||
| 122 | @Name("法人证件类型") | ||
| 123 | private String juridicalPersonIdType; | ||
| 124 | |||
| 125 | /** | ||
| 126 | * 法人证件号 | ||
| 127 | */ | ||
| 128 | @Name("法人证件号") | ||
| 129 | private String juridicalPersonId; | ||
| 130 | |||
| 131 | /** | ||
| 132 | * 法人证件照 | ||
| 133 | */ | ||
| 134 | @Name("法人证件照") | ||
| 135 | @TableField(updateStrategy = FieldStrategy.ALWAYS) | ||
| 136 | private String juridicalPersonIdPhotoJson; | ||
| 137 | |||
| 138 | /** | ||
| 139 | * 登录账号 | ||
| 140 | */ | ||
| 141 | @Name("登录账号") | ||
| 142 | private String logonUser; | ||
| 143 | |||
| 144 | /** | ||
| 145 | * 联系人 | ||
| 146 | */ | ||
| 147 | @Name("联系人") | ||
| 148 | private String contacts; | ||
| 149 | |||
| 150 | /** | ||
| 151 | * 联系人电话 | ||
| 152 | */ | ||
| 153 | @Name("联系人电话") | ||
| 154 | private String contactTel; | ||
| 155 | |||
| 156 | /** | ||
| 157 | * 管理员证件号 | ||
| 158 | */ | ||
| 159 | @Name("管理员证件号") | ||
| 160 | private String managerPersonId; | ||
| 161 | |||
| 162 | /** | ||
| 163 | * 管理员证件照 | ||
| 164 | */ | ||
| 165 | @Name("管理员证件照") | ||
| 166 | @TableField(updateStrategy = FieldStrategy.ALWAYS) | ||
| 167 | private String managerPersonIdPhotoJson; | ||
| 168 | |||
| 169 | /** | ||
| 170 | * 授权委托书 | ||
| 171 | */ | ||
| 172 | @Name("授权委托书") | ||
| 173 | private String authorizationLetter; | ||
| 174 | |||
| 175 | @Name("资产Guid") | ||
| 176 | private String zqBizGuid; | ||
| 177 | |||
| 178 | @Name("专区名称") | ||
| 179 | private String zqName; | ||
| 180 | |||
| 181 | @Name("审批状态(N 初始 A 审批中 Y 已通过 R 驳回 C 已撤销)") | ||
| 182 | private String crossPlatformApproveState; | ||
| 183 | |||
| 184 | /** | ||
| 185 | * 业务审批状态【N 草稿中,A 审批中,Y 已通过,R 驳回,C 已撤销,D 已废弃; 默认 N】 | ||
| 186 | */ | ||
| 187 | @Name("业务审批状态") | ||
| 188 | private String bizApproveState; | ||
| 189 | |||
| 190 | } |
| 1 | package com.csbr.qingcloud.portal.mybatis.entity; | ||
| 2 | |||
| 3 | import com.baomidou.mybatisplus.annotation.FieldStrategy; | ||
| 4 | import com.baomidou.mybatisplus.annotation.TableField; | ||
| 5 | import csbr.cloud.entity.domain.base.dao.BaseDO; | ||
| 6 | import jdk.jfr.Name; | ||
| 7 | import lombok.Data; | ||
| 8 | import lombok.EqualsAndHashCode; | ||
| 9 | import lombok.experimental.Accessors; | ||
| 10 | import java.math.BigDecimal; | ||
| 11 | import java.util.Date; | ||
| 12 | |||
| 13 | /** | ||
| 14 | * @program: D:/git/ms-data-circulation-portal-service | ||
| 15 | * @description: 企业信息变更审批实体 | ||
| 16 | * @author: xcq | ||
| 17 | * @create: 2024-12-27 15:10 | ||
| 18 | **/ | ||
| 19 | @Data | ||
| 20 | @EqualsAndHashCode(callSuper = true) | ||
| 21 | @Accessors(chain = true) | ||
| 22 | @Name("企业信息变更审批") | ||
| 23 | public class MfEnterpriseChangeApprove extends BaseDO { | ||
| 24 | |||
| 25 | @Name("会员GUID") | ||
| 26 | private String tenantGuid; | ||
| 27 | |||
| 28 | /** | ||
| 29 | * 公司名称 | ||
| 30 | */ | ||
| 31 | @Name("公司名称") | ||
| 32 | private String tenantName; | ||
| 33 | |||
| 34 | /** | ||
| 35 | * 统一社会信用代码 | ||
| 36 | */ | ||
| 37 | @Name("统一社会信用代码") | ||
| 38 | private String socialCreditCode; | ||
| 39 | |||
| 40 | /** | ||
| 41 | * 企业类型【选择平台字典【公司类型】的选项】 | ||
| 42 | */ | ||
| 43 | @Name("企业类型") | ||
| 44 | private String tenantType; | ||
| 45 | |||
| 46 | /** | ||
| 47 | * 注册日期 | ||
| 48 | */ | ||
| 49 | @Name("注册日期") | ||
| 50 | private Date registrationDate; | ||
| 51 | |||
| 52 | /** | ||
| 53 | * 注册资本【(万元)】 | ||
| 54 | */ | ||
| 55 | @Name("注册资本") | ||
| 56 | private BigDecimal registeredCapital; | ||
| 57 | |||
| 58 | /** | ||
| 59 | * 税号 | ||
| 60 | */ | ||
| 61 | @Name("税号") | ||
| 62 | private String bankTaxNo; | ||
| 63 | |||
| 64 | /** | ||
| 65 | * 省 | ||
| 66 | */ | ||
| 67 | @Name("省") | ||
| 68 | private String province; | ||
| 69 | |||
| 70 | /** | ||
| 71 | * 市 | ||
| 72 | */ | ||
| 73 | @Name("市") | ||
| 74 | private String city; | ||
| 75 | |||
| 76 | /** | ||
| 77 | * 区 | ||
| 78 | */ | ||
| 79 | @Name("区") | ||
| 80 | private String district; | ||
| 81 | |||
| 82 | /** | ||
| 83 | * 营业期限【1 长期有效;2 自定义】 | ||
| 84 | */ | ||
| 85 | @Name("营业期限") | ||
| 86 | private String businessLicenseTerm; | ||
| 87 | |||
| 88 | /** | ||
| 89 | * 营业开始日期 | ||
| 90 | */ | ||
| 91 | @Name("营业开始日期") | ||
| 92 | private Date businessLicenseStartDate; | ||
| 93 | |||
| 94 | /** | ||
| 95 | * 营业结束日期 | ||
| 96 | */ | ||
| 97 | @Name("营业结束日期") | ||
| 98 | private Date businessLicenseEndDate; | ||
| 99 | |||
| 100 | /** | ||
| 101 | * 营业执照 | ||
| 102 | */ | ||
| 103 | @Name("营业执照") | ||
| 104 | @TableField(updateStrategy = FieldStrategy.ALWAYS) | ||
| 105 | private String businessLicenseJson; | ||
| 106 | |||
| 107 | /** | ||
| 108 | * 营业执照经营范围 | ||
| 109 | */ | ||
| 110 | @Name("营业执照经营范围") | ||
| 111 | private String businessLicenseScope; | ||
| 112 | |||
| 113 | /** | ||
| 114 | * 公司法人 | ||
| 115 | */ | ||
| 116 | @Name("公司法人") | ||
| 117 | private String juridicalPerson; | ||
| 118 | |||
| 119 | /** | ||
| 120 | * 法人证件类型 | ||
| 121 | */ | ||
| 122 | @Name("法人证件类型") | ||
| 123 | private String juridicalPersonIdType; | ||
| 124 | |||
| 125 | /** | ||
| 126 | * 法人证件号 | ||
| 127 | */ | ||
| 128 | @Name("法人证件号") | ||
| 129 | private String juridicalPersonId; | ||
| 130 | |||
| 131 | /** | ||
| 132 | * 法人证件照 | ||
| 133 | */ | ||
| 134 | @Name("法人证件照") | ||
| 135 | @TableField(updateStrategy = FieldStrategy.ALWAYS) | ||
| 136 | private String juridicalPersonIdPhotoJson; | ||
| 137 | |||
| 138 | /** | ||
| 139 | * 登录账号 | ||
| 140 | */ | ||
| 141 | @Name("登录账号") | ||
| 142 | private String logonUser; | ||
| 143 | |||
| 144 | /** | ||
| 145 | * 联系人 | ||
| 146 | */ | ||
| 147 | @Name("联系人") | ||
| 148 | private String contacts; | ||
| 149 | |||
| 150 | /** | ||
| 151 | * 联系人电话 | ||
| 152 | */ | ||
| 153 | @Name("联系人电话") | ||
| 154 | private String contactTel; | ||
| 155 | |||
| 156 | /** | ||
| 157 | * 管理员证件号 | ||
| 158 | */ | ||
| 159 | @Name("管理员证件号") | ||
| 160 | private String managerPersonId; | ||
| 161 | |||
| 162 | /** | ||
| 163 | * 管理员证件照 | ||
| 164 | */ | ||
| 165 | @Name("管理员证件照") | ||
| 166 | @TableField(updateStrategy = FieldStrategy.ALWAYS) | ||
| 167 | private String managerPersonIdPhotoJson; | ||
| 168 | |||
| 169 | /** | ||
| 170 | * 授权委托书 | ||
| 171 | */ | ||
| 172 | @Name("授权委托书") | ||
| 173 | private String authorizationLetter; | ||
| 174 | |||
| 175 | /** | ||
| 176 | * 业务审批状态【N 草稿中,A 审批中,Y 已通过,R 驳回,C 已撤销,D 已废弃; 默认 N】 | ||
| 177 | */ | ||
| 178 | @Name("业务审批状态") | ||
| 179 | private String bizApproveState; | ||
| 180 | |||
| 181 | /** | ||
| 182 | * 审批流唯一标识 | ||
| 183 | */ | ||
| 184 | @Name("审批流唯一标识") | ||
| 185 | private String approveGuid; | ||
| 186 | |||
| 187 | /** | ||
| 188 | * 原数据唯一标识 | ||
| 189 | */ | ||
| 190 | @Name("原数据唯一标识") | ||
| 191 | private String sourceGuid; | ||
| 192 | |||
| 193 | @Name("资产Guid") | ||
| 194 | private String zqBizGuid; | ||
| 195 | |||
| 196 | @Name("专区名称") | ||
| 197 | private String zqName; | ||
| 198 | |||
| 199 | @Name("审批状态(N 初始 A 审批中 Y 已通过 R 驳回 C 已撤销)") | ||
| 200 | private String crossPlatformApproveState; | ||
| 201 | |||
| 202 | /** | ||
| 203 | * 数据类型【数据类型 1原数据 2新数据 0认证表数据】 | ||
| 204 | */ | ||
| 205 | @Name("数据类型") | ||
| 206 | private String dataType; | ||
| 207 | |||
| 208 | } |
| 1 | package com.csbr.qingcloud.portal.mybatis.entity; | ||
| 2 | |||
| 3 | import com.baomidou.mybatisplus.annotation.FieldStrategy; | ||
| 4 | import com.baomidou.mybatisplus.annotation.TableField; | ||
| 5 | import csbr.cloud.entity.domain.base.dao.BaseDO; | ||
| 6 | import jdk.jfr.Name; | ||
| 7 | import lombok.Data; | ||
| 8 | import lombok.EqualsAndHashCode; | ||
| 9 | import lombok.experimental.Accessors; | ||
| 10 | import java.util.Date; | ||
| 11 | |||
| 12 | /** | ||
| 13 | * @program: D:/git/ms-data-circulation-portal-service | ||
| 14 | * @description: 服务商维护实体 | ||
| 15 | * @author: xcq | ||
| 16 | * @create: 2024-12-31 18:49 | ||
| 17 | **/ | ||
| 18 | @Data | ||
| 19 | @EqualsAndHashCode(callSuper = true) | ||
| 20 | @Accessors(chain = true) | ||
| 21 | @Name("服务商维护") | ||
| 22 | public class MfServicerMaintain extends BaseDO { | ||
| 23 | |||
| 24 | /** | ||
| 25 | * 企业唯一标识 | ||
| 26 | */ | ||
| 27 | @Name("企业唯一标识") | ||
| 28 | private String tenantGuid; | ||
| 29 | |||
| 30 | /** | ||
| 31 | * 公司名称 | ||
| 32 | */ | ||
| 33 | @Name("公司名称") | ||
| 34 | private String tenantName; | ||
| 35 | |||
| 36 | /** | ||
| 37 | * 企业类型【选择平台字典【公司类型】的选项】 | ||
| 38 | */ | ||
| 39 | @Name("企业类型【选择平台字典【公司类型】的选项】") | ||
| 40 | private String tenantType; | ||
| 41 | |||
| 42 | /** | ||
| 43 | * 提交时间 | ||
| 44 | */ | ||
| 45 | @Name("提交时间") | ||
| 46 | private Date submitTime; | ||
| 47 | |||
| 48 | /** | ||
| 49 | * 联系人 | ||
| 50 | */ | ||
| 51 | @Name("联系人") | ||
| 52 | private String contacts; | ||
| 53 | |||
| 54 | /** | ||
| 55 | * 联系人电话 | ||
| 56 | */ | ||
| 57 | @Name("联系人电话") | ||
| 58 | private String contactTel; | ||
| 59 | |||
| 60 | /** | ||
| 61 | * 业务审批状态【N 草稿中,A 审批中,Y 已通过,R 驳回,C 已撤销,D 已废弃; 默认 N】 | ||
| 62 | */ | ||
| 63 | @Name("业务审批状态【N 草稿中,A 审批中,Y 已通过,R 驳回,C 已撤销,D 已废弃; 默认 N】") | ||
| 64 | private String bizApproveState; | ||
| 65 | |||
| 66 | /** | ||
| 67 | * 能否继续合作【Y 能;N 不能;】 | ||
| 68 | */ | ||
| 69 | @Name("能否继续合作【Y 能;N 不能;】") | ||
| 70 | private String canContinueCollaborate; | ||
| 71 | |||
| 72 | /** | ||
| 73 | * 维护信息 | ||
| 74 | */ | ||
| 75 | @Name("维护信息") | ||
| 76 | @TableField(updateStrategy = FieldStrategy.ALWAYS) | ||
| 77 | private String maintainJson; | ||
| 78 | |||
| 79 | } |
| 1 | package com.csbr.qingcloud.portal.mybatis.entity; | ||
| 2 | |||
| 3 | import csbr.cloud.entity.domain.base.dao.BaseDO; | ||
| 4 | import jdk.jfr.Name; | ||
| 5 | import lombok.Data; | ||
| 6 | import lombok.EqualsAndHashCode; | ||
| 7 | import lombok.experimental.Accessors; | ||
| 8 | import java.util.Date; | ||
| 9 | |||
| 10 | /** | ||
| 11 | * @program: D:/git/ms-data-circulation-portal-service | ||
| 12 | * @description: 服务商维护明细实体 | ||
| 13 | * @author: xcq | ||
| 14 | * @create: 2024-12-31 18:52 | ||
| 15 | **/ | ||
| 16 | @Data | ||
| 17 | @EqualsAndHashCode(callSuper = true) | ||
| 18 | @Accessors(chain = true) | ||
| 19 | @Name("服务商维护明细") | ||
| 20 | public class MfServicerMaintainDetail extends BaseDO { | ||
| 21 | |||
| 22 | /** | ||
| 23 | * 企业唯一标识 | ||
| 24 | */ | ||
| 25 | @Name("企业唯一标识") | ||
| 26 | private String tenantGuid; | ||
| 27 | |||
| 28 | /** | ||
| 29 | * 父唯一标识 | ||
| 30 | */ | ||
| 31 | @Name("父唯一标识") | ||
| 32 | private String parentGuid; | ||
| 33 | |||
| 34 | /** | ||
| 35 | * 字典唯一标识 | ||
| 36 | */ | ||
| 37 | @Name("字典唯一标识") | ||
| 38 | private String dicGuid; | ||
| 39 | |||
| 40 | /** | ||
| 41 | * 字典值 | ||
| 42 | */ | ||
| 43 | @Name("字典值") | ||
| 44 | private String dicValue; | ||
| 45 | |||
| 46 | } |
| 1 | package com.csbr.qingcloud.portal.mybatis.mapper; | ||
| 2 | |||
| 3 | import com.baomidou.mybatisplus.core.mapper.BaseMapper; | ||
| 4 | import org.apache.ibatis.annotations.Mapper; | ||
| 5 | import com.csbr.qingcloud.portal.mybatis.entity.MfDemand; | ||
| 6 | |||
| 7 | /** | ||
| 8 | * @program: D:/git/ms-data-circulation-portal-service | ||
| 9 | * @description: 数据需求 Mapper 接口 | ||
| 10 | * @author: xcq | ||
| 11 | * @create: 2024-12-31 18:46 | ||
| 12 | **/ | ||
| 13 | @Mapper | ||
| 14 | public interface MfDemandMapper extends BaseMapper<MfDemand> { | ||
| 15 | |||
| 16 | } |
src/main/java/com/csbr/qingcloud/portal/mybatis/mapper/MfEnterpriseChangeApproveMapper.java
0 → 100644
| 1 | package com.csbr.qingcloud.portal.mybatis.mapper; | ||
| 2 | |||
| 3 | import com.baomidou.mybatisplus.core.mapper.BaseMapper; | ||
| 4 | import org.apache.ibatis.annotations.Mapper; | ||
| 5 | import com.csbr.qingcloud.portal.mybatis.entity.MfEnterpriseChangeApprove; | ||
| 6 | |||
| 7 | /** | ||
| 8 | * @program: D:/git/ms-data-circulation-portal-service | ||
| 9 | * @description: 企业信息变更审批 Mapper 接口 | ||
| 10 | * @author: xcq | ||
| 11 | * @create: 2024-12-27 15:10 | ||
| 12 | **/ | ||
| 13 | @Mapper | ||
| 14 | public interface MfEnterpriseChangeApproveMapper extends BaseMapper<MfEnterpriseChangeApprove> { | ||
| 15 | |||
| 16 | } |
| 1 | package com.csbr.qingcloud.portal.mybatis.mapper; | ||
| 2 | |||
| 3 | import com.baomidou.mybatisplus.core.mapper.BaseMapper; | ||
| 4 | import org.apache.ibatis.annotations.Mapper; | ||
| 5 | import com.csbr.qingcloud.portal.mybatis.entity.MfEnterprise; | ||
| 6 | |||
| 7 | /** | ||
| 8 | * @program: D:/git/ms-data-circulation-portal-service | ||
| 9 | * @description: 企业信息 Mapper 接口 | ||
| 10 | * @author: xcq | ||
| 11 | * @create: 2024-12-26 16:18 | ||
| 12 | **/ | ||
| 13 | @Mapper | ||
| 14 | public interface MfEnterpriseMapper extends BaseMapper<MfEnterprise> { | ||
| 15 | |||
| 16 | } |
src/main/java/com/csbr/qingcloud/portal/mybatis/mapper/MfServicerMaintainDetailMapper.java
0 → 100644
| 1 | package com.csbr.qingcloud.portal.mybatis.mapper; | ||
| 2 | |||
| 3 | import com.baomidou.mybatisplus.core.mapper.BaseMapper; | ||
| 4 | import org.apache.ibatis.annotations.Mapper; | ||
| 5 | import com.csbr.qingcloud.portal.mybatis.entity.MfServicerMaintainDetail; | ||
| 6 | |||
| 7 | /** | ||
| 8 | * @program: D:/git/ms-data-circulation-portal-service | ||
| 9 | * @description: 服务商维护明细 Mapper 接口 | ||
| 10 | * @author: xcq | ||
| 11 | * @create: 2024-12-31 18:52 | ||
| 12 | **/ | ||
| 13 | @Mapper | ||
| 14 | public interface MfServicerMaintainDetailMapper extends BaseMapper<MfServicerMaintainDetail> { | ||
| 15 | |||
| 16 | } |
| 1 | package com.csbr.qingcloud.portal.mybatis.mapper; | ||
| 2 | |||
| 3 | import com.baomidou.mybatisplus.core.mapper.BaseMapper; | ||
| 4 | import org.apache.ibatis.annotations.Mapper; | ||
| 5 | import com.csbr.qingcloud.portal.mybatis.entity.MfServicerMaintain; | ||
| 6 | |||
| 7 | /** | ||
| 8 | * @program: D:/git/ms-data-circulation-portal-service | ||
| 9 | * @description: 服务商维护 Mapper 接口 | ||
| 10 | * @author: xcq | ||
| 11 | * @create: 2024-12-31 18:49 | ||
| 12 | **/ | ||
| 13 | @Mapper | ||
| 14 | public interface MfServicerMaintainMapper extends BaseMapper<MfServicerMaintain> { | ||
| 15 | |||
| 16 | } |
| 1 | package com.csbr.qingcloud.portal.mybatis.service; | ||
| 2 | |||
| 3 | import com.csbr.cloud.base.service.CsbrService; | ||
| 4 | import com.csbr.qingcloud.portal.mybatis.entity.MfDemand; | ||
| 5 | |||
| 6 | /** | ||
| 7 | * @program: D:/git/ms-data-circulation-portal-service | ||
| 8 | * @description: 数据需求逻辑层接口 | ||
| 9 | * @author: xcq | ||
| 10 | * @create: 2024-12-31 18:46 | ||
| 11 | **/ | ||
| 12 | public interface MfDemandService extends CsbrService<MfDemand> { | ||
| 13 | |||
| 14 | } |
src/main/java/com/csbr/qingcloud/portal/mybatis/service/MfEnterpriseChangeApproveService.java
0 → 100644
| 1 | package com.csbr.qingcloud.portal.mybatis.service; | ||
| 2 | |||
| 3 | import com.csbr.cloud.base.service.CsbrService; | ||
| 4 | import com.csbr.qingcloud.portal.mybatis.entity.MfEnterpriseChangeApprove; | ||
| 5 | |||
| 6 | /** | ||
| 7 | * @program: D:/git/ms-data-circulation-portal-service | ||
| 8 | * @description: 企业信息变更审批逻辑层接口 | ||
| 9 | * @author: xcq | ||
| 10 | * @create: 2024-12-27 15:10 | ||
| 11 | **/ | ||
| 12 | public interface MfEnterpriseChangeApproveService extends CsbrService<MfEnterpriseChangeApprove> { | ||
| 13 | |||
| 14 | } |
| 1 | package com.csbr.qingcloud.portal.mybatis.service; | ||
| 2 | |||
| 3 | import com.csbr.cloud.base.service.CsbrService; | ||
| 4 | import com.csbr.qingcloud.portal.mybatis.entity.MfEnterprise; | ||
| 5 | |||
| 6 | /** | ||
| 7 | * @program: D:/git/ms-data-circulation-portal-service | ||
| 8 | * @description: 企业信息逻辑层接口 | ||
| 9 | * @author: xcq | ||
| 10 | * @create: 2024-12-26 16:18 | ||
| 11 | **/ | ||
| 12 | public interface MfEnterpriseService extends CsbrService<MfEnterprise> { | ||
| 13 | |||
| 14 | } |
src/main/java/com/csbr/qingcloud/portal/mybatis/service/MfServicerMaintainDetailService.java
0 → 100644
| 1 | package com.csbr.qingcloud.portal.mybatis.service; | ||
| 2 | |||
| 3 | import com.csbr.cloud.base.service.CsbrService; | ||
| 4 | import com.csbr.qingcloud.portal.mybatis.entity.MfServicerMaintainDetail; | ||
| 5 | |||
| 6 | /** | ||
| 7 | * @program: D:/git/ms-data-circulation-portal-service | ||
| 8 | * @description: 服务商维护明细逻辑层接口 | ||
| 9 | * @author: xcq | ||
| 10 | * @create: 2024-12-31 18:52 | ||
| 11 | **/ | ||
| 12 | public interface MfServicerMaintainDetailService extends CsbrService<MfServicerMaintainDetail> { | ||
| 13 | |||
| 14 | } |
| 1 | package com.csbr.qingcloud.portal.mybatis.service; | ||
| 2 | |||
| 3 | import com.csbr.cloud.base.service.CsbrService; | ||
| 4 | import com.csbr.qingcloud.portal.mybatis.entity.MfServicerMaintain; | ||
| 5 | |||
| 6 | /** | ||
| 7 | * @program: D:/git/ms-data-circulation-portal-service | ||
| 8 | * @description: 服务商维护逻辑层接口 | ||
| 9 | * @author: xcq | ||
| 10 | * @create: 2024-12-31 18:49 | ||
| 11 | **/ | ||
| 12 | public interface MfServicerMaintainService extends CsbrService<MfServicerMaintain> { | ||
| 13 | |||
| 14 | } |
| 1 | package com.csbr.qingcloud.portal.mybatis.service.impl; | ||
| 2 | |||
| 3 | import com.csbr.cloud.mybatis.service.impl.CsbrServiceImpl; | ||
| 4 | import com.csbr.qingcloud.portal.mybatis.mapper.MfDemandMapper; | ||
| 5 | import com.csbr.qingcloud.portal.mybatis.entity.MfDemand; | ||
| 6 | import com.csbr.qingcloud.portal.mybatis.service.MfDemandService; | ||
| 7 | import jakarta.annotation.Resource; | ||
| 8 | import org.springframework.stereotype.Service; | ||
| 9 | |||
| 10 | /** | ||
| 11 | * @program: D:/git/ms-data-circulation-portal-service | ||
| 12 | * @description: 数据需求逻辑层接口实现 | ||
| 13 | * @author: xcq | ||
| 14 | * @create: 2024-12-31 18:46 | ||
| 15 | **/ | ||
| 16 | @Service | ||
| 17 | public class MfDemandServiceImpl extends CsbrServiceImpl<MfDemandMapper, MfDemand> implements MfDemandService { | ||
| 18 | |||
| 19 | @Resource | ||
| 20 | private MfDemandMapper mfDemandMapper; | ||
| 21 | |||
| 22 | } |
| 1 | package com.csbr.qingcloud.portal.mybatis.service.impl; | ||
| 2 | |||
| 3 | import com.baomidou.mybatisplus.core.conditions.query.LambdaQueryWrapper; | ||
| 4 | import com.baomidou.mybatisplus.core.toolkit.Wrappers; | ||
| 5 | import com.csbr.cloud.mybatis.service.impl.CsbrServiceImpl; | ||
| 6 | import com.csbr.qingcloud.portal.mybatis.entity.MfEnterprise; | ||
| 7 | import com.csbr.qingcloud.portal.mybatis.mapper.MfEnterpriseChangeApproveMapper; | ||
| 8 | import com.csbr.qingcloud.portal.mybatis.entity.MfEnterpriseChangeApprove; | ||
| 9 | import com.csbr.qingcloud.portal.mybatis.service.MfEnterpriseChangeApproveService; | ||
| 10 | import jakarta.annotation.Resource; | ||
| 11 | import org.springframework.stereotype.Service; | ||
| 12 | |||
| 13 | import java.io.Serializable; | ||
| 14 | import java.util.Collection; | ||
| 15 | import java.util.List; | ||
| 16 | |||
| 17 | /** | ||
| 18 | * @program: D:/git/ms-data-circulation-portal-service | ||
| 19 | * @description: 企业信息变更审批逻辑层接口实现 | ||
| 20 | * @author: xcq | ||
| 21 | * @create: 2024-12-27 15:10 | ||
| 22 | **/ | ||
| 23 | @Service | ||
| 24 | public class MfEnterpriseChangeApproveServiceImpl extends CsbrServiceImpl<MfEnterpriseChangeApproveMapper, MfEnterpriseChangeApprove> implements MfEnterpriseChangeApproveService { | ||
| 25 | |||
| 26 | @Resource | ||
| 27 | private MfEnterpriseChangeApproveMapper mfEnterpriseChangeApproveMapper; | ||
| 28 | |||
| 29 | @Override | ||
| 30 | public List<MfEnterpriseChangeApprove> listByIds(Collection<? extends Serializable> idList) { | ||
| 31 | LambdaQueryWrapper<MfEnterpriseChangeApprove> queryWrapper = Wrappers.lambdaQuery(MfEnterpriseChangeApprove.class); | ||
| 32 | queryWrapper.in(MfEnterpriseChangeApprove::getGuid, idList); | ||
| 33 | csbrExcludeShardingLambdaQueryWrapper(queryWrapper); | ||
| 34 | return list(queryWrapper); | ||
| 35 | } | ||
| 36 | |||
| 37 | } |
src/main/java/com/csbr/qingcloud/portal/mybatis/service/impl/MfEnterpriseServiceImpl.java
0 → 100644
| 1 | package com.csbr.qingcloud.portal.mybatis.service.impl; | ||
| 2 | |||
| 3 | import com.baomidou.mybatisplus.core.conditions.query.LambdaQueryWrapper; | ||
| 4 | import com.baomidou.mybatisplus.core.toolkit.Wrappers; | ||
| 5 | import com.csbr.cloud.mybatis.service.impl.CsbrServiceImpl; | ||
| 6 | import com.csbr.qingcloud.portal.mybatis.mapper.MfEnterpriseMapper; | ||
| 7 | import com.csbr.qingcloud.portal.mybatis.entity.MfEnterprise; | ||
| 8 | import com.csbr.qingcloud.portal.mybatis.service.MfEnterpriseService; | ||
| 9 | import jakarta.annotation.Resource; | ||
| 10 | import org.springframework.stereotype.Service; | ||
| 11 | |||
| 12 | import java.io.Serializable; | ||
| 13 | import java.util.Collection; | ||
| 14 | import java.util.List; | ||
| 15 | |||
| 16 | /** | ||
| 17 | * @program: D:/git/ms-data-circulation-portal-service | ||
| 18 | * @description: 企业信息逻辑层接口实现 | ||
| 19 | * @author: xcq | ||
| 20 | * @create: 2024-12-26 16:18 | ||
| 21 | **/ | ||
| 22 | @Service | ||
| 23 | public class MfEnterpriseServiceImpl extends CsbrServiceImpl<MfEnterpriseMapper, MfEnterprise> implements MfEnterpriseService { | ||
| 24 | |||
| 25 | @Resource | ||
| 26 | private MfEnterpriseMapper mfEnterpriseMapper; | ||
| 27 | |||
| 28 | @Override | ||
| 29 | public List<MfEnterprise> listByIds(Collection<? extends Serializable> idList) { | ||
| 30 | LambdaQueryWrapper<MfEnterprise> queryWrapper = Wrappers.lambdaQuery(MfEnterprise.class); | ||
| 31 | queryWrapper.in(MfEnterprise::getGuid, idList); | ||
| 32 | csbrExcludeShardingLambdaQueryWrapper(queryWrapper); | ||
| 33 | return list(queryWrapper); | ||
| 34 | } | ||
| 35 | } |
| 1 | package com.csbr.qingcloud.portal.mybatis.service.impl; | ||
| 2 | |||
| 3 | import com.csbr.cloud.mybatis.service.impl.CsbrServiceImpl; | ||
| 4 | import com.csbr.qingcloud.portal.mybatis.mapper.MfServicerMaintainDetailMapper; | ||
| 5 | import com.csbr.qingcloud.portal.mybatis.entity.MfServicerMaintainDetail; | ||
| 6 | import com.csbr.qingcloud.portal.mybatis.service.MfServicerMaintainDetailService; | ||
| 7 | import jakarta.annotation.Resource; | ||
| 8 | import org.springframework.stereotype.Service; | ||
| 9 | |||
| 10 | /** | ||
| 11 | * @program: D:/git/ms-data-circulation-portal-service | ||
| 12 | * @description: 服务商维护明细逻辑层接口实现 | ||
| 13 | * @author: xcq | ||
| 14 | * @create: 2024-12-31 18:52 | ||
| 15 | **/ | ||
| 16 | @Service | ||
| 17 | public class MfServicerMaintainDetailServiceImpl extends CsbrServiceImpl<MfServicerMaintainDetailMapper, MfServicerMaintainDetail> implements MfServicerMaintainDetailService { | ||
| 18 | |||
| 19 | @Resource | ||
| 20 | private MfServicerMaintainDetailMapper mfServicerMaintainDetailMapper; | ||
| 21 | |||
| 22 | } |
src/main/java/com/csbr/qingcloud/portal/mybatis/service/impl/MfServicerMaintainServiceImpl.java
0 → 100644
| 1 | package com.csbr.qingcloud.portal.mybatis.service.impl; | ||
| 2 | |||
| 3 | import com.csbr.cloud.mybatis.service.impl.CsbrServiceImpl; | ||
| 4 | import com.csbr.qingcloud.portal.mybatis.mapper.MfServicerMaintainMapper; | ||
| 5 | import com.csbr.qingcloud.portal.mybatis.entity.MfServicerMaintain; | ||
| 6 | import com.csbr.qingcloud.portal.mybatis.service.MfServicerMaintainService; | ||
| 7 | import jakarta.annotation.Resource; | ||
| 8 | import org.springframework.stereotype.Service; | ||
| 9 | |||
| 10 | /** | ||
| 11 | * @program: D:/git/ms-data-circulation-portal-service | ||
| 12 | * @description: 服务商维护逻辑层接口实现 | ||
| 13 | * @author: xcq | ||
| 14 | * @create: 2024-12-31 18:49 | ||
| 15 | **/ | ||
| 16 | @Service | ||
| 17 | public class MfServicerMaintainServiceImpl extends CsbrServiceImpl<MfServicerMaintainMapper, MfServicerMaintain> implements MfServicerMaintainService { | ||
| 18 | |||
| 19 | @Resource | ||
| 20 | private MfServicerMaintainMapper mfServicerMaintainMapper; | ||
| 21 | |||
| 22 | } |
| 1 | package com.csbr.qingcloud.portal.service; | ||
| 2 | |||
| 3 | import com.csbr.qingcloud.portal.domain.vo.*; | ||
| 4 | import csbr.cloud.entity.domain.base.vo.PageListVO; | ||
| 5 | import com.csbr.cloud.workflow.domain.dto.callback.BizCallbackDTO; | ||
| 6 | import com.csbr.cloud.workflow.domain.vo.appove.FlowRQBaseVO; | ||
| 7 | |||
| 8 | import java.util.List; | ||
| 9 | |||
| 10 | /** | ||
| 11 | * @program: D:/git/ms-data-circulation-portal-service | ||
| 12 | * @description: 数据需求业务逻辑接口 | ||
| 13 | * @author: xcq | ||
| 14 | * @create: 2024-12-31 18:46 | ||
| 15 | **/ | ||
| 16 | public interface DemandService { | ||
| 17 | |||
| 18 | /** | ||
| 19 | * 数据需求分页查询 | ||
| 20 | * @author xcq | ||
| 21 | * @date 2024-12-31 18:46 | ||
| 22 | * @param queryVO | ||
| 23 | * @return com.csbr.cloud.mybatis.entity.PageListVO<com.csbr.qingcloud.portal.domain.vo.DemandRSVO> | ||
| 24 | */ | ||
| 25 | PageListVO<DemandRSVO> pageList(DemandQueryVO queryVO); | ||
| 26 | |||
| 27 | /** | ||
| 28 | * 数据需求-门户分页 | ||
| 29 | * @param queryVO | ||
| 30 | * @return | ||
| 31 | */ | ||
| 32 | PageListVO<DemandPortalRSVO> portalPageList(DemandPortalQueryVO queryVO); | ||
| 33 | |||
| 34 | /** | ||
| 35 | * 数据需求获取详情数据 | ||
| 36 | * @author xcq | ||
| 37 | * @date 2024-12-31 18:46 | ||
| 38 | * @param guid | ||
| 39 | * @return com.csbr.qingcloud.portal.domain.vo.DemandRSVO | ||
| 40 | */ | ||
| 41 | DemandRSVO getDemandDetail(String guid); | ||
| 42 | |||
| 43 | /** | ||
| 44 | * 数据需求数据新增 | ||
| 45 | * @author xcq | ||
| 46 | * @date 2024-12-31 18:46 | ||
| 47 | * @param flowBaseVO | ||
| 48 | * @return void | ||
| 49 | */ | ||
| 50 | void saveDemand(FlowRQBaseVO flowBaseVO); | ||
| 51 | |||
| 52 | /** | ||
| 53 | * 数据需求数据修改 | ||
| 54 | * @author xcq | ||
| 55 | * @date 2024-12-31 18:46 | ||
| 56 | * @param flowBaseVO | ||
| 57 | * @return void | ||
| 58 | */ | ||
| 59 | void updateDemand(FlowRQBaseVO flowBaseVO); | ||
| 60 | |||
| 61 | /** | ||
| 62 | * 数据需求数据删除、并有相关的处理操作 | ||
| 63 | * @author xcq | ||
| 64 | * @date 2024-12-31 18:46 | ||
| 65 | * @param guids | ||
| 66 | * @return void | ||
| 67 | */ | ||
| 68 | void removeByGuids(List<String> guids); | ||
| 69 | |||
| 70 | /** | ||
| 71 | * 流程结束后进行业务回调 | ||
| 72 | * @author xcq | ||
| 73 | * @date 2024-12-31 18:46 | ||
| 74 | * @param dto | ||
| 75 | * @return void | ||
| 76 | */ | ||
| 77 | void flowCallBack(BizCallbackDTO dto); | ||
| 78 | |||
| 79 | /** | ||
| 80 | * 数据需求-流程结束后进行业务回调(跨服务审批) | ||
| 81 | * @param dto | ||
| 82 | */ | ||
| 83 | void crossFlowCallBack(BizCallbackDTO dto); | ||
| 84 | |||
| 85 | Boolean lastApprove(DemandApproveVO dto); | ||
| 86 | |||
| 87 | DemandRSVO getDemandDetailByProcess(String processOrderNo); | ||
| 88 | |||
| 89 | /** | ||
| 90 | * 根据加工单编号查询资产列表 | ||
| 91 | * @return | ||
| 92 | */ | ||
| 93 | List<ProcessOrderProcessDtlRSVO> listByProcessOrderNo(); | ||
| 94 | |||
| 95 | /** | ||
| 96 | * 数据需求-修改上架状态 | ||
| 97 | * @param vo | ||
| 98 | * @return | ||
| 99 | */ | ||
| 100 | Boolean updateGroundingPick(DemandRQVO vo); | ||
| 101 | } |
| 1 | package com.csbr.qingcloud.portal.service; | ||
| 2 | |||
| 3 | import com.csbr.cloud.workflow.domain.dto.callback.BizCallbackDTO; | ||
| 4 | import com.csbr.qingcloud.portal.domain.vo.ChangeApproveVO; | ||
| 5 | import com.csbr.qingcloud.portal.domain.vo.ChangeInfoVO; | ||
| 6 | import com.csbr.qingcloud.portal.domain.vo.EnterpriseRSVO; | ||
| 7 | |||
| 8 | import java.util.List; | ||
| 9 | |||
| 10 | /** | ||
| 11 | * @description: 供应商商品变更 | ||
| 12 | * @author: XiaoCQ | ||
| 13 | * @create: 2024-12-27 | ||
| 14 | **/ | ||
| 15 | public interface EnterpriseChangeApproveService { | ||
| 16 | void changeSave(ChangeApproveVO vo); | ||
| 17 | |||
| 18 | ChangeApproveVO changeDetail(String guid); | ||
| 19 | |||
| 20 | void changeUpdate(BizCallbackDTO dto); | ||
| 21 | |||
| 22 | void removeByGuids(List<String> guids); | ||
| 23 | |||
| 24 | void crossFlowCallBack(BizCallbackDTO dto); | ||
| 25 | |||
| 26 | void crossRemoveByBizGuid(List<String> zqBizGuids); | ||
| 27 | |||
| 28 | EnterpriseRSVO getEnterpriseChangeDetail(String guid); | ||
| 29 | } |
| 1 | package com.csbr.qingcloud.portal.service; | ||
| 2 | |||
| 3 | import com.csbr.cloud.workflow.domain.dto.appove.FlowQueryDTO; | ||
| 4 | import com.csbr.qingcloud.portal.domain.vo.*; | ||
| 5 | import com.csbr.qingcloud.portal.mybatis.entity.MfEnterprise; | ||
| 6 | import csbr.cloud.entity.domain.base.vo.PageListVO; | ||
| 7 | import com.csbr.cloud.workflow.domain.dto.callback.BizCallbackDTO; | ||
| 8 | import com.csbr.cloud.workflow.domain.vo.appove.FlowRQBaseVO; | ||
| 9 | |||
| 10 | import java.util.Date; | ||
| 11 | import java.util.List; | ||
| 12 | |||
| 13 | /** | ||
| 14 | * @program: D:/git/ms-data-circulation-portal-service | ||
| 15 | * @description: 企业信息业务逻辑接口 | ||
| 16 | * @author: xcq | ||
| 17 | * @create: 2024-12-26 16:18 | ||
| 18 | **/ | ||
| 19 | public interface EnterpriseService { | ||
| 20 | |||
| 21 | /** | ||
| 22 | * 企业信息分页查询 | ||
| 23 | * @author xcq | ||
| 24 | * @date 2024-12-26 16:18 | ||
| 25 | * @param queryVO | ||
| 26 | * @return com.csbr.cloud.mybatis.entity.PageListVO<com.csbr.qingcloud.portal.domain.vo.EnterpriseRSVO> | ||
| 27 | */ | ||
| 28 | PageListVO<EnterpriseRSVO> pageList(EnterpriseQueryVO queryVO); | ||
| 29 | |||
| 30 | /** | ||
| 31 | * 企业信息-分页(调用流程) | ||
| 32 | * @param dto | ||
| 33 | * @return | ||
| 34 | */ | ||
| 35 | PageListVO<EnterpriseApproveRSVO> flowPageList(FlowQueryDTO dto); | ||
| 36 | |||
| 37 | /** | ||
| 38 | * 企业信息获取详情数据 | ||
| 39 | * @author xcq | ||
| 40 | * @date 2024-12-26 16:18 | ||
| 41 | * @param guid | ||
| 42 | * @return com.csbr.qingcloud.portal.domain.vo.EnterpriseRSVO | ||
| 43 | */ | ||
| 44 | EnterpriseRSVO getEnterpriseDetail(String guid); | ||
| 45 | |||
| 46 | /** | ||
| 47 | * 企业信息数据新增 | ||
| 48 | * @author xcq | ||
| 49 | * @date 2024-12-26 16:18 | ||
| 50 | * @param flowBaseVO | ||
| 51 | * @return void | ||
| 52 | */ | ||
| 53 | void saveEnterprise(FlowRQBaseVO flowBaseVO); | ||
| 54 | |||
| 55 | /** | ||
| 56 | * 企业信息数据修改 | ||
| 57 | * @author xcq | ||
| 58 | * @date 2024-12-26 16:18 | ||
| 59 | * @param flowBaseVO | ||
| 60 | * @return void | ||
| 61 | */ | ||
| 62 | void updateEnterprise(FlowRQBaseVO flowBaseVO); | ||
| 63 | |||
| 64 | /** | ||
| 65 | * 企业信息数据删除、并有相关的处理操作 | ||
| 66 | * @author xcq | ||
| 67 | * @date 2024-12-26 16:18 | ||
| 68 | * @param guids | ||
| 69 | * @return void | ||
| 70 | */ | ||
| 71 | void removeByGuids(List<String> guids); | ||
| 72 | |||
| 73 | /** | ||
| 74 | * 流程结束后进行业务回调 | ||
| 75 | * @author xcq | ||
| 76 | * @date 2024-12-26 16:18 | ||
| 77 | * @param dto | ||
| 78 | * @return void | ||
| 79 | */ | ||
| 80 | void flowCallBack(BizCallbackDTO dto); | ||
| 81 | |||
| 82 | /** | ||
| 83 | * 流程结束后进行业务回调(跨服务审批) | ||
| 84 | * @param dto | ||
| 85 | */ | ||
| 86 | void crossFlowCallBack(BizCallbackDTO dto); | ||
| 87 | |||
| 88 | Boolean check(EnterpriseRQVO vo); | ||
| 89 | |||
| 90 | List<ChangeInfoVO> getChange(String sourceGuid, Date createTime); | ||
| 91 | |||
| 92 | List<ChangeInfoVO> beforeChangeList(String approveGuid); | ||
| 93 | |||
| 94 | EnterpriseRSVO getEnterpriseDetailByName(String tenantName); | ||
| 95 | |||
| 96 | /** 将此账号提交的数据需求迁移到新的企业 */ | ||
| 97 | void moveOldData(TenantRQVO vo); | ||
| 98 | |||
| 99 | /** 更新会员信息 */ | ||
| 100 | void updateTenant(MfEnterprise vo); | ||
| 101 | |||
| 102 | /** | ||
| 103 | * 企业信息-根据登陆账号查询详情 | ||
| 104 | * @param logonUser | ||
| 105 | * @return | ||
| 106 | */ | ||
| 107 | EnterpriseRSVO getEnterpriseDetailByLogonUser(String logonUser); | ||
| 108 | } |
| 1 | package com.csbr.qingcloud.portal.service; | ||
| 2 | |||
| 3 | import csbr.cloud.entity.domain.base.vo.PageListVO; | ||
| 4 | import com.csbr.cloud.workflow.domain.dto.callback.BizCallbackDTO; | ||
| 5 | import com.csbr.cloud.workflow.domain.vo.appove.FlowRQBaseVO; | ||
| 6 | import com.csbr.qingcloud.portal.domain.vo.ServicerMaintainQueryVO; | ||
| 7 | import com.csbr.qingcloud.portal.domain.vo.ServicerMaintainRSVO; | ||
| 8 | |||
| 9 | import java.util.List; | ||
| 10 | |||
| 11 | /** | ||
| 12 | * @program: D:/git/ms-data-circulation-portal-service | ||
| 13 | * @description: 服务商维护业务逻辑接口 | ||
| 14 | * @author: xcq | ||
| 15 | * @create: 2024-12-31 18:49 | ||
| 16 | **/ | ||
| 17 | public interface ServicerMaintainService { | ||
| 18 | |||
| 19 | /** | ||
| 20 | * 服务商维护分页查询 | ||
| 21 | * @author xcq | ||
| 22 | * @date 2024-12-31 18:49 | ||
| 23 | * @param queryVO | ||
| 24 | * @return com.csbr.cloud.mybatis.entity.PageListVO<com.csbr.qingcloud.portal.domain.vo.ServicerMaintainRSVO> | ||
| 25 | */ | ||
| 26 | PageListVO<ServicerMaintainRSVO> pageList(ServicerMaintainQueryVO queryVO); | ||
| 27 | |||
| 28 | /** | ||
| 29 | * 服务商维护获取详情数据 | ||
| 30 | * @author xcq | ||
| 31 | * @date 2024-12-31 18:49 | ||
| 32 | * @param guid | ||
| 33 | * @return com.csbr.qingcloud.portal.domain.vo.ServicerMaintainRSVO | ||
| 34 | */ | ||
| 35 | ServicerMaintainRSVO getServicerMaintainDetail(String guid); | ||
| 36 | |||
| 37 | /** | ||
| 38 | * 服务商维护数据新增 | ||
| 39 | * @author xcq | ||
| 40 | * @date 2024-12-31 18:49 | ||
| 41 | * @param flowBaseVO | ||
| 42 | * @return void | ||
| 43 | */ | ||
| 44 | void saveServicerMaintain(FlowRQBaseVO flowBaseVO); | ||
| 45 | |||
| 46 | /** | ||
| 47 | * 服务商维护数据修改 | ||
| 48 | * @author xcq | ||
| 49 | * @date 2024-12-31 18:49 | ||
| 50 | * @param flowBaseVO | ||
| 51 | * @return void | ||
| 52 | */ | ||
| 53 | void updateServicerMaintain(FlowRQBaseVO flowBaseVO); | ||
| 54 | |||
| 55 | /** | ||
| 56 | * 服务商维护数据删除、并有相关的处理操作 | ||
| 57 | * @author xcq | ||
| 58 | * @date 2024-12-31 18:49 | ||
| 59 | * @param guids | ||
| 60 | * @return void | ||
| 61 | */ | ||
| 62 | void removeByGuids(List<String> guids); | ||
| 63 | |||
| 64 | /** | ||
| 65 | * 流程结束后进行业务回调 | ||
| 66 | * @author xcq | ||
| 67 | * @date 2024-12-31 18:49 | ||
| 68 | * @param dto | ||
| 69 | * @return void | ||
| 70 | */ | ||
| 71 | void flowCallBack(BizCallbackDTO dto); | ||
| 72 | |||
| 73 | } |
| 1 | package com.csbr.qingcloud.portal.service.impl; | ||
| 2 | |||
| 3 | import com.alibaba.fastjson.JSON; | ||
| 4 | import com.alibaba.fastjson.JSONObject; | ||
| 5 | import com.baomidou.mybatisplus.core.conditions.query.LambdaQueryWrapper; | ||
| 6 | import com.baomidou.mybatisplus.core.conditions.update.LambdaUpdateWrapper; | ||
| 7 | import com.baomidou.mybatisplus.core.toolkit.Wrappers; | ||
| 8 | import com.csbr.cloud.common.enums.SystemError; | ||
| 9 | import com.csbr.cloud.common.enums.WorkFlowBizEnum; | ||
| 10 | import com.csbr.cloud.workflow.domain.dto.appove.FlowUpdateStateDTO; | ||
| 11 | import com.csbr.cloud.workflow.feign.WorkflowFeign; | ||
| 12 | import com.csbr.qingcloud.portal.domain.vo.*; | ||
| 13 | import com.csbr.qingcloud.portal.feign.ConfigureFeign; | ||
| 14 | import com.csbr.qingcloud.portal.feign.DataProcessBasicFeign; | ||
| 15 | import com.csbr.qingcloud.portal.feign.PersonelFeign; | ||
| 16 | import com.csbr.qingcloud.portal.util.DateUtil; | ||
| 17 | import com.csbr.qingcloud.portal.util.InvokeUtil; | ||
| 18 | import com.csbr.qingcloud.portal.util.ZQConfig; | ||
| 19 | import csbr.cloud.entity.domain.user.UserInfo; | ||
| 20 | import csbr.cloud.entity.enums.ApprovalStateEnum; | ||
| 21 | import com.csbr.cloud.common.exception.CsbrSystemException; | ||
| 22 | import com.csbr.cloud.common.util.CommonUtil; | ||
| 23 | import com.csbr.cloud.common.util.CsbrBeanUtil; | ||
| 24 | import com.csbr.cloud.workflow.util.ApprovalFlowUtil; | ||
| 25 | import com.csbr.cloud.workflow.util.FlowAbstractImpl; | ||
| 26 | import com.csbr.cloud.common.util.MessageSourceUtil; | ||
| 27 | import csbr.cloud.entity.domain.base.vo.PageListVO; | ||
| 28 | import com.csbr.cloud.workflow.domain.vo.appove.FlowRQBaseVO; | ||
| 29 | import com.csbr.cloud.workflow.domain.dto.appove.AddApprovalDTO; | ||
| 30 | import com.csbr.cloud.workflow.domain.dto.callback.BizCallbackDTO; | ||
| 31 | import com.csbr.qingcloud.portal.mybatis.entity.MfDemand; | ||
| 32 | import com.csbr.qingcloud.portal.mybatis.service.MfDemandService; | ||
| 33 | import com.csbr.qingcloud.portal.service.DemandService; | ||
| 34 | import csbr.cloud.entity.utils.UserContextHolder; | ||
| 35 | import jakarta.annotation.Resource; | ||
| 36 | import lombok.extern.slf4j.Slf4j; | ||
| 37 | import org.apache.commons.collections.CollectionUtils; | ||
| 38 | import org.apache.commons.lang3.ObjectUtils; | ||
| 39 | import org.apache.commons.lang3.StringUtils; | ||
| 40 | import org.springframework.beans.factory.annotation.Autowired; | ||
| 41 | import org.springframework.beans.factory.annotation.Value; | ||
| 42 | import org.springframework.stereotype.Service; | ||
| 43 | import io.seata.spring.annotation.GlobalTransactional; | ||
| 44 | import org.springframework.transaction.annotation.Transactional; | ||
| 45 | import java.util.*; | ||
| 46 | import java.util.stream.Collectors; | ||
| 47 | |||
| 48 | /** | ||
| 49 | * @program: D:/git/ms-data-circulation-portal-service | ||
| 50 | * @description: 数据需求业务逻辑实现 | ||
| 51 | * @author: xcq | ||
| 52 | * @create: 2024-12-31 18:46 | ||
| 53 | **/ | ||
| 54 | @Slf4j | ||
| 55 | @Service | ||
| 56 | public class DemandServiceImpl extends FlowAbstractImpl implements DemandService { | ||
| 57 | |||
| 58 | /** | ||
| 59 | * 功能名称 | ||
| 60 | */ | ||
| 61 | private static final String FUNCTION_NAME = "数据需求"; | ||
| 62 | |||
| 63 | private static final String SysFuncCode = "SJXQ"; | ||
| 64 | |||
| 65 | /** | ||
| 66 | * 流程类型 | ||
| 67 | */ | ||
| 68 | private static final String FLOW_TYPE = WorkFlowBizEnum.DATA_DEMAND.getValue(); | ||
| 69 | |||
| 70 | @Value("${isTenantAndHospital:false}") | ||
| 71 | private Boolean isTenantAndHospital; | ||
| 72 | |||
| 73 | @Autowired | ||
| 74 | private ZQConfig zqConfig; | ||
| 75 | |||
| 76 | @Autowired | ||
| 77 | private InvokeUtil invokeUtil; | ||
| 78 | |||
| 79 | @Resource | ||
| 80 | private MfDemandService mfDemandService; | ||
| 81 | |||
| 82 | @Resource | ||
| 83 | private ConfigureFeign configureFeign; | ||
| 84 | |||
| 85 | @Resource | ||
| 86 | private PersonelFeign personelFeign; | ||
| 87 | |||
| 88 | @Resource | ||
| 89 | private DataProcessBasicFeign dataProcessBasicFeign; | ||
| 90 | |||
| 91 | @Resource | ||
| 92 | private CsbrBeanUtil csbrBeanUtil; | ||
| 93 | |||
| 94 | @Resource | ||
| 95 | private ApprovalFlowUtil approvalFlowUtil; | ||
| 96 | |||
| 97 | @Resource | ||
| 98 | private MessageSourceUtil messageSourceUtil; | ||
| 99 | |||
| 100 | @Resource | ||
| 101 | private WorkflowFeign workflowFeign; | ||
| 102 | |||
| 103 | /** | ||
| 104 | * 数据需求分页查询 | ||
| 105 | * @author xcq | ||
| 106 | * @date 2024-12-31 18:46 | ||
| 107 | * @param queryVO | ||
| 108 | * @return com.csbr.cloud.mybatis.entity.PageListVO<com.csbr.qingcloud.portal.domain.vo.DemandRSVO> | ||
| 109 | */ | ||
| 110 | @Override | ||
| 111 | public PageListVO<DemandRSVO> pageList(DemandQueryVO queryVO) { | ||
| 112 | beforeQuery(queryVO); | ||
| 113 | if (queryVO.getIsNeedQuery()) { | ||
| 114 | LambdaQueryWrapper<MfDemand> queryWrapper = mfDemandService.csbrQueryWrapper(queryVO, MfDemand.class); | ||
| 115 | queryWrapper.in(CollectionUtils.isNotEmpty(queryVO.getGuidList()), MfDemand::getGuid,queryVO.getGuidList()); | ||
| 116 | queryWrapper.orderByDesc(MfDemand::getCreateTime); | ||
| 117 | mfDemandService.csbrExcludeShardingLambdaQueryWrapper(queryWrapper); | ||
| 118 | PageListVO<MfDemand> pageList = mfDemandService.csbrPageList(queryVO, queryWrapper); | ||
| 119 | PageListVO<DemandRSVO> rsPageList = csbrBeanUtil.convert(pageList, PageListVO.class); | ||
| 120 | afterQuery(pageList, rsPageList); | ||
| 121 | return rsPageList; | ||
| 122 | } | ||
| 123 | return new PageListVO<>(queryVO.getPageSize(), queryVO.getPageIndex()); | ||
| 124 | } | ||
| 125 | |||
| 126 | @Override | ||
| 127 | public PageListVO<DemandPortalRSVO> portalPageList(DemandPortalQueryVO queryVO) { | ||
| 128 | LambdaQueryWrapper<MfDemand> queryWrapper = mfDemandService.csbrQueryWrapper(queryVO, MfDemand.class); | ||
| 129 | queryWrapper.eq(MfDemand::getListingStatus, "Y").eq(MfDemand::getBizApproveState, "Y"); | ||
| 130 | queryWrapper.orderByDesc(MfDemand::getCreateTime); | ||
| 131 | mfDemandService.csbrExcludeShardingLambdaQueryWrapper(queryWrapper); | ||
| 132 | PageListVO<MfDemand> pageList = mfDemandService.csbrPageList(queryVO, queryWrapper); | ||
| 133 | PageListVO<DemandPortalRSVO> rsPageList = csbrBeanUtil.convert(pageList, PageListVO.class); | ||
| 134 | if(CollectionUtils.isNotEmpty(pageList.getRecords())){ | ||
| 135 | rsPageList.setRecords(csbrBeanUtil.convert(pageList.getRecords(), DemandPortalRSVO.class)); | ||
| 136 | } | ||
| 137 | return rsPageList; | ||
| 138 | } | ||
| 139 | |||
| 140 | /** | ||
| 141 | * 数据需求获取详情数据 | ||
| 142 | * @author xcq | ||
| 143 | * @date 2024-12-31 18:46 | ||
| 144 | * @param guid | ||
| 145 | * @return com.csbr.qingcloud.portal.domain.vo.DemandRSVO | ||
| 146 | */ | ||
| 147 | @Override | ||
| 148 | public DemandRSVO getDemandDetail(String guid) { | ||
| 149 | if (StringUtils.isBlank(guid)) { | ||
| 150 | // W00012 = {0}:参数[{1}]不能为空! | ||
| 151 | throw new CsbrSystemException(SystemError.DATA_INPUT_ERROR, messageSourceUtil.getMessage("W00010", | ||
| 152 | String.format("获取%s详情数据", FUNCTION_NAME), "数据唯一标识")); | ||
| 153 | } | ||
| 154 | MfDemand entity = mfDemandService.getById(guid); | ||
| 155 | if (entity == null) { | ||
| 156 | throw new CsbrSystemException(SystemError.DATA_NOT_EXISTS, messageSourceUtil.notExistsToSelectMessage(String.format("获取%s详情数据", FUNCTION_NAME))); | ||
| 157 | } | ||
| 158 | DemandRSVO demandRSVO = convertToVO(entity, getStateMap(Collections.singletonList(guid))); | ||
| 159 | |||
| 160 | // 补充业务产品名称 | ||
| 161 | String bizGuid = StringUtils.isNotEmpty(entity.getDataProductGuid()) ? entity.getDataProductGuid() : guid; | ||
| 162 | Map<String, DemandUpdateStateVO> data = dataProcessBasicFeign.getOrderStateAndBizName(Collections.singletonList(bizGuid)).getData(); | ||
| 163 | if (ObjectUtils.isNotEmpty(data)) { | ||
| 164 | DemandUpdateStateVO demandUpdateStateVO = data.get(bizGuid); | ||
| 165 | demandRSVO.setBizName(demandUpdateStateVO.getBizName()); | ||
| 166 | } | ||
| 167 | |||
| 168 | return demandRSVO; | ||
| 169 | } | ||
| 170 | |||
| 171 | private Map<String, DemandUpdateStateVO> getStateMap(List<String> guids){ | ||
| 172 | if(CollectionUtils.isEmpty(guids)){ | ||
| 173 | return null; | ||
| 174 | } | ||
| 175 | guids = guids.stream().filter(Objects::nonNull).collect(Collectors.toList()); | ||
| 176 | if(CollectionUtils.isEmpty(guids)){ | ||
| 177 | return null; | ||
| 178 | } | ||
| 179 | try{ | ||
| 180 | Map<String, DemandUpdateStateVO> map = dataProcessBasicFeign.getOrderState(guids).getData(); | ||
| 181 | return map; | ||
| 182 | }catch (Exception e){ | ||
| 183 | e.printStackTrace(); | ||
| 184 | return null; | ||
| 185 | } | ||
| 186 | } | ||
| 187 | |||
| 188 | /** | ||
| 189 | * 数据需求数据新增 | ||
| 190 | * @author xcq | ||
| 191 | * @date 2024-12-31 18:46 | ||
| 192 | * @param flowBaseVO | ||
| 193 | * @return void | ||
| 194 | */ | ||
| 195 | @GlobalTransactional(rollbackFor = Exception.class) | ||
| 196 | @Override | ||
| 197 | public void saveDemand(FlowRQBaseVO flowBaseVO) { | ||
| 198 | DemandRQVO rqVO = (DemandRQVO) flowBaseVO; | ||
| 199 | beforeSave(rqVO); | ||
| 200 | MfDemand entity = convertToEntity(rqVO); | ||
| 201 | entity.setRequirementOrderNo(configureFeign.newCode(new RuleDTO().setRuleName("demand-code").setRuleType("generate")).getData()); | ||
| 202 | // 发起审批流程或保存草稿 | ||
| 203 | AddApprovalDTO approvalDTO = getAddApprovalDTO(entity, rqVO); | ||
| 204 | super.startWorkFlow(rqVO, approvalDTO, entity::setBizApproveState); | ||
| 205 | // 业务数据保存 | ||
| 206 | boolean flag = mfDemandService.save(entity); | ||
| 207 | if (!flag) { | ||
| 208 | throw new CsbrSystemException(SystemError.DATA_ADD_ERROR, rqVO.getImmediateApprove() ? | ||
| 209 | messageSourceUtil.submitMessage(FUNCTION_NAME) : messageSourceUtil.addMessage(FUNCTION_NAME)); | ||
| 210 | } | ||
| 211 | afterSave(entity, rqVO); | ||
| 212 | } | ||
| 213 | |||
| 214 | private void checkProductGuid(String dataProductGuid){ | ||
| 215 | if (StringUtils.isBlank(dataProductGuid)) { | ||
| 216 | throw new CsbrSystemException(SystemError.DATA_INPUT_ERROR, "产品不能为空"); | ||
| 217 | } | ||
| 218 | //此产品审批中的需求只能有1个 | ||
| 219 | LambdaQueryWrapper<MfDemand> wrapper = new LambdaQueryWrapper<>(); | ||
| 220 | wrapper.eq(MfDemand::getDataProductGuid,dataProductGuid); | ||
| 221 | wrapper.eq(MfDemand::getBizApproveState,"A"); | ||
| 222 | List<MfDemand> list = mfDemandService.list(wrapper); | ||
| 223 | if(CollectionUtils.isNotEmpty(list)){ | ||
| 224 | throw new CsbrSystemException(SystemError.DATA_INPUT_ERROR, "该数据产品已在审批中,请勿重复提交!"); | ||
| 225 | } | ||
| 226 | } | ||
| 227 | |||
| 228 | /** | ||
| 229 | * 数据需求数据修改 | ||
| 230 | * @author xcq | ||
| 231 | * @date 2024-12-31 18:46 | ||
| 232 | * @param flowBaseVO | ||
| 233 | * @return void | ||
| 234 | */ | ||
| 235 | @GlobalTransactional(rollbackFor = Exception.class) | ||
| 236 | @Transactional(rollbackFor = Exception.class) | ||
| 237 | @Override | ||
| 238 | public void updateDemand(FlowRQBaseVO flowBaseVO) { | ||
| 239 | DemandRQVO rqVO = (DemandRQVO) flowBaseVO; | ||
| 240 | // 将修改前数据查出来缓存下来,传入到修改后方法中,用于一些特殊逻辑处理,如某个值变化才进行 | ||
| 241 | // MfDemand oldEntity = mfDemandService.getById(rqVO.getGuid()); | ||
| 242 | beforeUpdate(rqVO); | ||
| 243 | MfDemand entity = convertToEntity(rqVO); | ||
| 244 | // 发起审批流程或保存草稿 | ||
| 245 | AddApprovalDTO approvalDTO = getAddApprovalDTO(entity, rqVO); | ||
| 246 | super.restartWorkFlow(rqVO, rqVO.getBizApproveState(), approvalDTO, this::saveDemand, entity::setBizApproveState); | ||
| 247 | if (Boolean.FALSE.equals(rqVO.getIsRestart())) { | ||
| 248 | // 修改业务数据 | ||
| 249 | mfDemandService.updateById(entity); | ||
| 250 | afterUpdate(entity, rqVO); | ||
| 251 | } | ||
| 252 | } | ||
| 253 | |||
| 254 | /** | ||
| 255 | * 重新提交数据需求 | ||
| 256 | * @author xcq | ||
| 257 | * @date 2025-02-17 18:16 | ||
| 258 | * @param entity | ||
| 259 | * @param rqVO | ||
| 260 | * @param approvalDTO | ||
| 261 | * @return void | ||
| 262 | */ | ||
| 263 | private void againSubmitFlow(MfDemand entity, DemandRQVO rqVO, AddApprovalDTO approvalDTO) { | ||
| 264 | entity.setGuid(CommonUtil.newGuid()); | ||
| 265 | mfDemandService.csbrBaseEntity(entity); | ||
| 266 | entity.setBizApproveState("A"); | ||
| 267 | // 保存新数据 | ||
| 268 | boolean flag = mfDemandService.save(entity); | ||
| 269 | if (!flag) { | ||
| 270 | throw new CsbrSystemException(SystemError.DATA_ADD_ERROR, messageSourceUtil.addMessage(String.format("重新提交%s",FUNCTION_NAME))); | ||
| 271 | } | ||
| 272 | // 发起新的流程 | ||
| 273 | approvalDTO.setBizGuid(entity.getGuid()); | ||
| 274 | approvalDTO.setUrlParam(String.format("guid=%s&demandCategory=%s&name=%s&type=detail", entity.getGuid(), entity.getDemandCategory(), entity.getDataDemandName())); | ||
| 275 | approvalFlowUtil.addApproval(approvalDTO); | ||
| 276 | afterSave(entity, rqVO); | ||
| 277 | } | ||
| 278 | |||
| 279 | /** | ||
| 280 | * 数据需求数据删除、并有相关的处理操作 | ||
| 281 | * @author xcq | ||
| 282 | * @date 2024-12-31 18:46 | ||
| 283 | * @param guids | ||
| 284 | * @return void | ||
| 285 | */ | ||
| 286 | @GlobalTransactional(rollbackFor = Exception.class) | ||
| 287 | @Override | ||
| 288 | public void removeByGuids(List<String> guids) { | ||
| 289 | if (CollectionUtils.isEmpty(guids)) { | ||
| 290 | // W00012 = {0}:参数[{1}]不能为空! | ||
| 291 | throw new CsbrSystemException(SystemError.DATA_INPUT_ERROR, messageSourceUtil.getMessage("W00012", | ||
| 292 | String.format("删除%s数据", FUNCTION_NAME), "数据唯一标识")); | ||
| 293 | } | ||
| 294 | String crossPlatformApproveState = ""; | ||
| 295 | for (String guid : guids) { | ||
| 296 | MfDemand entity = mfDemandService.getById(guid); | ||
| 297 | if (entity == null) { | ||
| 298 | continue; | ||
| 299 | } | ||
| 300 | if (ApprovalStateEnum.CHECKING.getValue().equals(entity.getBizApproveState()) || | ||
| 301 | (ApprovalStateEnum.PASSED.getValue().equals(entity.getBizApproveState()) && "Y".equals(entity.getListingStatus()))) { | ||
| 302 | throw new CsbrSystemException(SystemError.DATA_DEL_ERROR, "审批中和审批通过的数据不能删除!"); | ||
| 303 | } | ||
| 304 | mfDemandService.removeById(entity); | ||
| 305 | afterRemove(entity); | ||
| 306 | crossPlatformApproveState = entity.getCrossPlatformApproveState(); | ||
| 307 | } | ||
| 308 | // 删除流程数据 | ||
| 309 | approvalFlowUtil.removeApproveByBizGuids(guids); | ||
| 310 | |||
| 311 | // 删除主平台数据 | ||
| 312 | if (!zqConfig.getIsMain() && StringUtils.isNotEmpty(crossPlatformApproveState)) { | ||
| 313 | JSONObject jsonObject = new JSONObject(); | ||
| 314 | jsonObject.put("zqSystemCode", SysFuncCode); | ||
| 315 | jsonObject.put("zqBizGuids", JSON.toJSONString(guids)); | ||
| 316 | jsonObject.put("isCollection", true); | ||
| 317 | invokeUtil.invokeMainDel(jsonObject, zqConfig.getAppKey(), zqConfig.getZqDelUrl()); | ||
| 318 | } | ||
| 319 | } | ||
| 320 | |||
| 321 | /** | ||
| 322 | * 流程结束后进行业务回调 | ||
| 323 | * @author xcq | ||
| 324 | * @date 2024-12-31 18:46 | ||
| 325 | * @return void | ||
| 326 | */ | ||
| 327 | @Transactional(rollbackFor = Exception.class) | ||
| 328 | @Override | ||
| 329 | public void flowCallBack(BizCallbackDTO dto) { | ||
| 330 | MfDemand entity = mfDemandService.getById(dto.getBizGuid()); | ||
| 331 | if (entity == null) { | ||
| 332 | throw new CsbrSystemException(SystemError.DATA_NOT_EXISTS, messageSourceUtil.notExistsToSelectMessage(FUNCTION_NAME)); | ||
| 333 | } | ||
| 334 | String orderNo = null; | ||
| 335 | LambdaUpdateWrapper<MfDemand> updateWrapper = new LambdaUpdateWrapper<>(); | ||
| 336 | if (ApprovalStateEnum.PASSED.getValue().equals(dto.getApprovalState()) && !dto.getIsZqPlatformApprove()) { | ||
| 337 | if (StringUtils.isEmpty(entity.getZqName())) { | ||
| 338 | //生成加工单 | ||
| 339 | orderNo = addOrder(mfDemandService.getById(dto.getBizGuid()),dto); | ||
| 340 | } | ||
| 341 | |||
| 342 | // 判断是否审核自动上架 | ||
| 343 | if (!isTenantAndHospital) { | ||
| 344 | updateWrapper.set(MfDemand::getListingStatus, "Y"); | ||
| 345 | } | ||
| 346 | } | ||
| 347 | // 同步更新审批状态 | ||
| 348 | updateWrapper.set(MfDemand::getBizApproveState, dto.getApprovalState()); | ||
| 349 | updateWrapper.set(StringUtils.isNotBlank(orderNo),MfDemand::getProcessOrderNo, orderNo); | ||
| 350 | updateWrapper.set(StringUtils.isNotBlank(orderNo),MfDemand::getProcessingGenerateTime, new Date()); | ||
| 351 | updateWrapper.eq(MfDemand::getGuid, dto.getBizGuid()); | ||
| 352 | boolean flag = mfDemandService.update(updateWrapper); | ||
| 353 | if (!flag) { | ||
| 354 | throw new CsbrSystemException(SystemError.DATA_UPDATE_ERROR, messageSourceUtil.updateMessage(String.format("%s的业务审批状态", FUNCTION_NAME))); | ||
| 355 | } | ||
| 356 | } | ||
| 357 | |||
| 358 | @Override | ||
| 359 | public void crossFlowCallBack(BizCallbackDTO dto) { | ||
| 360 | MfDemand entity = mfDemandService.getById(dto.getBizGuid()); | ||
| 361 | if (entity == null) { | ||
| 362 | throw new CsbrSystemException(SystemError.DATA_NOT_EXISTS, messageSourceUtil.notExistsToSelectMessage(FUNCTION_NAME)); | ||
| 363 | } | ||
| 364 | String orderNo = null; | ||
| 365 | LambdaUpdateWrapper<MfDemand> updateWrapper = new LambdaUpdateWrapper<>(); | ||
| 366 | if (ApprovalStateEnum.PASSED.getValue().equals(dto.getApprovalState())) { | ||
| 367 | //生成加工单 | ||
| 368 | orderNo = addOrder(mfDemandService.getById(dto.getBizGuid()),dto); | ||
| 369 | // 判断是否审核自动上架 | ||
| 370 | if (!isTenantAndHospital) { | ||
| 371 | updateWrapper.set(MfDemand::getListingStatus, "Y"); | ||
| 372 | } | ||
| 373 | } | ||
| 374 | // 同步更新审批状态 | ||
| 375 | updateWrapper.set(MfDemand::getBizApproveState, dto.getApprovalState()); | ||
| 376 | updateWrapper.set(MfDemand::getCrossPlatformApproveState, dto.getApprovalState()); | ||
| 377 | updateWrapper.set(StringUtils.isNotBlank(orderNo),MfDemand::getProcessOrderNo, orderNo); | ||
| 378 | updateWrapper.set(StringUtils.isNotBlank(orderNo),MfDemand::getProcessingGenerateTime, new Date()); | ||
| 379 | updateWrapper.eq(MfDemand::getGuid, dto.getBizGuid()); | ||
| 380 | boolean flag = mfDemandService.update(updateWrapper); | ||
| 381 | if (!flag) { | ||
| 382 | throw new CsbrSystemException(SystemError.DATA_UPDATE_ERROR, messageSourceUtil.updateMessage(String.format("%s的业务审批状态", FUNCTION_NAME))); | ||
| 383 | } | ||
| 384 | } | ||
| 385 | |||
| 386 | private String addOrder(MfDemand bean,BizCallbackDTO dto){ | ||
| 387 | ProcessOrderRQVO vo = csbrBeanUtil.convert(bean,ProcessOrderRQVO.class); | ||
| 388 | vo.setGuid(bean.getGuid()); | ||
| 389 | vo.setTenantName(personelFeign.getAllTenantGuidNameMap().getData().get(bean.getTenantGuid())); | ||
| 390 | vo.setRequirementOrderNo(bean.getRequirementOrderNo()); | ||
| 391 | vo.setProcessOrderNo(configureFeign.newCode(new RuleDTO().setRuleName("process-order-code").setRuleType("generate")).getData()); | ||
| 392 | vo.setAcceptanceOrderNo(configureFeign.newCode(new RuleDTO().setRuleName("acceptance-order-code").setRuleType("generate")).getData()); | ||
| 393 | vo.setRequirementOrderName(bean.getDataDemandName()); | ||
| 394 | vo.setApplicationSceneDesc(bean.getSceneDescription()); | ||
| 395 | vo.setProcessState("N"); | ||
| 396 | vo.setContactTel(bean.getContactInformation()); | ||
| 397 | vo.setLinkContractInfoJson(bean.getContractAttachJson()); | ||
| 398 | vo.setProcessCompanyType(bean.getProcessCompanyType()); | ||
| 399 | if("人员".equals(bean.getProcessCompanyType())){ | ||
| 400 | vo.setProcessStaffGuid(bean.getProcessCompanyGuid()); | ||
| 401 | } | ||
| 402 | else if("公司".equals(bean.getProcessCompanyType())){ | ||
| 403 | vo.setProcessCompanyGuid(bean.getProcessCompanyGuid()); | ||
| 404 | } | ||
| 405 | vo.setFileUrl(bean.getDataDemandFieldAttachJson()); | ||
| 406 | |||
| 407 | UserInfo user = UserContextHolder.get(); | ||
| 408 | vo.setAcceptanceNameGuid(dto.getStaffGuid()); | ||
| 409 | vo.setAcceptanceName(user.getUserName()); | ||
| 410 | vo.setAcceptanceDate(new Date()); | ||
| 411 | vo.setAcceptanceReason(dto.getApproveSuggest()); | ||
| 412 | vo.setRequestPath(bean.getRequestType()); | ||
| 413 | |||
| 414 | dataProcessBasicFeign.saveProcessOrder(vo); | ||
| 415 | return vo.getProcessOrderNo(); | ||
| 416 | } | ||
| 417 | |||
| 418 | @GlobalTransactional | ||
| 419 | @Override | ||
| 420 | public Boolean lastApprove(DemandApproveVO dto) { | ||
| 421 | MfDemand entity = mfDemandService.getById(dto.getBizGuid()); | ||
| 422 | entity.setContractAttachJson(dto.getContractAttachJson()); | ||
| 423 | entity.setProcessCompanyType(dto.getProcessCompanyType()); | ||
| 424 | entity.setProcessCompanyGuid(dto.getProcessCompanyGuid()); | ||
| 425 | entity.setProcessCompanyName(dto.getProcessCompanyName()); | ||
| 426 | mfDemandService.updateById(entity); | ||
| 427 | FlowUpdateStateDTO flowDTO = csbrBeanUtil.convert(dto,FlowUpdateStateDTO.class); | ||
| 428 | MfDemand demand = new MfDemand(); | ||
| 429 | demand.setContractAttachJson(entity.getContractAttachJson()); | ||
| 430 | demand.setProcessCompanyType(entity.getProcessCompanyType()); | ||
| 431 | demand.setProcessCompanyGuid(entity.getProcessCompanyGuid()); | ||
| 432 | demand.setProcessCompanyName(entity.getProcessCompanyName()); | ||
| 433 | flowDTO.setBizData(JSON.toJSONString(demand)); | ||
| 434 | flowDTO.setBackEndInvoke(true); | ||
| 435 | workflowFeign.allowFlowCore(flowDTO).getData(); | ||
| 436 | |||
| 437 | return true; | ||
| 438 | } | ||
| 439 | |||
| 440 | @Override | ||
| 441 | public DemandRSVO getDemandDetailByProcess(String processOrderNo) { | ||
| 442 | LambdaQueryWrapper<MfDemand> queryWrapper = new LambdaQueryWrapper<>(); | ||
| 443 | queryWrapper.eq(MfDemand::getProcessOrderNo,processOrderNo); | ||
| 444 | List<MfDemand> list = mfDemandService.list(queryWrapper); | ||
| 445 | if(CollectionUtils.isEmpty(list)){ | ||
| 446 | return null; | ||
| 447 | } | ||
| 448 | return convertToVO(list.get(0),getStateMap(Collections.singletonList(list.get(0).getGuid()))); | ||
| 449 | } | ||
| 450 | |||
| 451 | @Override | ||
| 452 | public List<ProcessOrderProcessDtlRSVO> listByProcessOrderNo() { | ||
| 453 | LambdaQueryWrapper<MfDemand> queryWrapper = Wrappers.lambdaQuery(MfDemand.class); | ||
| 454 | queryWrapper.isNotNull(MfDemand::getRequirementOrderNo).isNotNull(MfDemand::getProcessOrderNo); | ||
| 455 | queryWrapper.orderByDesc(MfDemand::getCreateTime); | ||
| 456 | List<MfDemand> mfDemands = mfDemandService.list(queryWrapper); | ||
| 457 | if (ObjectUtils.isEmpty(mfDemands)) { | ||
| 458 | return null; | ||
| 459 | } | ||
| 460 | List<String> guids = mfDemands.stream().map(MfDemand::getGuid).toList(); | ||
| 461 | return dataProcessBasicFeign.processOrderList(guids).getData(); | ||
| 462 | } | ||
| 463 | |||
| 464 | @Override | ||
| 465 | public Boolean updateGroundingPick(DemandRQVO vo) { | ||
| 466 | |||
| 467 | MfDemand mfDemand = mfDemandService.getById(vo.getGuid()); | ||
| 468 | if (ObjectUtils.isEmpty(mfDemand)) { | ||
| 469 | return Boolean.FALSE; | ||
| 470 | } | ||
| 471 | |||
| 472 | LambdaUpdateWrapper<MfDemand> updateWrapper = Wrappers.lambdaUpdate(); | ||
| 473 | updateWrapper.eq(MfDemand::getGuid, vo.getGuid()) | ||
| 474 | .set(MfDemand::getListingStatus, vo.getListingStatus()); | ||
| 475 | mfDemandService.update(updateWrapper); | ||
| 476 | |||
| 477 | // 下架主平台数据 | ||
| 478 | if (!zqConfig.getIsMain() && StringUtils.isNotEmpty(mfDemand.getCrossPlatformApproveState())) { | ||
| 479 | JSONObject jsonObject = new JSONObject(); | ||
| 480 | jsonObject.put("zqSystemCode", SysFuncCode); | ||
| 481 | jsonObject.put("guid", vo.getGuid()); | ||
| 482 | jsonObject.put("listingStatus", vo.getListingStatus()); | ||
| 483 | invokeUtil.invokeMainDel(jsonObject, zqConfig.getAppKey(), zqConfig.getGroundingPickUrl()); | ||
| 484 | } | ||
| 485 | return Boolean.TRUE; | ||
| 486 | } | ||
| 487 | |||
| 488 | /** | ||
| 489 | * 获取发起流程参数 | ||
| 490 | * | ||
| 491 | * @param entity | ||
| 492 | * @param rqVO | ||
| 493 | * @return com.csbr.cloud.workflow.domain.dto.appove.AddApprovalDTO | ||
| 494 | * @author xcq | ||
| 495 | * @date 2024-12-31 18:46 | ||
| 496 | */ | ||
| 497 | private AddApprovalDTO getAddApprovalDTO(MfDemand entity, DemandRQVO rqVO) { | ||
| 498 | AddApprovalDTO approvalDTO = new AddApprovalDTO(FLOW_TYPE, entity.getGuid()); | ||
| 499 | // todo | ||
| 500 | approvalDTO.setFuncCode(SysFuncCode); | ||
| 501 | approvalDTO.setUrlParam(String.format("guid=%s&demandCategory=%s&name=%s&type=detail", entity.getGuid(), entity.getDemandCategory(), entity.getDataDemandName())); | ||
| 502 | // 流程消息中的变量替换参数 | ||
| 503 | approvalDTO.setFlowMessageBody(String.format("%s,%s", CommonUtil.getUserInfo().getUserName(),entity.getDataDemandName())); | ||
| 504 | // 流程列表数据核心param参数处理 | ||
| 505 | approvalDTO.setParam1(entity.getDataDemandName()); | ||
| 506 | approvalDTO.setParam2(null); | ||
| 507 | approvalDTO.setParam3(null); | ||
| 508 | approvalDTO.setParam4(null); | ||
| 509 | |||
| 510 | // 增加跨服务审批字段 | ||
| 511 | rqVO.setGuid(entity.getGuid()); | ||
| 512 | approvalDTO.setBizData(JSON.toJSONString(rqVO)); | ||
| 513 | |||
| 514 | return approvalDTO; | ||
| 515 | } | ||
| 516 | |||
| 517 | /** | ||
| 518 | * 数据需求新新增前置处理 | ||
| 519 | * @author xcq | ||
| 520 | * @date 2024-12-31 18:46 | ||
| 521 | * @param rqVO | ||
| 522 | * @return void | ||
| 523 | */ | ||
| 524 | private void beforeSave(DemandRQVO rqVO) { | ||
| 525 | //region 1.输入基础验证 | ||
| 526 | //endregion | ||
| 527 | |||
| 528 | //region 2.数据验证特殊处理 | ||
| 529 | //region 2.1.业务合规性验证 | ||
| 530 | //endregion 2.1.业务合规性验证 | ||
| 531 | |||
| 532 | //region 2.2.业务数据验证 | ||
| 533 | if(rqVO.getImmediateApprove() && "2".equals(rqVO.getDemandCategory())){ | ||
| 534 | checkProductGuid(rqVO.getDataProductGuid()); | ||
| 535 | } | ||
| 536 | //endregion 2.2.业务数据验证 | ||
| 537 | if (!isTenantAndHospital) { | ||
| 538 | rqVO.setListingStatus("N"); | ||
| 539 | } | ||
| 540 | |||
| 541 | //endregion 2.数据验证特殊处理 | ||
| 542 | |||
| 543 | //region 3.数据转换处理 | ||
| 544 | |||
| 545 | //region 3.1.数据过程转换 | ||
| 546 | //endregion 3.1.数据过程转换 | ||
| 547 | |||
| 548 | //endregion 3.数据转换处理 | ||
| 549 | |||
| 550 | //region 4.数据过滤与补充处理 | ||
| 551 | |||
| 552 | //endregion 4.数据过滤与补充处理 | ||
| 553 | |||
| 554 | //region 5.过程处理 | ||
| 555 | |||
| 556 | //region 5.1.计算逻辑处理 | ||
| 557 | //endregion 5.1.计算逻辑处理 | ||
| 558 | |||
| 559 | //region 5.2.业务逻辑处理 | ||
| 560 | //endregion 5.2.业务逻辑处理 | ||
| 561 | |||
| 562 | //endregion 5.过程处理 | ||
| 563 | } | ||
| 564 | |||
| 565 | /** | ||
| 566 | * 数据需求新增后置处理 | ||
| 567 | * @author xcq | ||
| 568 | * @date 2024-12-31 18:46 | ||
| 569 | * @param entity | ||
| 570 | * @param rqVO | ||
| 571 | * @return void | ||
| 572 | */ | ||
| 573 | private void afterSave(MfDemand entity, DemandRQVO rqVO) { | ||
| 574 | //region 1.输出特殊转换 | ||
| 575 | |||
| 576 | //region 1.1.输出过滤与补充处理 | ||
| 577 | //endregion 1.1.输出过滤与补充处理 | ||
| 578 | |||
| 579 | //endregion 1.输出特殊转换 | ||
| 580 | } | ||
| 581 | |||
| 582 | /** | ||
| 583 | * 数据需求修改前置校验、处理 | ||
| 584 | * @author xcq | ||
| 585 | * @date 2024-12-31 18:46 | ||
| 586 | * @param rqVO | ||
| 587 | * @return void | ||
| 588 | */ | ||
| 589 | private void beforeUpdate(DemandRQVO rqVO) { | ||
| 590 | //region 1.输入基础验证 | ||
| 591 | if (StringUtils.isBlank(rqVO.getGuid())) { | ||
| 592 | // W00012 = {0}:参数[{1}]不能为空! | ||
| 593 | throw new CsbrSystemException(SystemError.DATA_INPUT_ERROR, messageSourceUtil.getMessage("W00010", String.format("修改%s数据",FUNCTION_NAME), "数据唯一标识")); | ||
| 594 | } | ||
| 595 | //endregion | ||
| 596 | |||
| 597 | //region 2.数据验证特殊处理 | ||
| 598 | //region 2.1.业务合规性验证 | ||
| 599 | //endregion 2.1.业务合规性验证 | ||
| 600 | |||
| 601 | //region 2.2.业务数据验证 | ||
| 602 | LambdaQueryWrapper<MfDemand> queryWrapper = new LambdaQueryWrapper<>(); | ||
| 603 | queryWrapper.eq(MfDemand::getGuid, rqVO.getGuid()); | ||
| 604 | queryWrapper.select(MfDemand::getGuid, MfDemand::getBizApproveState); | ||
| 605 | MfDemand entity = mfDemandService.getOne(queryWrapper); | ||
| 606 | if (entity == null) { | ||
| 607 | throw new CsbrSystemException(SystemError.DATA_NOT_EXISTS, messageSourceUtil.notExistsToUpdateMessage(FUNCTION_NAME)); | ||
| 608 | } | ||
| 609 | //endregion 2.2.业务数据验证 | ||
| 610 | if(rqVO.getImmediateApprove() && "2".equals(rqVO.getDemandCategory())){ | ||
| 611 | checkProductGuid(rqVO.getDataProductGuid()); | ||
| 612 | } | ||
| 613 | //endregion 2.数据验证特殊处理 | ||
| 614 | rqVO.setBizApproveState(entity.getBizApproveState()); | ||
| 615 | |||
| 616 | // 上次审批通过时 重新提交上架 修改上次审批状态为已废弃 | ||
| 617 | if (ApprovalStateEnum.PASSED.getValue().equals(entity.getBizApproveState())) { | ||
| 618 | LambdaUpdateWrapper<MfDemand> updateWrapper = Wrappers.lambdaUpdate(); | ||
| 619 | updateWrapper.eq(MfDemand::getGuid, rqVO.getGuid()) | ||
| 620 | .set(MfDemand::getBizApproveState, ApprovalStateEnum.DISABLE.getValue()); | ||
| 621 | mfDemandService.update(updateWrapper); | ||
| 622 | } | ||
| 623 | |||
| 624 | if (!isTenantAndHospital) { | ||
| 625 | rqVO.setListingStatus("N"); | ||
| 626 | } | ||
| 627 | |||
| 628 | //region 3.数据转换处理 | ||
| 629 | |||
| 630 | //region 3.1.数据过程转换 | ||
| 631 | //endregion 3.1.数据过程转换 | ||
| 632 | |||
| 633 | //endregion 3.数据转换处理 | ||
| 634 | |||
| 635 | //region 4.数据过滤与补充处理 | ||
| 636 | //endregion 4.数据过滤与补充处理 | ||
| 637 | |||
| 638 | //region 5.过程处理 | ||
| 639 | |||
| 640 | //region 5.1.计算逻辑处理 | ||
| 641 | //endregion 5.1.计算逻辑处理 | ||
| 642 | |||
| 643 | //region 5.2.业务逻辑处理 | ||
| 644 | //endregion 5.2.业务逻辑处理 | ||
| 645 | |||
| 646 | //endregion 5.过程处理 | ||
| 647 | } | ||
| 648 | |||
| 649 | /** | ||
| 650 | * 数据需求修改后置处理 | ||
| 651 | * @author xcq | ||
| 652 | * @date 2024-12-31 18:46 | ||
| 653 | * @param entity | ||
| 654 | * @param rqVO | ||
| 655 | * @return void | ||
| 656 | */ | ||
| 657 | protected void afterUpdate(MfDemand entity, DemandRQVO rqVO) { | ||
| 658 | //region 1.输出特殊转换 | ||
| 659 | |||
| 660 | //region 1.1.输出过滤与补充处理 | ||
| 661 | //endregion 1.1.输出过滤与补充处理 | ||
| 662 | |||
| 663 | //endregion 1.输出特殊转换 | ||
| 664 | } | ||
| 665 | |||
| 666 | |||
| 667 | /** | ||
| 668 | * 数据需求删除前置处理 | ||
| 669 | * @author xcq | ||
| 670 | * @date 2024-12-31 18:46 | ||
| 671 | * @param entity | ||
| 672 | * @return void | ||
| 673 | */ | ||
| 674 | private void beforeRemove(MfDemand entity) { | ||
| 675 | if (entity == null) { | ||
| 676 | throw new CsbrSystemException(SystemError.DATA_DEL_ERROR, messageSourceUtil.notExistsToDelMessage(FUNCTION_NAME)); | ||
| 677 | } | ||
| 678 | if (ApprovalStateEnum.CHECKING.getValue().equals(entity.getBizApproveState()) || | ||
| 679 | ApprovalStateEnum.PASSED.getValue().equals(entity.getBizApproveState())) { | ||
| 680 | throw new CsbrSystemException(SystemError.DATA_DEL_ERROR, "审批中和审批通过的数据不能删除!"); | ||
| 681 | } | ||
| 682 | } | ||
| 683 | |||
| 684 | /** | ||
| 685 | * 数据需求删除后置处理 | ||
| 686 | * @author xcq | ||
| 687 | * @date 2024-12-31 18:46 | ||
| 688 | * @param entity | ||
| 689 | * @return void | ||
| 690 | */ | ||
| 691 | private void afterRemove(MfDemand entity) { | ||
| 692 | |||
| 693 | } | ||
| 694 | |||
| 695 | /** | ||
| 696 | * 数据需求查询方法前置验证、处理 | ||
| 697 | * @author xcq | ||
| 698 | * @date 2024-12-31 18:46 | ||
| 699 | * @param rqQueryVO | ||
| 700 | * @return void | ||
| 701 | */ | ||
| 702 | private void beforeQuery(DemandQueryVO rqQueryVO) { | ||
| 703 | rqQueryVO.setIsNeedQuery(true); | ||
| 704 | if (approvalFlowUtil.isQueryBizGuid(rqQueryVO)) { | ||
| 705 | rqQueryVO.setFlowType(FLOW_TYPE); | ||
| 706 | List<String> bizGuidList = approvalFlowUtil.getApprovalBizGuids(rqQueryVO); | ||
| 707 | if (CollectionUtils.isEmpty(bizGuidList)) { | ||
| 708 | rqQueryVO.setIsNeedQuery(false); | ||
| 709 | } else { | ||
| 710 | rqQueryVO.setGuidList(bizGuidList); | ||
| 711 | } | ||
| 712 | } | ||
| 713 | //如果是非认证会员在操作时,如果是管理员看全部,非管理员看自己的数据 | ||
| 714 | StaffRSVO staff = getCurStaff(); | ||
| 715 | if("非认证会员".equals(staff.getTenantName())){ | ||
| 716 | if("N".equals(staff.getIsAdmin())){ | ||
| 717 | rqQueryVO.setCreateUserName(staff.getStaffName()); | ||
| 718 | } | ||
| 719 | } | ||
| 720 | } | ||
| 721 | |||
| 722 | private StaffRSVO getCurStaff(){ | ||
| 723 | UserInfo userInfo = UserContextHolder.get(); | ||
| 724 | StaffRSVO staffVO = personelFeign.getByUserGuid(userInfo.getUserId()).getData(); | ||
| 725 | return staffVO; | ||
| 726 | } | ||
| 727 | |||
| 728 | /** | ||
| 729 | * 数据需求查询方法后置数据转换、处理 | ||
| 730 | * @author xcq | ||
| 731 | * @date 2024-12-31 18:46 | ||
| 732 | * @param pageList 数据库查询数据 | ||
| 733 | * @param rsPageList 返回的最终数据 | ||
| 734 | * @return void | ||
| 735 | */ | ||
| 736 | private void afterQuery(PageListVO<MfDemand> pageList, PageListVO<DemandRSVO> rsPageList) { | ||
| 737 | // 需要特殊处理数据时使用 | ||
| 738 | if(CollectionUtils.isNotEmpty(pageList.getRecords())){ | ||
| 739 | List<String> guids = pageList.getRecords().stream().map(MfDemand::getGuid).collect(Collectors.toList()); | ||
| 740 | List<DemandRSVO> results = new ArrayList<>(); | ||
| 741 | Map<String, DemandUpdateStateVO> stateMap = getStateMap(guids); | ||
| 742 | for (MfDemand item : pageList.getRecords()){ | ||
| 743 | DemandRSVO vo = convertToVO(item, stateMap); | ||
| 744 | results.add(vo); | ||
| 745 | } | ||
| 746 | rsPageList.setRecords(results); | ||
| 747 | } | ||
| 748 | } | ||
| 749 | |||
| 750 | //region 辅助操作 | ||
| 751 | |||
| 752 | /** | ||
| 753 | * 数据需求实体数据转换为视图对象数据 | ||
| 754 | * @author xcq | ||
| 755 | * @date 2024-12-31 18:46 | ||
| 756 | * @param entity | ||
| 757 | * @return com.csbr.qingcloud.portal.domain.vo.DemandRSVO | ||
| 758 | */ | ||
| 759 | private DemandRSVO convertToVO(MfDemand entity,Map<String, DemandUpdateStateVO> map) { | ||
| 760 | DemandRSVO vo = csbrBeanUtil.convert(entity, DemandRSVO.class); | ||
| 761 | //流程数据处理 | ||
| 762 | vo.setApproveVO(approvalFlowUtil.getApprovalInfo(entity.getGuid())); | ||
| 763 | if(map != null){ | ||
| 764 | DemandUpdateStateVO voState = map.get(entity.getGuid()); | ||
| 765 | if(voState != null){ | ||
| 766 | vo.setResourceAcquisitionState(voState.getResourceAcquisitionState()); | ||
| 767 | vo.setProductProcessingState(voState.getProductProcessingState()); | ||
| 768 | vo.setProductDeliveryState(voState.getProductDeliveryState()); | ||
| 769 | vo.setProductAcceptState(voState.getProductAcceptState()); | ||
| 770 | vo.setAcceptFinishTime(DateUtil.getShortDate(voState.getAcceptFinishTime())); | ||
| 771 | vo.setFinishCycle(DateUtil.getDiffDay(voState.getAcceptFinishTime(),entity.getProcessingGenerateTime())); | ||
| 772 | vo.setBizName(voState.getBizName()); | ||
| 773 | } | ||
| 774 | } | ||
| 775 | return vo; | ||
| 776 | } | ||
| 777 | |||
| 778 | |||
| 779 | |||
| 780 | /** | ||
| 781 | * 数据需求新增、修改和其他情况的参数转换为实体 | ||
| 782 | * @author xcq | ||
| 783 | * @date 2024-12-31 18:46 | ||
| 784 | * @param vo | ||
| 785 | * @return com.csbr.qingcloud.portal.mybatis.entity.MfDemand | ||
| 786 | */ | ||
| 787 | private MfDemand convertToEntity(DemandRQVO vo) { | ||
| 788 | MfDemand entity = csbrBeanUtil.convert(vo, MfDemand.class); | ||
| 789 | // 新增时数据默认guid赋值,转换后该guid可能别使用 | ||
| 790 | if (StringUtils.isBlank(vo.getGuid())) { | ||
| 791 | entity.setGuid(CommonUtil.newGuid()); | ||
| 792 | } | ||
| 793 | return entity; | ||
| 794 | } | ||
| 795 | |||
| 796 | //endregion | ||
| 797 | |||
| 798 | } |
src/main/java/com/csbr/qingcloud/portal/service/impl/EnterpriseChangeApproveServiceImpl.java
0 → 100644
| 1 | package com.csbr.qingcloud.portal.service.impl; | ||
| 2 | |||
| 3 | import com.alibaba.fastjson.JSON; | ||
| 4 | import com.alibaba.fastjson.JSONObject; | ||
| 5 | import com.baomidou.mybatisplus.core.conditions.query.LambdaQueryWrapper; | ||
| 6 | import com.baomidou.mybatisplus.core.conditions.update.LambdaUpdateWrapper; | ||
| 7 | import com.baomidou.mybatisplus.core.toolkit.Wrappers; | ||
| 8 | import com.csbr.cloud.common.enums.SystemError; | ||
| 9 | import com.csbr.cloud.common.exception.CsbrSystemException; | ||
| 10 | import com.csbr.cloud.common.util.CommonUtil; | ||
| 11 | import com.csbr.cloud.common.util.CsbrBeanUtil; | ||
| 12 | import com.csbr.cloud.common.util.MessageSourceUtil; | ||
| 13 | import com.csbr.cloud.workflow.domain.dto.callback.BizCallbackDTO; | ||
| 14 | import com.csbr.cloud.workflow.util.ApprovalFlowUtil; | ||
| 15 | import com.csbr.qingcloud.portal.domain.vo.ChangeApproveVO; | ||
| 16 | import com.csbr.qingcloud.portal.domain.vo.ChangeInfoVO; | ||
| 17 | import com.csbr.qingcloud.portal.domain.vo.EnterpriseRQVO; | ||
| 18 | import com.csbr.qingcloud.portal.domain.vo.EnterpriseRSVO; | ||
| 19 | import com.csbr.qingcloud.portal.feign.ConfigureFeign; | ||
| 20 | import com.csbr.qingcloud.portal.feign.PersonelFeign; | ||
| 21 | import com.csbr.qingcloud.portal.mybatis.entity.MfEnterprise; | ||
| 22 | import com.csbr.qingcloud.portal.mybatis.entity.MfEnterpriseChangeApprove; | ||
| 23 | import com.csbr.qingcloud.portal.mybatis.service.MfEnterpriseChangeApproveService; | ||
| 24 | import com.csbr.qingcloud.portal.mybatis.service.MfEnterpriseService; | ||
| 25 | import com.csbr.qingcloud.portal.service.EnterpriseChangeApproveService; | ||
| 26 | import com.csbr.qingcloud.portal.service.EnterpriseService; | ||
| 27 | import com.csbr.qingcloud.portal.util.ChangeInfoUtil; | ||
| 28 | import com.csbr.qingcloud.portal.util.InvokeUtil; | ||
| 29 | import com.csbr.qingcloud.portal.util.ZQConfig; | ||
| 30 | import csbr.cloud.entity.enums.ApprovalStateEnum; | ||
| 31 | import io.seata.spring.annotation.GlobalTransactional; | ||
| 32 | import jakarta.annotation.Resource; | ||
| 33 | import lombok.extern.slf4j.Slf4j; | ||
| 34 | import org.apache.commons.collections.CollectionUtils; | ||
| 35 | import org.apache.commons.lang.StringUtils; | ||
| 36 | import org.apache.commons.lang3.ObjectUtils; | ||
| 37 | import org.springframework.beans.factory.annotation.Autowired; | ||
| 38 | import org.springframework.stereotype.Component; | ||
| 39 | |||
| 40 | import java.util.*; | ||
| 41 | |||
| 42 | /** | ||
| 43 | * @program: ms-hc-customer-service | ||
| 44 | * @description: 供应商商品变更 | ||
| 45 | * @author: XiaoCQ | ||
| 46 | * @create: 2024-08-05 | ||
| 47 | **/ | ||
| 48 | @Component | ||
| 49 | @Slf4j | ||
| 50 | public class EnterpriseChangeApproveServiceImpl implements EnterpriseChangeApproveService { | ||
| 51 | |||
| 52 | /** | ||
| 53 | * 功能名称 | ||
| 54 | */ | ||
| 55 | private static final String FUNCTION_NAME = "企业变更信息"; | ||
| 56 | |||
| 57 | private static final String SysFuncCode = "QYRZ"; | ||
| 58 | |||
| 59 | @Autowired | ||
| 60 | private ZQConfig zqConfig; | ||
| 61 | |||
| 62 | @Autowired | ||
| 63 | private InvokeUtil invokeUtil; | ||
| 64 | |||
| 65 | @Resource | ||
| 66 | private MfEnterpriseChangeApproveService mfEnterpriseChangeApproveService; | ||
| 67 | |||
| 68 | @Resource | ||
| 69 | private CsbrBeanUtil csbrBeanUtil; | ||
| 70 | |||
| 71 | @Resource | ||
| 72 | private MfEnterpriseService mfEnterpriseService; | ||
| 73 | |||
| 74 | @Resource | ||
| 75 | private EnterpriseService enterpriseService; | ||
| 76 | |||
| 77 | @Resource | ||
| 78 | private MessageSourceUtil messageSourceUtil; | ||
| 79 | |||
| 80 | @Resource | ||
| 81 | private ApprovalFlowUtil approvalFlowUtil; | ||
| 82 | |||
| 83 | @Resource | ||
| 84 | private PersonelFeign personelFeign; | ||
| 85 | |||
| 86 | @Resource | ||
| 87 | private ConfigureFeign configureFeign; | ||
| 88 | |||
| 89 | /** 保存变更数据 */ | ||
| 90 | @Override | ||
| 91 | public void changeSave(ChangeApproveVO vo) { | ||
| 92 | log.info("======vo, {}", JSON.toJSONString(vo)); | ||
| 93 | //对重新发起的原审批源数据进行废弃 | ||
| 94 | if(StringUtils.isNotBlank(vo.getSourceApproveGuid())){ | ||
| 95 | LambdaUpdateWrapper<MfEnterpriseChangeApprove> updateWrapper = new LambdaUpdateWrapper<>(); | ||
| 96 | updateWrapper.eq(MfEnterpriseChangeApprove::getApproveGuid,vo.getSourceApproveGuid()); | ||
| 97 | updateWrapper.set(MfEnterpriseChangeApprove::getBizApproveState,"D"); | ||
| 98 | mfEnterpriseChangeApproveService.update(updateWrapper); | ||
| 99 | } | ||
| 100 | |||
| 101 | //保存新数据 | ||
| 102 | EnterpriseRQVO beanVO = JSON.parseObject(vo.getBizDataJson(), EnterpriseRQVO.class); | ||
| 103 | String tenantGuid = beanVO.getTenantGuid(); | ||
| 104 | MfEnterpriseChangeApprove entity = csbrBeanUtil.convert(beanVO, MfEnterpriseChangeApprove.class); | ||
| 105 | setEntity(entity,beanVO,vo); | ||
| 106 | entity.setDataType("2"); | ||
| 107 | entity.setBizApproveState(ApprovalStateEnum.CHECKING.getValue()); | ||
| 108 | entity.setGuid(vo.getGuid()); | ||
| 109 | mfEnterpriseChangeApproveService.save(entity); | ||
| 110 | |||
| 111 | //保存原数据 | ||
| 112 | beanVO = JSON.parseObject(vo.getOldBizDataJson(),EnterpriseRQVO.class); | ||
| 113 | entity = csbrBeanUtil.convert(beanVO,MfEnterpriseChangeApprove.class); | ||
| 114 | setEntity(entity,beanVO,vo); | ||
| 115 | entity.setDataType("1"); | ||
| 116 | entity.setGuid(CommonUtil.newGuid()); | ||
| 117 | entity.setTenantGuid(tenantGuid); | ||
| 118 | mfEnterpriseChangeApproveService.save(entity); | ||
| 119 | |||
| 120 | log.info("========entity, {}", entity); | ||
| 121 | MfEnterprise bean = mfEnterpriseService.getById(entity.getSourceGuid()); | ||
| 122 | bean.setBizApproveState("B"); | ||
| 123 | mfEnterpriseService.updateById(bean); | ||
| 124 | } | ||
| 125 | |||
| 126 | private void setEntity(MfEnterpriseChangeApprove entity,EnterpriseRQVO customerVO,ChangeApproveVO vo){ | ||
| 127 | entity.setApproveGuid(vo.getApproveGuid()); | ||
| 128 | entity.setSourceGuid(vo.getSourceGuid()); | ||
| 129 | entity.setZqName(vo.getZqName()); | ||
| 130 | entity.setZqBizGuid(vo.getZqBizGuid()); | ||
| 131 | } | ||
| 132 | |||
| 133 | /** 变更数据详细接口 */ | ||
| 134 | @Override | ||
| 135 | public ChangeApproveVO changeDetail(String guid) { | ||
| 136 | //取新数据 | ||
| 137 | LambdaQueryWrapper<MfEnterpriseChangeApprove> queryWrapper = new LambdaQueryWrapper<>(); | ||
| 138 | queryWrapper.eq(MfEnterpriseChangeApprove::getApproveGuid,guid); | ||
| 139 | queryWrapper.eq(MfEnterpriseChangeApprove::getDataType,"2"); | ||
| 140 | List<MfEnterpriseChangeApprove> tempList = mfEnterpriseChangeApproveService.list(queryWrapper); | ||
| 141 | if(CollectionUtils.isEmpty(tempList)){ | ||
| 142 | throw new CsbrSystemException(SystemError.DATA_INPUT_ERROR, "未找到对应的变更数据,审批流GUID:" + guid); | ||
| 143 | } | ||
| 144 | MfEnterpriseChangeApprove bean = tempList.get(0); | ||
| 145 | ChangeApproveVO vo = new ChangeApproveVO(); | ||
| 146 | vo.setGuid(bean.getGuid()); | ||
| 147 | vo.setApproveGuid(bean.getApproveGuid()); | ||
| 148 | vo.setSourceGuid(bean.getSourceGuid()); | ||
| 149 | vo.setBizDataJson(convertToVO(bean)); | ||
| 150 | |||
| 151 | //取原数据 | ||
| 152 | queryWrapper = new LambdaQueryWrapper<>(); | ||
| 153 | queryWrapper.eq(MfEnterpriseChangeApprove::getApproveGuid,bean.getApproveGuid()); | ||
| 154 | queryWrapper.eq(MfEnterpriseChangeApprove::getDataType,"1"); | ||
| 155 | tempList = mfEnterpriseChangeApproveService.list(queryWrapper); | ||
| 156 | if(CollectionUtils.isNotEmpty(tempList)){ | ||
| 157 | vo.setOldBizDataJson(convertToVO(tempList.get(0))); | ||
| 158 | } | ||
| 159 | |||
| 160 | return vo; | ||
| 161 | } | ||
| 162 | |||
| 163 | /** 执行最终的变更 */ | ||
| 164 | @Override | ||
| 165 | public void changeUpdate(BizCallbackDTO dto) { | ||
| 166 | MfEnterpriseChangeApprove entity = mfEnterpriseChangeApproveService.getById(dto.getBizGuid()); | ||
| 167 | |||
| 168 | LambdaUpdateWrapper<MfEnterpriseChangeApprove> updateWrapper = new LambdaUpdateWrapper<>(); | ||
| 169 | updateWrapper.eq(MfEnterpriseChangeApprove::getApproveGuid,entity.getApproveGuid()); | ||
| 170 | updateWrapper.set(MfEnterpriseChangeApprove::getBizApproveState,dto.getApprovalState()); | ||
| 171 | mfEnterpriseChangeApproveService.update(updateWrapper); | ||
| 172 | |||
| 173 | //审批不通过则将状态恢复到以前的Y | ||
| 174 | if(dto.getApprovalState().equals(ApprovalStateEnum.REJECT.getValue())){ | ||
| 175 | MfEnterprise bean = mfEnterpriseService.getById(entity.getSourceGuid()); | ||
| 176 | bean.setBizApproveState("Y"); | ||
| 177 | mfEnterpriseService.updateById(bean); | ||
| 178 | return; | ||
| 179 | } | ||
| 180 | if (dto.getApprovalState().equals(ApprovalStateEnum.PASSED.getValue()) && !dto.getIsZqPlatformApprove()) { | ||
| 181 | //审批通过则执行更新 | ||
| 182 | MfEnterprise vo = csbrBeanUtil.convert(entity,MfEnterprise.class); | ||
| 183 | vo.setGuid(entity.getSourceGuid()); | ||
| 184 | vo.setBizApproveState("Y"); | ||
| 185 | mfEnterpriseService.updateById(vo); | ||
| 186 | |||
| 187 | //同步更新会员表 | ||
| 188 | enterpriseService.updateTenant(vo); | ||
| 189 | } | ||
| 190 | } | ||
| 191 | |||
| 192 | @Override | ||
| 193 | @GlobalTransactional(rollbackFor = Exception.class) | ||
| 194 | public void removeByGuids(List<String> guids) { | ||
| 195 | if (CollectionUtils.isEmpty(guids)) { | ||
| 196 | // W00012 = {0}:参数[{1}]不能为空! | ||
| 197 | throw new CsbrSystemException(SystemError.DATA_INPUT_ERROR, messageSourceUtil.getMessage("W00012", | ||
| 198 | String.format("删除%s数据", FUNCTION_NAME), "数据唯一标识")); | ||
| 199 | } | ||
| 200 | String crossPlatformApproveState = ""; | ||
| 201 | for (String guid : guids) { | ||
| 202 | MfEnterpriseChangeApprove entity = mfEnterpriseChangeApproveService.getById(guid); | ||
| 203 | if (entity == null) { | ||
| 204 | continue; | ||
| 205 | } | ||
| 206 | if (ApprovalStateEnum.CHECKING.getValue().equals(entity.getBizApproveState()) || | ||
| 207 | ApprovalStateEnum.PASSED.getValue().equals(entity.getBizApproveState())) { | ||
| 208 | throw new CsbrSystemException(SystemError.DATA_DEL_ERROR, "审批中和审批通过的数据不能删除!"); | ||
| 209 | } | ||
| 210 | mfEnterpriseChangeApproveService.removeById(guid); | ||
| 211 | |||
| 212 | // 修改企业认证审批状态 | ||
| 213 | LambdaQueryWrapper<MfEnterpriseChangeApprove> lambdaQueryWrapper = Wrappers.lambdaQuery(MfEnterpriseChangeApprove.class); | ||
| 214 | lambdaQueryWrapper.eq(MfEnterpriseChangeApprove::getSourceGuid, entity.getSourceGuid()); | ||
| 215 | lambdaQueryWrapper.eq(MfEnterpriseChangeApprove::getDataType, "2"); | ||
| 216 | lambdaQueryWrapper.orderByDesc(MfEnterpriseChangeApprove::getCreateTime).last("limit 1"); | ||
| 217 | MfEnterpriseChangeApprove enterpriseChangeApprove = mfEnterpriseChangeApproveService.getOne(lambdaQueryWrapper); | ||
| 218 | if (ObjectUtils.isEmpty(enterpriseChangeApprove) || Arrays.asList("Y", "R", "C").contains(enterpriseChangeApprove.getBizApproveState())) { | ||
| 219 | LambdaUpdateWrapper<MfEnterprise> updateWrapper = new LambdaUpdateWrapper<>(); | ||
| 220 | updateWrapper.eq(MfEnterprise::getGuid, entity.getSourceGuid()); | ||
| 221 | updateWrapper.set(MfEnterprise::getBizApproveState, ApprovalStateEnum.PASSED.getValue()); | ||
| 222 | mfEnterpriseService.update(updateWrapper); | ||
| 223 | } | ||
| 224 | |||
| 225 | crossPlatformApproveState = entity.getCrossPlatformApproveState(); | ||
| 226 | } | ||
| 227 | |||
| 228 | // 删除主平台数据 | ||
| 229 | if (!zqConfig.getIsMain() && StringUtils.isNotEmpty(crossPlatformApproveState)) { | ||
| 230 | JSONObject jsonObject = new JSONObject(); | ||
| 231 | jsonObject.put("zqSystemCode", SysFuncCode + "BG"); | ||
| 232 | jsonObject.put("zqBizGuids", JSON.toJSONString(guids)); | ||
| 233 | jsonObject.put("isCollection", true); | ||
| 234 | invokeUtil.invokeMainDel(jsonObject, zqConfig.getAppKey(), zqConfig.getZqDelUrl()); | ||
| 235 | } | ||
| 236 | |||
| 237 | // 删除流程数据 | ||
| 238 | approvalFlowUtil.removeApproveByBizGuids(guids); | ||
| 239 | } | ||
| 240 | |||
| 241 | @Override | ||
| 242 | public void crossFlowCallBack(BizCallbackDTO dto) { | ||
| 243 | MfEnterpriseChangeApprove entity = mfEnterpriseChangeApproveService.getById(dto.getBizGuid()); | ||
| 244 | |||
| 245 | LambdaUpdateWrapper<MfEnterpriseChangeApprove> updateWrapper = new LambdaUpdateWrapper<>(); | ||
| 246 | updateWrapper.eq(MfEnterpriseChangeApprove::getApproveGuid,entity.getApproveGuid()); | ||
| 247 | updateWrapper.set(MfEnterpriseChangeApprove::getBizApproveState, dto.getApprovalState()); | ||
| 248 | updateWrapper.set(MfEnterpriseChangeApprove::getCrossPlatformApproveState, dto.getApprovalState()); | ||
| 249 | mfEnterpriseChangeApproveService.update(updateWrapper); | ||
| 250 | |||
| 251 | //审批不通过则将状态恢复到以前的Y | ||
| 252 | if(dto.getApprovalState().equals(ApprovalStateEnum.REJECT.getValue())){ | ||
| 253 | MfEnterprise bean = mfEnterpriseService.getById(entity.getSourceGuid()); | ||
| 254 | bean.setBizApproveState("Y"); | ||
| 255 | bean.setCrossPlatformApproveState("Y"); | ||
| 256 | mfEnterpriseService.updateById(bean); | ||
| 257 | return; | ||
| 258 | } | ||
| 259 | if(dto.getApprovalState().equals(ApprovalStateEnum.PASSED.getValue())){ | ||
| 260 | //审批通过则执行更新 | ||
| 261 | MfEnterprise vo = csbrBeanUtil.convert(entity,MfEnterprise.class); | ||
| 262 | vo.setGuid(entity.getSourceGuid()); | ||
| 263 | vo.setBizApproveState("Y"); | ||
| 264 | vo.setCrossPlatformApproveState("Y"); | ||
| 265 | mfEnterpriseService.updateById(vo); | ||
| 266 | |||
| 267 | //同步更新会员表 | ||
| 268 | enterpriseService.updateTenant(vo); | ||
| 269 | } | ||
| 270 | } | ||
| 271 | |||
| 272 | @Override | ||
| 273 | @GlobalTransactional | ||
| 274 | public void crossRemoveByBizGuid(List<String> zqBizGuids) { | ||
| 275 | if (ObjectUtils.isEmpty(zqBizGuids)) { | ||
| 276 | // W00012 = {0}:参数[{1}]不能为空! | ||
| 277 | throw new CsbrSystemException(SystemError.DATA_INPUT_ERROR, messageSourceUtil.getMessage("W00012", | ||
| 278 | String.format("删除%s数据", FUNCTION_NAME), "数据唯一标识")); | ||
| 279 | } | ||
| 280 | String zqBizGuid = zqBizGuids.get(0); | ||
| 281 | LambdaQueryWrapper<MfEnterpriseChangeApprove> queryWrapper = Wrappers.lambdaQuery(MfEnterpriseChangeApprove.class); | ||
| 282 | queryWrapper.eq(MfEnterpriseChangeApprove::getZqBizGuid, zqBizGuid); | ||
| 283 | queryWrapper.eq(MfEnterpriseChangeApprove::getDataType, 2).last(" limit 1 "); | ||
| 284 | MfEnterpriseChangeApprove enterpriseChangeApprove = mfEnterpriseChangeApproveService.getOne(queryWrapper); | ||
| 285 | if (ObjectUtils.isEmpty(enterpriseChangeApprove)) { | ||
| 286 | return; | ||
| 287 | } | ||
| 288 | |||
| 289 | LambdaUpdateWrapper<MfEnterpriseChangeApprove> removeWraaper = Wrappers.lambdaUpdate(MfEnterpriseChangeApprove.class); | ||
| 290 | removeWraaper.eq(MfEnterpriseChangeApprove::getZqBizGuid, zqBizGuid); | ||
| 291 | mfEnterpriseChangeApproveService.remove(removeWraaper); | ||
| 292 | |||
| 293 | // 删除流程数据 | ||
| 294 | approvalFlowUtil.removeApproveByBizGuids(Collections.singletonList(enterpriseChangeApprove.getGuid())); | ||
| 295 | } | ||
| 296 | |||
| 297 | @Override | ||
| 298 | public EnterpriseRSVO getEnterpriseChangeDetail(String guid) { | ||
| 299 | if (StringUtils.isBlank(guid)) { | ||
| 300 | // W00012 = {0}:参数[{1}]不能为空! | ||
| 301 | throw new CsbrSystemException(SystemError.DATA_INPUT_ERROR, messageSourceUtil.getMessage("W00010", | ||
| 302 | String.format("获取%s详情数据", FUNCTION_NAME), "数据唯一标识")); | ||
| 303 | } | ||
| 304 | |||
| 305 | MfEnterpriseChangeApprove entity = mfEnterpriseChangeApproveService.getById(guid); | ||
| 306 | if (entity == null) { | ||
| 307 | throw new CsbrSystemException(SystemError.DATA_NOT_EXISTS, messageSourceUtil.notExistsToSelectMessage(String.format("获取%s详情数据", FUNCTION_NAME))); | ||
| 308 | } | ||
| 309 | EnterpriseRSVO vo = csbrBeanUtil.convert(entity, EnterpriseRSVO.class); | ||
| 310 | |||
| 311 | //流程数据处理 | ||
| 312 | vo.setApproveVO(approvalFlowUtil.getApprovalCrossTenantInfo(entity.getGuid())); | ||
| 313 | if(CollectionUtils.isEmpty(ChangeInfoUtil.areaList)){ | ||
| 314 | ChangeInfoUtil.areaList = configureFeign.getBoroughCodeName().getData(); | ||
| 315 | } | ||
| 316 | vo.setVenue(ChangeInfoUtil.getVenue(vo.getProvince(),vo.getCity(),vo.getDistrict())); | ||
| 317 | vo.setBusinessLicenseStartEnd(ChangeInfoUtil.getStartEnd(vo.getBusinessLicenseTerm(),vo.getBusinessLicenseStartDate(),vo.getBusinessLicenseEndDate())); | ||
| 318 | |||
| 319 | //生成变更信息 | ||
| 320 | vo.setChangeList(enterpriseService.getChange(entity.getSourceGuid(), entity.getCreateTime())); | ||
| 321 | |||
| 322 | // 生成变更前的数据 | ||
| 323 | vo.setBeforeChangeList(enterpriseService.beforeChangeList(entity.getApproveGuid())); | ||
| 324 | return vo; | ||
| 325 | } | ||
| 326 | |||
| 327 | /** | ||
| 328 | * 企业信息删除前置处理 | ||
| 329 | * @author xcq | ||
| 330 | * @date 2024-12-26 16:18 | ||
| 331 | * @param entity | ||
| 332 | * @return void | ||
| 333 | */ | ||
| 334 | private void beforeRemove(MfEnterpriseChangeApprove entity) { | ||
| 335 | if (entity == null) { | ||
| 336 | throw new CsbrSystemException(SystemError.DATA_DEL_ERROR, messageSourceUtil.notExistsToDelMessage(FUNCTION_NAME)); | ||
| 337 | } | ||
| 338 | if (ApprovalStateEnum.CHECKING.getValue().equals(entity.getBizApproveState()) || | ||
| 339 | ApprovalStateEnum.PASSED.getValue().equals(entity.getBizApproveState())) { | ||
| 340 | throw new CsbrSystemException(SystemError.DATA_DEL_ERROR, "审批中和审批通过的数据不能删除!"); | ||
| 341 | } | ||
| 342 | } | ||
| 343 | |||
| 344 | /** 转换数据 */ | ||
| 345 | private String convertToVO(MfEnterpriseChangeApprove entity){ | ||
| 346 | EnterpriseRSVO vo = csbrBeanUtil.convert(entity, EnterpriseRSVO.class); | ||
| 347 | return JSON.toJSONString(vo); | ||
| 348 | } | ||
| 349 | |||
| 350 | } |
| 1 | package com.csbr.qingcloud.portal.service.impl; | ||
| 2 | |||
| 3 | import com.alibaba.fastjson.JSON; | ||
| 4 | import com.alibaba.fastjson.JSONArray; | ||
| 5 | import com.alibaba.fastjson.JSONObject; | ||
| 6 | import com.baomidou.mybatisplus.core.conditions.query.LambdaQueryWrapper; | ||
| 7 | import com.baomidou.mybatisplus.core.conditions.update.LambdaUpdateWrapper; | ||
| 8 | import com.baomidou.mybatisplus.core.toolkit.Wrappers; | ||
| 9 | import com.csbr.cloud.common.enums.SystemError; | ||
| 10 | import com.csbr.cloud.common.enums.WorkFlowBizEnum; | ||
| 11 | import com.csbr.cloud.common.exception.CsbrSystemException; | ||
| 12 | import com.csbr.cloud.common.util.CommonUtil; | ||
| 13 | import com.csbr.cloud.common.util.CsbrBeanUtil; | ||
| 14 | import com.csbr.cloud.common.util.MessageSourceUtil; | ||
| 15 | import com.csbr.cloud.distributelock.util.RedisUtil; | ||
| 16 | import com.csbr.cloud.workflow.domain.dto.appove.AddApprovalDTO; | ||
| 17 | import com.csbr.cloud.workflow.domain.dto.appove.FlowQueryDTO; | ||
| 18 | import com.csbr.cloud.workflow.domain.dto.callback.BizCallbackDTO; | ||
| 19 | import com.csbr.cloud.workflow.domain.vo.appove.ApproveVO; | ||
| 20 | import com.csbr.cloud.workflow.domain.vo.appove.FlowRQBaseVO; | ||
| 21 | import com.csbr.cloud.workflow.util.ApprovalFlowUtil; | ||
| 22 | import com.csbr.cloud.workflow.util.FlowAbstractImpl; | ||
| 23 | import com.csbr.qingcloud.portal.domain.vo.*; | ||
| 24 | import com.csbr.qingcloud.portal.feign.ConfigureFeign; | ||
| 25 | import com.csbr.qingcloud.portal.feign.PersonelFeign; | ||
| 26 | import com.csbr.qingcloud.portal.feign.WorkflowFeign; | ||
| 27 | import com.csbr.qingcloud.portal.mybatis.entity.MfDemand; | ||
| 28 | import com.csbr.qingcloud.portal.mybatis.entity.MfEnterprise; | ||
| 29 | import com.csbr.qingcloud.portal.mybatis.entity.MfEnterpriseChangeApprove; | ||
| 30 | import com.csbr.qingcloud.portal.mybatis.service.MfDemandService; | ||
| 31 | import com.csbr.qingcloud.portal.mybatis.service.MfEnterpriseChangeApproveService; | ||
| 32 | import com.csbr.qingcloud.portal.mybatis.service.MfEnterpriseService; | ||
| 33 | import com.csbr.qingcloud.portal.service.EnterpriseService; | ||
| 34 | import com.csbr.qingcloud.portal.util.ChangeInfoUtil; | ||
| 35 | import com.csbr.qingcloud.portal.util.DateUtil; | ||
| 36 | import com.csbr.qingcloud.portal.util.InvokeUtil; | ||
| 37 | import com.csbr.qingcloud.portal.util.ZQConfig; | ||
| 38 | import csbr.cloud.entity.domain.base.vo.PageListVO; | ||
| 39 | import csbr.cloud.entity.enums.ApprovalStateEnum; | ||
| 40 | import io.seata.spring.annotation.GlobalTransactional; | ||
| 41 | import jakarta.annotation.Resource; | ||
| 42 | import lombok.extern.slf4j.Slf4j; | ||
| 43 | import org.apache.commons.collections.CollectionUtils; | ||
| 44 | import org.apache.commons.lang3.ObjectUtils; | ||
| 45 | import org.apache.commons.lang3.StringUtils; | ||
| 46 | import org.springframework.beans.factory.annotation.Autowired; | ||
| 47 | import org.springframework.stereotype.Service; | ||
| 48 | import org.springframework.transaction.annotation.Transactional; | ||
| 49 | |||
| 50 | import java.text.SimpleDateFormat; | ||
| 51 | import java.util.*; | ||
| 52 | import java.util.function.Function; | ||
| 53 | import java.util.stream.Collectors; | ||
| 54 | |||
| 55 | /** | ||
| 56 | * @program: D:/git/ms-data-circulation-portal-service | ||
| 57 | * @description: 企业信息业务逻辑实现 | ||
| 58 | * @author: xcq | ||
| 59 | * @create: 2024-12-26 16:18 | ||
| 60 | **/ | ||
| 61 | @Slf4j | ||
| 62 | @Service | ||
| 63 | public class EnterpriseServiceImpl extends FlowAbstractImpl implements EnterpriseService { | ||
| 64 | |||
| 65 | /** | ||
| 66 | * 功能名称 | ||
| 67 | */ | ||
| 68 | private static final String FUNCTION_NAME = "企业信息"; | ||
| 69 | |||
| 70 | private static final String SysFuncCode = "QYRZ"; | ||
| 71 | |||
| 72 | @Autowired | ||
| 73 | private ZQConfig zqConfig; | ||
| 74 | |||
| 75 | @Autowired | ||
| 76 | private InvokeUtil invokeUtil; | ||
| 77 | |||
| 78 | @Resource | ||
| 79 | private MfEnterpriseService mfEnterpriseService; | ||
| 80 | |||
| 81 | @Resource | ||
| 82 | private CsbrBeanUtil csbrBeanUtil; | ||
| 83 | |||
| 84 | @Resource | ||
| 85 | private ApprovalFlowUtil approvalFlowUtil; | ||
| 86 | |||
| 87 | @Resource | ||
| 88 | private MessageSourceUtil messageSourceUtil; | ||
| 89 | |||
| 90 | @Resource | ||
| 91 | private PersonelFeign personelFeign; | ||
| 92 | |||
| 93 | @Resource | ||
| 94 | private WorkflowFeign workflowFeign; | ||
| 95 | |||
| 96 | @Resource | ||
| 97 | private RedisUtil redisUtil; | ||
| 98 | |||
| 99 | @Resource | ||
| 100 | private MfEnterpriseChangeApproveService mfEnterpriseChangeApproveService; | ||
| 101 | |||
| 102 | @Resource | ||
| 103 | private MfDemandService mfDemandService; | ||
| 104 | |||
| 105 | @Resource | ||
| 106 | private ConfigureFeign configureFeign; | ||
| 107 | |||
| 108 | /** | ||
| 109 | * 企业信息分页查询 | ||
| 110 | * @author xcq | ||
| 111 | * @date 2024-12-26 16:18 | ||
| 112 | * @param queryVO | ||
| 113 | * @return com.csbr.cloud.mybatis.entity.PageListVO<com.csbr.qingcloud.portal.domain.vo.EnterpriseRSVO> | ||
| 114 | */ | ||
| 115 | @Override | ||
| 116 | public PageListVO<EnterpriseRSVO> pageList(EnterpriseQueryVO queryVO) { | ||
| 117 | beforeQuery(queryVO); | ||
| 118 | if (queryVO.getIsNeedQuery()) { | ||
| 119 | LambdaQueryWrapper<MfEnterprise> queryWrapper = mfEnterpriseService.csbrQueryWrapper(queryVO, MfEnterprise.class); | ||
| 120 | queryWrapper.in(CollectionUtils.isNotEmpty(queryVO.getGuidList()), MfEnterprise::getGuid,queryVO.getGuidList()); | ||
| 121 | queryWrapper.notIn(CollectionUtils.isNotEmpty(queryVO.getBizApproveStateNotList()), MfEnterprise::getBizApproveState,queryVO.getBizApproveStateNotList()); | ||
| 122 | queryWrapper.orderByDesc(MfEnterprise::getCreateTime); | ||
| 123 | PageListVO<MfEnterprise> pageList = mfEnterpriseService.csbrPageList(queryVO, queryWrapper); | ||
| 124 | PageListVO<EnterpriseRSVO> rsPageList = csbrBeanUtil.convert(pageList, PageListVO.class); | ||
| 125 | afterQuery(pageList, rsPageList); | ||
| 126 | return rsPageList; | ||
| 127 | } | ||
| 128 | return new PageListVO<>(0L,0L); | ||
| 129 | } | ||
| 130 | |||
| 131 | @Override | ||
| 132 | public PageListVO<EnterpriseApproveRSVO> flowPageList(FlowQueryDTO dto) { | ||
| 133 | // 调用流程获取流程数据 | ||
| 134 | PageListVO<ApproveVO> pageListVO = workflowFeign.getFlowListCrossTenant(dto).getData(); | ||
| 135 | PageListVO<EnterpriseApproveRSVO> rsPageList = csbrBeanUtil.convert(pageListVO, PageListVO.class); | ||
| 136 | List<ApproveVO> approveVOList = pageListVO.getRecords(); | ||
| 137 | if (ObjectUtils.isNotEmpty(approveVOList)) { | ||
| 138 | // 根据业务guid查询认证表数据 | ||
| 139 | List<String> guids = approveVOList.stream().map(ApproveVO::getBizGuid).toList(); | ||
| 140 | List<MfEnterprise> mfEnterprises = mfEnterpriseService.listByIds(guids); | ||
| 141 | Map<String, MfEnterprise> mfEnterpriseMap = new HashMap<>(); | ||
| 142 | if (ObjectUtils.isNotEmpty(mfEnterprises)) { | ||
| 143 | mfEnterpriseMap = mfEnterprises.stream().collect(Collectors.toMap(MfEnterprise::getGuid, Function.identity())); | ||
| 144 | } | ||
| 145 | |||
| 146 | // 根据业务guid查询认证变更表数据 | ||
| 147 | List<MfEnterpriseChangeApprove> mfEnterpriseChangeApproves = mfEnterpriseChangeApproveService.listByIds(guids); | ||
| 148 | Map<String, MfEnterpriseChangeApprove> mfEnterpriseChangeApproveMap = new HashMap<>(); | ||
| 149 | if (ObjectUtils.isNotEmpty(mfEnterpriseChangeApproves)) { | ||
| 150 | mfEnterpriseChangeApproveMap = mfEnterpriseChangeApproves.stream().collect(Collectors.toMap(MfEnterpriseChangeApprove::getGuid, Function.identity())); | ||
| 151 | } | ||
| 152 | |||
| 153 | // 数据转换 | ||
| 154 | List<EnterpriseApproveRSVO> results = new ArrayList<>(); | ||
| 155 | for (ApproveVO approveVO : approveVOList) { | ||
| 156 | // 补跨服务审批状态数据 | ||
| 157 | EnterpriseApproveRSVO enterpriseApproveRSVO = csbrBeanUtil.convert(approveVO, EnterpriseApproveRSVO.class); | ||
| 158 | if (ObjectUtils.isNotEmpty(mfEnterpriseChangeApproveMap) && mfEnterpriseChangeApproveMap.containsKey(enterpriseApproveRSVO.getBizGuid())) { | ||
| 159 | MfEnterpriseChangeApprove mfEnterpriseChangeApprove = mfEnterpriseChangeApproveMap.get(enterpriseApproveRSVO.getBizGuid()); | ||
| 160 | enterpriseApproveRSVO.setCrossPlatformApproveState(mfEnterpriseChangeApprove.getCrossPlatformApproveState()); | ||
| 161 | enterpriseApproveRSVO.setZqName(mfEnterpriseChangeApprove.getZqName()); | ||
| 162 | enterpriseApproveRSVO.setTenantName(mfEnterpriseChangeApprove.getTenantName()); | ||
| 163 | } | ||
| 164 | if (ObjectUtils.isNotEmpty(mfEnterpriseMap) && mfEnterpriseMap.containsKey(enterpriseApproveRSVO.getBizGuid())) { | ||
| 165 | MfEnterprise mfEnterprise = mfEnterpriseMap.get(enterpriseApproveRSVO.getBizGuid()); | ||
| 166 | enterpriseApproveRSVO.setCrossPlatformApproveState(mfEnterprise.getCrossPlatformApproveState()); | ||
| 167 | enterpriseApproveRSVO.setZqName(mfEnterprise.getZqName()); | ||
| 168 | enterpriseApproveRSVO.setTenantName(mfEnterprise.getTenantName()); | ||
| 169 | } | ||
| 170 | results.add(enterpriseApproveRSVO); | ||
| 171 | } | ||
| 172 | |||
| 173 | rsPageList.setRecords(results); | ||
| 174 | } | ||
| 175 | |||
| 176 | return rsPageList; | ||
| 177 | } | ||
| 178 | |||
| 179 | /** | ||
| 180 | * 企业信息获取详情数据 | ||
| 181 | * @author xcq | ||
| 182 | * @date 2024-12-26 16:18 | ||
| 183 | * @param guid | ||
| 184 | * @return com.csbr.qingcloud.portal.domain.vo.EnterpriseRSVO | ||
| 185 | */ | ||
| 186 | @Override | ||
| 187 | public EnterpriseRSVO getEnterpriseDetail(String guid) { | ||
| 188 | if (StringUtils.isBlank(guid)) { | ||
| 189 | // W00012 = {0}:参数[{1}]不能为空! | ||
| 190 | throw new CsbrSystemException(SystemError.DATA_INPUT_ERROR, messageSourceUtil.getMessage("W00010", | ||
| 191 | String.format("获取%s详情数据", FUNCTION_NAME), "数据唯一标识")); | ||
| 192 | } | ||
| 193 | MfEnterprise entity = mfEnterpriseService.getById(guid); | ||
| 194 | if (entity == null) { | ||
| 195 | throw new CsbrSystemException(SystemError.DATA_NOT_EXISTS, messageSourceUtil.notExistsToSelectMessage(String.format("获取%s详情数据", FUNCTION_NAME))); | ||
| 196 | } | ||
| 197 | EnterpriseRSVO vo = convertToVO(entity); | ||
| 198 | //生成变更信息 | ||
| 199 | vo.setChangeList(getChange(guid, entity.getCreateTime())); | ||
| 200 | return vo; | ||
| 201 | } | ||
| 202 | |||
| 203 | /** 生成变更信息列表 */ | ||
| 204 | @Override | ||
| 205 | public List<ChangeInfoVO> getChange(String sourceGuid, Date createTime){ | ||
| 206 | LambdaQueryWrapper<MfEnterpriseChangeApprove> queryWrapper = new LambdaQueryWrapper<>(); | ||
| 207 | queryWrapper.eq(MfEnterpriseChangeApprove::getSourceGuid, sourceGuid); | ||
| 208 | queryWrapper.eq(MfEnterpriseChangeApprove::getBizApproveState, ApprovalStateEnum.PASSED.getValue()); | ||
| 209 | queryWrapper.lt(MfEnterpriseChangeApprove::getCreateTime, createTime); | ||
| 210 | queryWrapper.orderByDesc(MfEnterpriseChangeApprove::getCreateTime); | ||
| 211 | List<MfEnterpriseChangeApprove> approveList = mfEnterpriseChangeApproveService.list(queryWrapper); | ||
| 212 | if(CollectionUtils.isEmpty(approveList)){ | ||
| 213 | return new ArrayList<>(); | ||
| 214 | } | ||
| 215 | List<ChangeApproveBean> beanList = getChangeBeanList(approveList); | ||
| 216 | try { | ||
| 217 | if(CollectionUtils.isEmpty(ChangeInfoUtil.areaList)){ | ||
| 218 | ChangeInfoUtil.areaList = configureFeign.getBoroughCodeName().getData(); | ||
| 219 | } | ||
| 220 | return ChangeInfoUtil.getChangeList(beanList); | ||
| 221 | } catch (IllegalAccessException e) { | ||
| 222 | e.printStackTrace(); | ||
| 223 | } | ||
| 224 | return new ArrayList<>(); | ||
| 225 | } | ||
| 226 | |||
| 227 | @Override | ||
| 228 | public List<ChangeInfoVO> beforeChangeList(String approveGuid){ | ||
| 229 | SimpleDateFormat simpleDateFormat = new SimpleDateFormat("yyyy-MM-dd HH:mm:ss"); | ||
| 230 | LambdaQueryWrapper<MfEnterpriseChangeApprove> queryWrapper = new LambdaQueryWrapper<>(); | ||
| 231 | queryWrapper.eq(MfEnterpriseChangeApprove::getApproveGuid, approveGuid); | ||
| 232 | // queryWrapper.apply("DATE_FORMAT(create_time, '%Y-%m-%d %H:%i:%s') = '" + simpleDateFormat.format(createTime) + "'"); | ||
| 233 | queryWrapper.orderByDesc(MfEnterpriseChangeApprove::getCreateTime); | ||
| 234 | List<MfEnterpriseChangeApprove> approveList = mfEnterpriseChangeApproveService.list(queryWrapper); | ||
| 235 | if(CollectionUtils.isEmpty(approveList)){ | ||
| 236 | return new ArrayList<>(); | ||
| 237 | } | ||
| 238 | List<EnterpriseServiceImpl.ChangeApproveBean> beanList = getChangeBeanList(approveList); | ||
| 239 | try { | ||
| 240 | if(CollectionUtils.isEmpty(ChangeInfoUtil.areaList)){ | ||
| 241 | ChangeInfoUtil.areaList = configureFeign.getBoroughCodeName().getData(); | ||
| 242 | } | ||
| 243 | return ChangeInfoUtil.getChangeList(beanList); | ||
| 244 | } catch (IllegalAccessException e) { | ||
| 245 | e.printStackTrace(); | ||
| 246 | } | ||
| 247 | return new ArrayList<>(); | ||
| 248 | } | ||
| 249 | |||
| 250 | @Override | ||
| 251 | public EnterpriseRSVO getEnterpriseDetailByName(String tenantName) { | ||
| 252 | LambdaQueryWrapper<MfEnterprise> queryWrapper = new LambdaQueryWrapper<>(); | ||
| 253 | queryWrapper.eq(MfEnterprise::getTenantName,tenantName); | ||
| 254 | List<MfEnterprise> list = mfEnterpriseService.list(queryWrapper); | ||
| 255 | if(CollectionUtils.isEmpty(list)){ | ||
| 256 | return null; | ||
| 257 | } | ||
| 258 | return convertToVO(list.get(0)); | ||
| 259 | } | ||
| 260 | |||
| 261 | /** 准备变更对比实体 */ | ||
| 262 | private List<ChangeApproveBean> getChangeBeanList(List<MfEnterpriseChangeApprove> list){ | ||
| 263 | List<ChangeApproveBean> beanList = new ArrayList<>(); | ||
| 264 | for(MfEnterpriseChangeApprove item : list){ | ||
| 265 | if("1".equals(item.getDataType())){ | ||
| 266 | ChangeApproveBean bean = new ChangeApproveBean(); | ||
| 267 | bean.oldBean = csbrBeanUtil.convert(item,MfEnterprise.class); | ||
| 268 | beanList.add(bean); | ||
| 269 | } | ||
| 270 | if("2".equals(item.getDataType())){ | ||
| 271 | ChangeApproveBean bean = beanList.get(beanList.size() - 1); | ||
| 272 | bean.newBean = csbrBeanUtil.convert(item,MfEnterprise.class); | ||
| 273 | } | ||
| 274 | } | ||
| 275 | return beanList; | ||
| 276 | } | ||
| 277 | |||
| 278 | public static class ChangeApproveBean{ | ||
| 279 | public MfEnterprise oldBean; | ||
| 280 | public MfEnterprise newBean; | ||
| 281 | } | ||
| 282 | |||
| 283 | /** | ||
| 284 | * 企业信息数据新增 | ||
| 285 | * @author xcq | ||
| 286 | * @date 2024-12-26 16:18 | ||
| 287 | * @param flowBaseVO | ||
| 288 | * @return void | ||
| 289 | */ | ||
| 290 | @GlobalTransactional(rollbackFor = Exception.class) | ||
| 291 | @Transactional(rollbackFor = Exception.class) | ||
| 292 | @Override | ||
| 293 | public void saveEnterprise(FlowRQBaseVO flowBaseVO) { | ||
| 294 | EnterpriseRQVO rqVO = (EnterpriseRQVO) flowBaseVO; | ||
| 295 | beforeSave(rqVO); | ||
| 296 | MfEnterprise entity = convertToEntity(rqVO); | ||
| 297 | // 发起审批流程或保存草稿 | ||
| 298 | AddApprovalDTO approvalDTO = getAddApprovalDTO(entity, rqVO); | ||
| 299 | super.startWorkFlow(rqVO, approvalDTO, entity::setBizApproveState); | ||
| 300 | // 业务数据保存 | ||
| 301 | boolean flag = mfEnterpriseService.save(entity); | ||
| 302 | if (!flag) { | ||
| 303 | throw new CsbrSystemException(SystemError.DATA_ADD_ERROR, rqVO.getImmediateApprove() ? | ||
| 304 | messageSourceUtil.submitMessage(FUNCTION_NAME) : messageSourceUtil.addMessage(FUNCTION_NAME)); | ||
| 305 | } | ||
| 306 | afterSave(entity, rqVO); | ||
| 307 | } | ||
| 308 | |||
| 309 | /** | ||
| 310 | * 企业信息数据修改 | ||
| 311 | * @author xcq | ||
| 312 | * @date 2024-12-26 16:18 | ||
| 313 | * @param flowBaseVO | ||
| 314 | * @return void | ||
| 315 | */ | ||
| 316 | @GlobalTransactional(rollbackFor = Exception.class) | ||
| 317 | @Override | ||
| 318 | public void updateEnterprise(FlowRQBaseVO flowBaseVO) { | ||
| 319 | EnterpriseRQVO rqVO = (EnterpriseRQVO) flowBaseVO; | ||
| 320 | // 将修改前数据查出来缓存下来,传入到修改后方法中,用于一些特殊逻辑处理,如某个值变化才进行 | ||
| 321 | // MfEnterprise oldEntity = mfEnterpriseService.getById(rqVO.getGuid()); | ||
| 322 | beforeUpdate(rqVO); | ||
| 323 | MfEnterprise entity = convertToEntity(rqVO); | ||
| 324 | // 发起审批流程或保存草稿 | ||
| 325 | AddApprovalDTO approvalDTO = getAddApprovalDTO(entity, rqVO); | ||
| 326 | super.startOrRestartWorkFlow(rqVO, rqVO.getBizApproveState(), approvalDTO, entity::setBizApproveState); | ||
| 327 | if (rqVO.getIsRestart()) { | ||
| 328 | // 重新提交 | ||
| 329 | againSubmitFlow(entity, rqVO, approvalDTO); | ||
| 330 | } else { | ||
| 331 | // 修改业务数据 | ||
| 332 | boolean flag = mfEnterpriseService.updateById(entity); | ||
| 333 | if (!flag) { | ||
| 334 | throw new CsbrSystemException(SystemError.DATA_UPDATE_ERROR, rqVO.getImmediateApprove() ? | ||
| 335 | messageSourceUtil.submitMessage(FUNCTION_NAME) : messageSourceUtil.updateMessage(FUNCTION_NAME)); | ||
| 336 | } | ||
| 337 | afterUpdate(entity, rqVO); | ||
| 338 | } | ||
| 339 | } | ||
| 340 | |||
| 341 | /** | ||
| 342 | * 重新提交企业信息 | ||
| 343 | * @author xcq | ||
| 344 | * @date 2024-12-26 16:18 | ||
| 345 | * @param entity | ||
| 346 | * @param rqVO | ||
| 347 | * @param approvalDTO | ||
| 348 | * @return void | ||
| 349 | */ | ||
| 350 | private void againSubmitFlow(MfEnterprise entity, EnterpriseRQVO rqVO, AddApprovalDTO approvalDTO) { | ||
| 351 | entity.setGuid(CommonUtil.newGuid()); | ||
| 352 | mfEnterpriseService.csbrBaseEntity(entity); | ||
| 353 | entity.setBizApproveState("A"); | ||
| 354 | // 保存新数据 | ||
| 355 | boolean flag = mfEnterpriseService.save(entity); | ||
| 356 | if (!flag) { | ||
| 357 | throw new CsbrSystemException(SystemError.DATA_ADD_ERROR, messageSourceUtil.addMessage(String.format("重新提交%s",FUNCTION_NAME))); | ||
| 358 | } | ||
| 359 | // 发起新的流程 | ||
| 360 | approvalDTO.setBizGuid(entity.getGuid()); | ||
| 361 | approvalDTO.setUrlParam(String.format("guid=%s&name=%s&tName=%s&fType=%s&type=detail",entity.getGuid(), entity.getTenantName(), | ||
| 362 | entity.getTenantName(),WorkFlowBizEnum.ENTERPRISE_APPLY.getValue())); | ||
| 363 | approvalFlowUtil.addApproval(approvalDTO); | ||
| 364 | afterSave(entity, rqVO); | ||
| 365 | } | ||
| 366 | |||
| 367 | /** | ||
| 368 | * 企业信息数据删除、并有相关的处理操作 | ||
| 369 | * @author xcq | ||
| 370 | * @date 2024-12-26 16:18 | ||
| 371 | * @param guids | ||
| 372 | * @return void | ||
| 373 | */ | ||
| 374 | @GlobalTransactional(rollbackFor = Exception.class) | ||
| 375 | @Override | ||
| 376 | public void removeByGuids(List<String> guids) { | ||
| 377 | if (CollectionUtils.isEmpty(guids)) { | ||
| 378 | // W00012 = {0}:参数[{1}]不能为空! | ||
| 379 | throw new CsbrSystemException(SystemError.DATA_INPUT_ERROR, messageSourceUtil.getMessage("W00012", | ||
| 380 | String.format("删除%s数据", FUNCTION_NAME), "数据唯一标识")); | ||
| 381 | } | ||
| 382 | String crossPlatformApproveState = ""; | ||
| 383 | for (String guid : guids) { | ||
| 384 | MfEnterprise entity = mfEnterpriseService.getById(guid); | ||
| 385 | if (entity == null) { | ||
| 386 | continue; | ||
| 387 | } | ||
| 388 | if (ApprovalStateEnum.CHECKING.getValue().equals(entity.getBizApproveState()) || | ||
| 389 | ApprovalStateEnum.PASSED.getValue().equals(entity.getBizApproveState())) { | ||
| 390 | throw new CsbrSystemException(SystemError.DATA_DEL_ERROR, "审批中和审批通过的数据不能删除!"); | ||
| 391 | } | ||
| 392 | mfEnterpriseService.removeById(guid); | ||
| 393 | afterRemove(entity); | ||
| 394 | crossPlatformApproveState = entity.getCrossPlatformApproveState(); | ||
| 395 | } | ||
| 396 | |||
| 397 | // 删除主平台数据 | ||
| 398 | if (!zqConfig.getIsMain() && StringUtils.isNotEmpty(crossPlatformApproveState)) { | ||
| 399 | JSONObject jsonObject = new JSONObject(); | ||
| 400 | jsonObject.put("zqSystemCode", SysFuncCode); | ||
| 401 | jsonObject.put("zqBizGuids", JSON.toJSONString(guids)); | ||
| 402 | jsonObject.put("isCollection", true); | ||
| 403 | invokeUtil.invokeMainDel(jsonObject, zqConfig.getAppKey(), zqConfig.getZqDelUrl()); | ||
| 404 | } | ||
| 405 | |||
| 406 | // 删除流程数据 | ||
| 407 | approvalFlowUtil.removeApproveByBizGuids(guids); | ||
| 408 | } | ||
| 409 | |||
| 410 | /** | ||
| 411 | * 流程结束后进行业务回调 | ||
| 412 | * @author xcq | ||
| 413 | * @date 2024-12-26 16:18 | ||
| 414 | * @param dto | ||
| 415 | * @return void | ||
| 416 | */ | ||
| 417 | @Transactional(rollbackFor = Exception.class) | ||
| 418 | @Override | ||
| 419 | public void flowCallBack(BizCallbackDTO dto) { | ||
| 420 | MfEnterprise entity = mfEnterpriseService.getById(dto.getBizGuid()); | ||
| 421 | if (entity == null) { | ||
| 422 | throw new CsbrSystemException(SystemError.DATA_NOT_EXISTS, messageSourceUtil.notExistsToSelectMessage(FUNCTION_NAME)); | ||
| 423 | } | ||
| 424 | // 同步更新审批状态 | ||
| 425 | LambdaUpdateWrapper<MfEnterprise> updateWrapper = new LambdaUpdateWrapper<>(); | ||
| 426 | updateWrapper.set(MfEnterprise::getBizApproveState, dto.getApprovalState()); | ||
| 427 | updateWrapper.eq(MfEnterprise::getGuid, dto.getBizGuid()); | ||
| 428 | boolean flag = mfEnterpriseService.update(updateWrapper); | ||
| 429 | if (!flag) { | ||
| 430 | throw new CsbrSystemException(SystemError.DATA_UPDATE_ERROR, messageSourceUtil.updateMessage(String.format("%s的业务审批状态", FUNCTION_NAME))); | ||
| 431 | } | ||
| 432 | if (ApprovalStateEnum.PASSED.getValue().equals(dto.getApprovalState()) && !dto.getIsZqPlatformApprove() && StringUtils.isEmpty(entity.getZqName())) { | ||
| 433 | String tenantName = personelFeign.getAllTenantGuidNameMap().getData().get(entity.getTenantGuid()); | ||
| 434 | if("非认证会员".equals(tenantName)){ | ||
| 435 | //删除原帐号并新增正式会员 | ||
| 436 | TenantRQVO vo = csbrBeanUtil.convert(entity,TenantRQVO.class); | ||
| 437 | //新增会员时guid必须保证为空 | ||
| 438 | vo.setGuid(null); | ||
| 439 | vo.setTenantType(null); | ||
| 440 | vo.setContactTel(entity.getContactTel()); | ||
| 441 | vo.setBizGuid(dto.getBizGuid()); | ||
| 442 | vo.setPersonIncharge(entity.getJuridicalPerson()); | ||
| 443 | vo.setBizState("Y"); | ||
| 444 | vo.setRegistrationDate(DateUtil.getDateToLocal(entity.getRegistrationDate())); | ||
| 445 | vo.setTenantLicList(getTenantLicList(entity.getBusinessLicenseJson())); | ||
| 446 | vo.setCompanyAddress(String.format("%s/%s/%s",entity.getProvince(),entity.getCity(),entity.getDistrict())); | ||
| 447 | vo.setProvince(null); | ||
| 448 | vo.setCity(null); | ||
| 449 | vo.setDistrict(null); | ||
| 450 | personelFeign.authTenant(vo).getData(); | ||
| 451 | } | ||
| 452 | else{ | ||
| 453 | updateTenant(entity); | ||
| 454 | } | ||
| 455 | } | ||
| 456 | |||
| 457 | } | ||
| 458 | |||
| 459 | @Override | ||
| 460 | public void crossFlowCallBack(BizCallbackDTO dto) { | ||
| 461 | MfEnterprise entity = mfEnterpriseService.getById(dto.getBizGuid()); | ||
| 462 | if (entity == null) { | ||
| 463 | throw new CsbrSystemException(SystemError.DATA_NOT_EXISTS, messageSourceUtil.notExistsToSelectMessage(FUNCTION_NAME)); | ||
| 464 | } | ||
| 465 | // 同步更新审批状态 | ||
| 466 | LambdaUpdateWrapper<MfEnterprise> updateWrapper = new LambdaUpdateWrapper<>(); | ||
| 467 | updateWrapper.set(MfEnterprise::getBizApproveState, dto.getApprovalState()); | ||
| 468 | updateWrapper.set(MfEnterprise::getCrossPlatformApproveState, dto.getApprovalState()); | ||
| 469 | updateWrapper.eq(MfEnterprise::getGuid, dto.getBizGuid()); | ||
| 470 | boolean flag = mfEnterpriseService.update(updateWrapper); | ||
| 471 | if (!flag) { | ||
| 472 | throw new CsbrSystemException(SystemError.DATA_UPDATE_ERROR, messageSourceUtil.updateMessage(String.format("%s的业务审批状态", FUNCTION_NAME))); | ||
| 473 | } | ||
| 474 | if (ApprovalStateEnum.PASSED.getValue().equals(dto.getApprovalState())) { | ||
| 475 | String tenantName = personelFeign.getAllTenantGuidNameMap().getData().get(entity.getTenantGuid()); | ||
| 476 | if("非认证会员".equals(tenantName)){ | ||
| 477 | //删除原帐号并新增正式会员 | ||
| 478 | TenantRQVO vo = csbrBeanUtil.convert(entity,TenantRQVO.class); | ||
| 479 | //新增会员时guid必须保证为空 | ||
| 480 | vo.setGuid(null); | ||
| 481 | vo.setTenantType(null); | ||
| 482 | vo.setContactTel(entity.getContactTel()); | ||
| 483 | vo.setBizGuid(dto.getBizGuid()); | ||
| 484 | vo.setPersonIncharge(entity.getJuridicalPerson()); | ||
| 485 | vo.setBizState("Y"); | ||
| 486 | vo.setRegistrationDate(DateUtil.getDateToLocal(entity.getRegistrationDate())); | ||
| 487 | vo.setTenantLicList(getTenantLicList(entity.getBusinessLicenseJson())); | ||
| 488 | vo.setCompanyAddress(String.format("%s/%s/%s",entity.getProvince(),entity.getCity(),entity.getDistrict())); | ||
| 489 | vo.setProvince(null); | ||
| 490 | vo.setCity(null); | ||
| 491 | vo.setDistrict(null); | ||
| 492 | personelFeign.authTenant(vo).getData(); | ||
| 493 | } | ||
| 494 | else{ | ||
| 495 | updateTenant(entity); | ||
| 496 | } | ||
| 497 | } | ||
| 498 | } | ||
| 499 | |||
| 500 | private List<TenantLicRQVO> getTenantLicList(String json) { | ||
| 501 | if(StringUtils.isBlank(json)){ | ||
| 502 | return null; | ||
| 503 | } | ||
| 504 | JSONArray array = JSON.parseArray(json); | ||
| 505 | if(array.size() == 0){ | ||
| 506 | return null; | ||
| 507 | } | ||
| 508 | JSONArray itemArray = new JSONArray(); | ||
| 509 | for(int i = 0; i < array.size(); i++){ | ||
| 510 | JSONObject obj = array.getJSONObject(i); | ||
| 511 | //格式转换 | ||
| 512 | JSONObject itemOjb = new JSONObject(); | ||
| 513 | itemOjb.put("name",obj.get("name")); | ||
| 514 | itemOjb.put("path",obj.get("url")); | ||
| 515 | itemArray.add(itemOjb); | ||
| 516 | } | ||
| 517 | TenantLicRQVO item = new TenantLicRQVO(); | ||
| 518 | item.setLicenseType("1"); | ||
| 519 | item.setPictContentJson(JSON.toJSONString(itemArray)); | ||
| 520 | |||
| 521 | List<TenantLicRQVO> list = new ArrayList<>(); | ||
| 522 | list.add(item); | ||
| 523 | return list; | ||
| 524 | } | ||
| 525 | |||
| 526 | /** 将此账号提交的数据需求迁移到新的企业 */ | ||
| 527 | @Override | ||
| 528 | @Transactional(rollbackFor = Exception.class) | ||
| 529 | public void moveOldData(TenantRQVO vo){ | ||
| 530 | LambdaQueryWrapper<MfDemand> queryWrapper = new LambdaQueryWrapper<>(); | ||
| 531 | queryWrapper.eq(MfDemand::getCreateUserName, vo.getTenantName()); | ||
| 532 | mfDemandService.csbrExcludeShardingLambdaQueryWrapper(queryWrapper); | ||
| 533 | List<MfDemand> list = mfDemandService.list(queryWrapper); | ||
| 534 | if(CollectionUtils.isEmpty(list)){ | ||
| 535 | return; | ||
| 536 | } | ||
| 537 | |||
| 538 | List<MfDemand> newList = new ArrayList<>(); | ||
| 539 | for(MfDemand item : list){ | ||
| 540 | MfDemand newItem = csbrBeanUtil.convert(item,MfDemand.class,true); | ||
| 541 | newItem.setGuid(CommonUtil.newGuid()); | ||
| 542 | newItem.setTenantGuid(vo.getGuid()); | ||
| 543 | newItem.setShardingFlag(vo.getShardingFlag()); | ||
| 544 | newItem.setRequirementUnit(vo.getTenantName()); | ||
| 545 | newItem.setCreateUserName(vo.getContacts()); | ||
| 546 | newItem.setUpdateUserName(vo.getContacts()); | ||
| 547 | newList.add(newItem); | ||
| 548 | } | ||
| 549 | mfDemandService.saveBatch(newList); | ||
| 550 | mfDemandService.removeByIds(list); | ||
| 551 | } | ||
| 552 | |||
| 553 | /** 仅更新会员本表信息 */ | ||
| 554 | @Override | ||
| 555 | public void updateTenant(MfEnterprise vo) { | ||
| 556 | //同步更新会员表 | ||
| 557 | TenantRQVO tenantVO = csbrBeanUtil.convert(vo,TenantRQVO.class); | ||
| 558 | tenantVO.setGuid(vo.getTenantGuid()); | ||
| 559 | tenantVO.setPersonIncharge(vo.getJuridicalPerson()); | ||
| 560 | tenantVO.setTenantName(vo.getTenantName()); | ||
| 561 | tenantVO.setRegisteredCapital(vo.getRegisteredCapital()); | ||
| 562 | tenantVO.setRegistrationDate(DateUtil.getDateToLocal(vo.getRegistrationDate())); | ||
| 563 | tenantVO.setBankTaxNo(vo.getBankTaxNo()); | ||
| 564 | tenantVO.setBusinessLicenseScope(vo.getBusinessLicenseScope()); | ||
| 565 | tenantVO.setPersonIncharge(vo.getJuridicalPerson()); | ||
| 566 | tenantVO.setContacts(vo.getContacts()); | ||
| 567 | tenantVO.setContactTel(vo.getContactTel()); | ||
| 568 | tenantVO.setCompanyAddress(String.format("%s/%s/%s",vo.getProvince(),vo.getCity(),vo.getDistrict())); | ||
| 569 | tenantVO.setTenantLicList(getTenantLicList(vo.getBusinessLicenseJson())); | ||
| 570 | personelFeign.changeUpdate(tenantVO); | ||
| 571 | } | ||
| 572 | |||
| 573 | @Override | ||
| 574 | public EnterpriseRSVO getEnterpriseDetailByLogonUser(String logonUser) { | ||
| 575 | // 根据登陆人信息查询业务数据 | ||
| 576 | LambdaQueryWrapper<MfEnterprise> queryWrapper = Wrappers.lambdaQuery(MfEnterprise.class); | ||
| 577 | queryWrapper.eq(MfEnterprise::getLogonUser, logonUser); | ||
| 578 | queryWrapper.orderByDesc(MfEnterprise::getCreateTime); | ||
| 579 | List<MfEnterprise> mfEnterprises = mfEnterpriseService.list(queryWrapper); | ||
| 580 | if (ObjectUtils.isEmpty(mfEnterprises)) { | ||
| 581 | return null; | ||
| 582 | } | ||
| 583 | |||
| 584 | // 判断业务数据是否有通过 | ||
| 585 | Optional<MfEnterprise> enterpriseOptional = mfEnterprises.stream().filter(item -> | ||
| 586 | ApprovalStateEnum.PASSED.getValue().equals(item.getBizApproveState()) | ||
| 587 | || "B".equals(item.getBizApproveState()) | ||
| 588 | || ApprovalStateEnum.CHECKING.getValue().equals(item.getBizApproveState()) | ||
| 589 | || "E".equals(item.getBizApproveState())).findFirst(); | ||
| 590 | if (enterpriseOptional.isEmpty()) { | ||
| 591 | return null; | ||
| 592 | } | ||
| 593 | MfEnterprise mfEnterprise = enterpriseOptional.get(); | ||
| 594 | EnterpriseRSVO enterpriseRSVO = convertToVO(mfEnterprise); | ||
| 595 | |||
| 596 | // 查询变更历史 | ||
| 597 | LambdaQueryWrapper<MfEnterpriseChangeApprove> lambdaQueryWrapper = new LambdaQueryWrapper<>(); | ||
| 598 | lambdaQueryWrapper.eq(MfEnterpriseChangeApprove::getSourceGuid, mfEnterprise.getGuid()); | ||
| 599 | lambdaQueryWrapper.orderByDesc(MfEnterpriseChangeApprove::getCreateTime); | ||
| 600 | List<MfEnterpriseChangeApprove> approveList = mfEnterpriseChangeApproveService.list(lambdaQueryWrapper); | ||
| 601 | if(CollectionUtils.isEmpty(approveList)){ | ||
| 602 | return enterpriseRSVO; | ||
| 603 | } | ||
| 604 | |||
| 605 | // 判断最新变更数据是否是审批中 审批中显示最新数据 驳回或通过显示最新一次审批通过数据 | ||
| 606 | if ("B".equals(enterpriseRSVO.getBizApproveState())) { | ||
| 607 | Optional<MfEnterpriseChangeApprove> changeApproveOptFirst = approveList.stream().filter(item -> "2".equals(item.getDataType())).findFirst(); | ||
| 608 | if (changeApproveOptFirst.isPresent()) { | ||
| 609 | enterpriseRSVO = csbrBeanUtil.convert(changeApproveOptFirst.get(), EnterpriseRSVO.class); | ||
| 610 | enterpriseRSVO.setBizApproveState(mfEnterprise.getBizApproveState()); | ||
| 611 | } | ||
| 612 | } | ||
| 613 | |||
| 614 | // 只显示审批通过的变更历史 | ||
| 615 | List<MfEnterpriseChangeApprove> passChangeApproves = approveList.stream().filter(item -> ApprovalStateEnum.PASSED.getValue().equals(item.getBizApproveState())).toList(); | ||
| 616 | if (ObjectUtils.isNotEmpty(passChangeApproves)) { | ||
| 617 | List<ChangeApproveBean> beanList = getChangeBeanList(passChangeApproves); | ||
| 618 | try { | ||
| 619 | if(CollectionUtils.isEmpty(ChangeInfoUtil.areaList)){ | ||
| 620 | ChangeInfoUtil.areaList = configureFeign.getBoroughCodeName().getData(); | ||
| 621 | } | ||
| 622 | enterpriseRSVO.setChangeList(ChangeInfoUtil.getChangeList(beanList)); | ||
| 623 | } catch (IllegalAccessException e) { | ||
| 624 | e.printStackTrace(); | ||
| 625 | } | ||
| 626 | } | ||
| 627 | |||
| 628 | return enterpriseRSVO; | ||
| 629 | } | ||
| 630 | |||
| 631 | @Override | ||
| 632 | public Boolean check(EnterpriseRQVO vo) { | ||
| 633 | String tenantName = personelFeign.getAllTenantGuidNameMap().getData().get(vo.getTenantGuid()); | ||
| 634 | TenantRQVO tenant = csbrBeanUtil.convert(vo,TenantRQVO.class); | ||
| 635 | if("非认证会员".equals(tenantName)){ | ||
| 636 | tenant.setGuid(null); | ||
| 637 | } | ||
| 638 | else{ | ||
| 639 | tenant.setGuid(vo.getTenantGuid()); | ||
| 640 | } | ||
| 641 | personelFeign.checkTenant(tenant); | ||
| 642 | return true; | ||
| 643 | } | ||
| 644 | |||
| 645 | /** | ||
| 646 | * 获取发起流程参数 | ||
| 647 | * | ||
| 648 | * @param entity | ||
| 649 | * @param rqVO | ||
| 650 | * @return com.csbr.cloud.workflow.domain.dto.appove.AddApprovalDTO | ||
| 651 | * @author xcq | ||
| 652 | * @date 2024-12-26 16:18 | ||
| 653 | */ | ||
| 654 | private AddApprovalDTO getAddApprovalDTO(MfEnterprise entity, EnterpriseRQVO rqVO) { | ||
| 655 | AddApprovalDTO approvalDTO = new AddApprovalDTO(WorkFlowBizEnum.ENTERPRISE_APPLY.getValue(), entity.getGuid()); | ||
| 656 | approvalDTO.setFuncCode(SysFuncCode); | ||
| 657 | approvalDTO.setUrlParam(String.format("guid=%s&name=%s&tName=%s&fType=%s&type=detail", entity.getGuid(), entity.getTenantName(), | ||
| 658 | entity.getTenantName(), WorkFlowBizEnum.ENTERPRISE_APPLY.getValue())); | ||
| 659 | // 流程消息中的变量替换参数 | ||
| 660 | approvalDTO.setFlowMessageBody(entity.getTenantName()); | ||
| 661 | // 流程列表数据核心param参数处理 | ||
| 662 | approvalDTO.setParam1(entity.getTenantName()); | ||
| 663 | approvalDTO.setParam2(entity.getTenantType()); | ||
| 664 | approvalDTO.setParam3(entity.getSocialCreditCode()); | ||
| 665 | approvalDTO.setParam4(String.format("%s_%s_%s",entity.getJuridicalPerson(),entity.getContacts(),entity.getContactTel())); | ||
| 666 | |||
| 667 | // 增加跨服务审批字段 | ||
| 668 | rqVO.setGuid(entity.getGuid()); | ||
| 669 | approvalDTO.setBizData(JSON.toJSONString(rqVO)); | ||
| 670 | |||
| 671 | return approvalDTO; | ||
| 672 | } | ||
| 673 | |||
| 674 | |||
| 675 | |||
| 676 | /** | ||
| 677 | * 企业信息新新增前置处理 | ||
| 678 | * @author xcq | ||
| 679 | * @date 2024-12-26 16:18 | ||
| 680 | * @param rqVO | ||
| 681 | * @return void | ||
| 682 | */ | ||
| 683 | private void beforeSave(EnterpriseRQVO rqVO) { | ||
| 684 | //region 1.输入基础验证 | ||
| 685 | check(rqVO); | ||
| 686 | //endregion | ||
| 687 | |||
| 688 | //region 2.数据验证特殊处理 | ||
| 689 | //region 2.1.业务合规性验证 | ||
| 690 | //endregion 2.1.业务合规性验证 | ||
| 691 | |||
| 692 | //region 2.2.业务数据验证 | ||
| 693 | //endregion 2.2.业务数据验证 | ||
| 694 | |||
| 695 | //endregion 2.数据验证特殊处理 | ||
| 696 | |||
| 697 | //region 3.数据转换处理 | ||
| 698 | |||
| 699 | //region 3.1.数据过程转换 | ||
| 700 | //endregion 3.1.数据过程转换 | ||
| 701 | |||
| 702 | //endregion 3.数据转换处理 | ||
| 703 | |||
| 704 | //region 4.数据过滤与补充处理 | ||
| 705 | |||
| 706 | //endregion 4.数据过滤与补充处理 | ||
| 707 | |||
| 708 | //region 5.过程处理 | ||
| 709 | |||
| 710 | //region 5.1.计算逻辑处理 | ||
| 711 | //endregion 5.1.计算逻辑处理 | ||
| 712 | |||
| 713 | //region 5.2.业务逻辑处理 | ||
| 714 | //endregion 5.2.业务逻辑处理 | ||
| 715 | |||
| 716 | //endregion 5.过程处理 | ||
| 717 | } | ||
| 718 | |||
| 719 | /** | ||
| 720 | * 企业信息新增后置处理 | ||
| 721 | * @author xcq | ||
| 722 | * @date 2024-12-26 16:18 | ||
| 723 | * @param entity | ||
| 724 | * @param rqVO | ||
| 725 | * @return void | ||
| 726 | */ | ||
| 727 | public void afterSave(MfEnterprise entity, EnterpriseRQVO rqVO) { | ||
| 728 | // 保存认证数据 | ||
| 729 | MfEnterpriseChangeApprove enterpriseChangeApprove = csbrBeanUtil.convert(entity, MfEnterpriseChangeApprove.class); | ||
| 730 | enterpriseChangeApprove.setSourceGuid(entity.getGuid()); | ||
| 731 | enterpriseChangeApprove.setDataType("0"); | ||
| 732 | mfEnterpriseChangeApproveService.save(enterpriseChangeApprove); | ||
| 733 | } | ||
| 734 | |||
| 735 | /** | ||
| 736 | * 企业信息修改前置校验、处理 | ||
| 737 | * @author xcq | ||
| 738 | * @date 2024-12-26 16:18 | ||
| 739 | * @param rqVO | ||
| 740 | * @return void | ||
| 741 | */ | ||
| 742 | private void beforeUpdate(EnterpriseRQVO rqVO) { | ||
| 743 | //region 1.输入基础验证 | ||
| 744 | check(rqVO); | ||
| 745 | if (StringUtils.isBlank(rqVO.getGuid())) { | ||
| 746 | // W00012 = {0}:参数[{1}]不能为空! | ||
| 747 | throw new CsbrSystemException(SystemError.DATA_INPUT_ERROR, messageSourceUtil.getMessage("W00010", String.format("修改%s数据",FUNCTION_NAME), "数据唯一标识")); | ||
| 748 | } | ||
| 749 | //endregion | ||
| 750 | |||
| 751 | //region 2.数据验证特殊处理 | ||
| 752 | //region 2.1.业务合规性验证 | ||
| 753 | //endregion 2.1.业务合规性验证 | ||
| 754 | |||
| 755 | //region 2.2.业务数据验证 | ||
| 756 | LambdaQueryWrapper<MfEnterprise> queryWrapper = new LambdaQueryWrapper<>(); | ||
| 757 | queryWrapper.eq(MfEnterprise::getGuid, rqVO.getGuid()); | ||
| 758 | queryWrapper.select(MfEnterprise::getGuid, MfEnterprise::getBizApproveState); | ||
| 759 | MfEnterprise entity = mfEnterpriseService.getOne(queryWrapper); | ||
| 760 | if (entity == null) { | ||
| 761 | throw new CsbrSystemException(SystemError.DATA_NOT_EXISTS, messageSourceUtil.notExistsToUpdateMessage(FUNCTION_NAME)); | ||
| 762 | } | ||
| 763 | //endregion 2.2.业务数据验证 | ||
| 764 | |||
| 765 | //endregion 2.数据验证特殊处理 | ||
| 766 | rqVO.setBizApproveState(entity.getBizApproveState()); | ||
| 767 | |||
| 768 | //region 3.数据转换处理 | ||
| 769 | |||
| 770 | //region 3.1.数据过程转换 | ||
| 771 | //endregion 3.1.数据过程转换 | ||
| 772 | |||
| 773 | //endregion 3.数据转换处理 | ||
| 774 | |||
| 775 | //region 4.数据过滤与补充处理 | ||
| 776 | //endregion 4.数据过滤与补充处理 | ||
| 777 | |||
| 778 | //region 5.过程处理 | ||
| 779 | |||
| 780 | //region 5.1.计算逻辑处理 | ||
| 781 | //endregion 5.1.计算逻辑处理 | ||
| 782 | |||
| 783 | //region 5.2.业务逻辑处理 | ||
| 784 | //endregion 5.2.业务逻辑处理 | ||
| 785 | |||
| 786 | //endregion 5.过程处理 | ||
| 787 | } | ||
| 788 | |||
| 789 | /** | ||
| 790 | * 企业信息修改后置处理 | ||
| 791 | * @author xcq | ||
| 792 | * @date 2024-12-26 16:18 | ||
| 793 | * @param entity | ||
| 794 | * @param rqVO | ||
| 795 | * @return void | ||
| 796 | */ | ||
| 797 | public void afterUpdate(MfEnterprise entity, EnterpriseRQVO rqVO) { | ||
| 798 | // 修改认证记录 | ||
| 799 | MfEnterpriseChangeApprove enterpriseChangeApprove = csbrBeanUtil.convert(entity, MfEnterpriseChangeApprove.class); | ||
| 800 | enterpriseChangeApprove.setSourceGuid(entity.getGuid()); | ||
| 801 | enterpriseChangeApprove.setDataType("0"); | ||
| 802 | mfEnterpriseChangeApproveService.updateById(enterpriseChangeApprove); | ||
| 803 | } | ||
| 804 | |||
| 805 | |||
| 806 | /** | ||
| 807 | * 企业信息删除前置处理 | ||
| 808 | * @author xcq | ||
| 809 | * @date 2024-12-26 16:18 | ||
| 810 | * @param entity | ||
| 811 | * @return void | ||
| 812 | */ | ||
| 813 | private void beforeRemove(MfEnterprise entity) { | ||
| 814 | if (entity == null) { | ||
| 815 | return; | ||
| 816 | } | ||
| 817 | if (ApprovalStateEnum.CHECKING.getValue().equals(entity.getBizApproveState()) || | ||
| 818 | ApprovalStateEnum.PASSED.getValue().equals(entity.getBizApproveState())) { | ||
| 819 | throw new CsbrSystemException(SystemError.DATA_DEL_ERROR, "审批中和审批通过的数据不能删除!"); | ||
| 820 | } | ||
| 821 | } | ||
| 822 | |||
| 823 | /** | ||
| 824 | * 企业信息删除后置处理 | ||
| 825 | * @author xcq | ||
| 826 | * @date 2024-12-26 16:18 | ||
| 827 | * @param entity | ||
| 828 | * @return void | ||
| 829 | */ | ||
| 830 | private void afterRemove(MfEnterprise entity) { | ||
| 831 | |||
| 832 | } | ||
| 833 | |||
| 834 | /** | ||
| 835 | * 企业信息查询方法前置验证、处理 | ||
| 836 | * @author xcq | ||
| 837 | * @date 2024-12-26 16:18 | ||
| 838 | * @param rqQueryVO | ||
| 839 | * @return void | ||
| 840 | */ | ||
| 841 | private void beforeQuery(EnterpriseQueryVO rqQueryVO) { | ||
| 842 | rqQueryVO.setIsNeedQuery(true); | ||
| 843 | if (approvalFlowUtil.isQueryBizGuid(rqQueryVO)) { | ||
| 844 | rqQueryVO.setFlowType(WorkFlowBizEnum.ENTERPRISE_APPLY.getValue()); | ||
| 845 | List<String> bizGuidList = approvalFlowUtil.getApprovalCrossTenantBizGuids(rqQueryVO); | ||
| 846 | if (CollectionUtils.isEmpty(bizGuidList)) { | ||
| 847 | rqQueryVO.setIsNeedQuery(false); | ||
| 848 | } else { | ||
| 849 | rqQueryVO.setGuidList(bizGuidList); | ||
| 850 | } | ||
| 851 | } | ||
| 852 | } | ||
| 853 | |||
| 854 | /** | ||
| 855 | * 企业信息查询方法后置数据转换、处理 | ||
| 856 | * @author xcq | ||
| 857 | * @date 2024-12-26 16:18 | ||
| 858 | * @param pageList 数据库查询数据 | ||
| 859 | * @param rsPageList 返回的最终数据 | ||
| 860 | * @return void | ||
| 861 | */ | ||
| 862 | private void afterQuery(PageListVO<MfEnterprise> pageList, PageListVO<EnterpriseRSVO> rsPageList) { | ||
| 863 | if (CollectionUtils.isNotEmpty(pageList.getRecords())) { | ||
| 864 | rsPageList.setRecords(convertToVO(pageList.getRecords())); | ||
| 865 | } | ||
| 866 | // 需要特殊处理数据时使用 | ||
| 867 | /*if(CollectionUtils.isNotEmpty(pageList.getRecords())){ | ||
| 868 | List<EnterpriseRSVO> results = new ArrayList<>(); | ||
| 869 | for (MfEnterprise item : pageList.getRecords()){ | ||
| 870 | EnterpriseRSVO vo = convertToVO(item); | ||
| 871 | results.add(vo); | ||
| 872 | } | ||
| 873 | rsPageList.setRecords(results); | ||
| 874 | }*/ | ||
| 875 | } | ||
| 876 | |||
| 877 | //region 辅助操作 | ||
| 878 | |||
| 879 | /** | ||
| 880 | * 企业信息实体数据转换为视图对象数据(多个) | ||
| 881 | * @author xcq | ||
| 882 | * @date 2024-12-26 16:18 | ||
| 883 | * @param entityList 实体数据列表 | ||
| 884 | * @return java.util.List<com.csbr.qingcloud.portal.domain.vo.EnterpriseRSVO> 视图对象列表 | ||
| 885 | */ | ||
| 886 | private List<EnterpriseRSVO> convertToVO(List<MfEnterprise> entityList) { | ||
| 887 | if (CollectionUtils.isEmpty(entityList)) { | ||
| 888 | // W00012 = {0}:参数[{1}]不能为空! | ||
| 889 | throw new CsbrSystemException(SystemError.DATA_INPUT_ERROR, messageSourceUtil.getMessage("W00012", | ||
| 890 | "实体数据转换为视图对象实体数据", "实体数据")); | ||
| 891 | } | ||
| 892 | List<EnterpriseRSVO> voList = new ArrayList<>(entityList.size()); | ||
| 893 | for (MfEnterprise item : entityList) { | ||
| 894 | EnterpriseRSVO vo = convertToVO(item); | ||
| 895 | voList.add(vo); | ||
| 896 | } | ||
| 897 | return voList; | ||
| 898 | } | ||
| 899 | |||
| 900 | /** | ||
| 901 | * 企业信息实体数据转换为视图对象数据 | ||
| 902 | * @author xcq | ||
| 903 | * @date 2024-12-26 16:18 | ||
| 904 | * @param entity | ||
| 905 | * @return com.csbr.qingcloud.portal.domain.vo.EnterpriseRSVO | ||
| 906 | */ | ||
| 907 | private EnterpriseRSVO convertToVO(MfEnterprise entity) { | ||
| 908 | EnterpriseRSVO vo = csbrBeanUtil.convert(entity, EnterpriseRSVO.class); | ||
| 909 | //流程数据处理 | ||
| 910 | vo.setApproveVO(approvalFlowUtil.getApprovalCrossTenantInfo(entity.getGuid())); | ||
| 911 | if(CollectionUtils.isEmpty(ChangeInfoUtil.areaList)){ | ||
| 912 | ChangeInfoUtil.areaList = configureFeign.getBoroughCodeName().getData(); | ||
| 913 | } | ||
| 914 | vo.setVenue(ChangeInfoUtil.getVenue(vo.getProvince(),vo.getCity(),vo.getDistrict())); | ||
| 915 | vo.setBusinessLicenseStartEnd(ChangeInfoUtil.getStartEnd(vo.getBusinessLicenseTerm(),vo.getBusinessLicenseStartDate(),vo.getBusinessLicenseEndDate())); | ||
| 916 | return vo; | ||
| 917 | } | ||
| 918 | |||
| 919 | |||
| 920 | /** | ||
| 921 | * 企业信息新增、修改和其他情况的参数转换为实体 | ||
| 922 | * @author xcq | ||
| 923 | * @date 2024-12-26 16:18 | ||
| 924 | * @param vo | ||
| 925 | * @return com.csbr.qingcloud.portal.mybatis.entity.MfEnterprise | ||
| 926 | */ | ||
| 927 | private MfEnterprise convertToEntity(EnterpriseRQVO vo) { | ||
| 928 | MfEnterprise entity = csbrBeanUtil.convert(vo, MfEnterprise.class); | ||
| 929 | // 新增时数据默认guid赋值,转换后该guid可能别使用 | ||
| 930 | if (StringUtils.isBlank(vo.getGuid())) { | ||
| 931 | entity.setGuid(CommonUtil.newGuid()); | ||
| 932 | } | ||
| 933 | return entity; | ||
| 934 | } | ||
| 935 | |||
| 936 | //endregion | ||
| 937 | |||
| 938 | } |
| 1 | package com.csbr.qingcloud.portal.service.impl; | ||
| 2 | |||
| 3 | import com.alibaba.fastjson.JSON; | ||
| 4 | import com.baomidou.mybatisplus.core.conditions.query.LambdaQueryWrapper; | ||
| 5 | import com.baomidou.mybatisplus.core.conditions.update.LambdaUpdateWrapper; | ||
| 6 | import com.csbr.cloud.common.entity.DictModel; | ||
| 7 | import com.csbr.cloud.common.enums.SystemError; | ||
| 8 | import com.csbr.cloud.common.enums.WorkFlowBizEnum; | ||
| 9 | import com.csbr.qingcloud.portal.feign.ConfigureFeign; | ||
| 10 | import com.csbr.qingcloud.portal.mybatis.entity.MfServicerMaintainDetail; | ||
| 11 | import com.csbr.qingcloud.portal.mybatis.service.MfServicerMaintainDetailService; | ||
| 12 | import csbr.cloud.entity.enums.ApprovalStateEnum; | ||
| 13 | import com.csbr.cloud.common.exception.CsbrSystemException; | ||
| 14 | import com.csbr.cloud.common.util.CommonUtil; | ||
| 15 | import com.csbr.cloud.common.util.CsbrBeanUtil; | ||
| 16 | import com.csbr.cloud.workflow.util.ApprovalFlowUtil; | ||
| 17 | import com.csbr.cloud.workflow.util.FlowAbstractImpl; | ||
| 18 | import com.csbr.cloud.common.util.MessageSourceUtil; | ||
| 19 | import csbr.cloud.entity.domain.base.vo.PageListVO; | ||
| 20 | import com.csbr.cloud.workflow.domain.vo.appove.FlowRQBaseVO; | ||
| 21 | import com.csbr.cloud.workflow.domain.dto.appove.AddApprovalDTO; | ||
| 22 | import com.csbr.cloud.workflow.domain.dto.callback.BizCallbackDTO; | ||
| 23 | import com.csbr.qingcloud.portal.domain.vo.ServicerMaintainQueryVO; | ||
| 24 | import com.csbr.qingcloud.portal.domain.vo.ServicerMaintainRQVO; | ||
| 25 | import com.csbr.qingcloud.portal.domain.vo.ServicerMaintainRSVO; | ||
| 26 | import com.csbr.qingcloud.portal.mybatis.entity.MfServicerMaintain; | ||
| 27 | import com.csbr.qingcloud.portal.mybatis.service.MfServicerMaintainService; | ||
| 28 | import com.csbr.qingcloud.portal.service.ServicerMaintainService; | ||
| 29 | import jakarta.annotation.Resource; | ||
| 30 | import lombok.extern.slf4j.Slf4j; | ||
| 31 | import org.apache.commons.collections.CollectionUtils; | ||
| 32 | import org.apache.commons.lang3.StringUtils; | ||
| 33 | import org.springframework.stereotype.Service; | ||
| 34 | import io.seata.spring.annotation.GlobalTransactional; | ||
| 35 | import org.springframework.transaction.annotation.Transactional; | ||
| 36 | |||
| 37 | import java.util.ArrayList; | ||
| 38 | import java.util.Collections; | ||
| 39 | import java.util.List; | ||
| 40 | |||
| 41 | /** | ||
| 42 | * @program: D:/git/ms-data-circulation-portal-service | ||
| 43 | * @description: 服务商维护业务逻辑实现 | ||
| 44 | * @author: xcq | ||
| 45 | * @create: 2024-12-31 18:49 | ||
| 46 | **/ | ||
| 47 | @Slf4j | ||
| 48 | @Service | ||
| 49 | public class ServicerMaintainServiceImpl extends FlowAbstractImpl implements ServicerMaintainService { | ||
| 50 | |||
| 51 | /** | ||
| 52 | * 功能名称 | ||
| 53 | */ | ||
| 54 | private static final String FUNCTION_NAME = "服务商维护"; | ||
| 55 | |||
| 56 | /** | ||
| 57 | * 流程类型 | ||
| 58 | */ | ||
| 59 | private static final String FLOW_TYPE = WorkFlowBizEnum.SERVICE_MAINTAIN.getValue(); | ||
| 60 | |||
| 61 | @Resource | ||
| 62 | private MfServicerMaintainService mfServicerMaintainService; | ||
| 63 | |||
| 64 | @Resource | ||
| 65 | private MfServicerMaintainDetailService mfServicerMaintainDetailService; | ||
| 66 | |||
| 67 | @Resource | ||
| 68 | private CsbrBeanUtil csbrBeanUtil; | ||
| 69 | |||
| 70 | @Resource | ||
| 71 | private ApprovalFlowUtil approvalFlowUtil; | ||
| 72 | |||
| 73 | @Resource | ||
| 74 | private MessageSourceUtil messageSourceUtil; | ||
| 75 | |||
| 76 | @Resource | ||
| 77 | private ConfigureFeign configureFeign; | ||
| 78 | |||
| 79 | /** | ||
| 80 | * 服务商维护分页查询 | ||
| 81 | * @author xcq | ||
| 82 | * @date 2024-12-31 18:49 | ||
| 83 | * @param queryVO | ||
| 84 | * @return com.csbr.cloud.mybatis.entity.PageListVO<com.csbr.qingcloud.portal.domain.vo.ServicerMaintainRSVO> | ||
| 85 | */ | ||
| 86 | @Override | ||
| 87 | public PageListVO<ServicerMaintainRSVO> pageList(ServicerMaintainQueryVO queryVO) { | ||
| 88 | beforeQuery(queryVO); | ||
| 89 | if (queryVO.getIsNeedQuery()) { | ||
| 90 | LambdaQueryWrapper<MfServicerMaintain> queryWrapper = mfServicerMaintainService.csbrQueryWrapper(queryVO, MfServicerMaintain.class); | ||
| 91 | queryWrapper.in(CollectionUtils.isNotEmpty(queryVO.getGuidList()), MfServicerMaintain::getGuid, | ||
| 92 | queryVO.getGuidList()); | ||
| 93 | queryWrapper.orderByDesc(MfServicerMaintain::getCreateTime); | ||
| 94 | PageListVO<MfServicerMaintain> pageList = mfServicerMaintainService.csbrPageList(queryVO, queryWrapper); | ||
| 95 | PageListVO<ServicerMaintainRSVO> rsPageList = csbrBeanUtil.convert(pageList, PageListVO.class); | ||
| 96 | afterQuery(pageList, rsPageList); | ||
| 97 | return rsPageList; | ||
| 98 | } | ||
| 99 | return new PageListVO<>(0L,0L); | ||
| 100 | } | ||
| 101 | |||
| 102 | /** | ||
| 103 | * 服务商维护获取详情数据 | ||
| 104 | * @author xcq | ||
| 105 | * @date 2024-12-31 18:49 | ||
| 106 | * @param guid | ||
| 107 | * @return com.csbr.qingcloud.portal.domain.vo.ServicerMaintainRSVO | ||
| 108 | */ | ||
| 109 | @Override | ||
| 110 | public ServicerMaintainRSVO getServicerMaintainDetail(String guid) { | ||
| 111 | if (StringUtils.isBlank(guid)) { | ||
| 112 | // W00012 = {0}:参数[{1}]不能为空! | ||
| 113 | throw new CsbrSystemException(SystemError.DATA_INPUT_ERROR, messageSourceUtil.getMessage("W00010", | ||
| 114 | String.format("获取%s详情数据", FUNCTION_NAME), "数据唯一标识")); | ||
| 115 | } | ||
| 116 | MfServicerMaintain entity = mfServicerMaintainService.getById(guid); | ||
| 117 | if (entity == null) { | ||
| 118 | throw new CsbrSystemException(SystemError.DATA_NOT_EXISTS, messageSourceUtil.notExistsToSelectMessage(String.format("获取%s详情数据", FUNCTION_NAME))); | ||
| 119 | } | ||
| 120 | return convertToVO(entity); | ||
| 121 | } | ||
| 122 | |||
| 123 | /** | ||
| 124 | * 服务商维护数据新增 | ||
| 125 | * @author xcq | ||
| 126 | * @date 2024-12-31 18:49 | ||
| 127 | * @param flowBaseVO | ||
| 128 | * @return void | ||
| 129 | */ | ||
| 130 | @GlobalTransactional(rollbackFor = Exception.class) | ||
| 131 | @Transactional(rollbackFor = Exception.class) | ||
| 132 | @Override | ||
| 133 | public void saveServicerMaintain(FlowRQBaseVO flowBaseVO) { | ||
| 134 | ServicerMaintainRQVO rqVO = (ServicerMaintainRQVO) flowBaseVO; | ||
| 135 | beforeSave(rqVO); | ||
| 136 | MfServicerMaintain entity = convertToEntity(rqVO); | ||
| 137 | if(!"Y".equals(rqVO.getBizApproveState())){ | ||
| 138 | // 发起审批流程或保存草稿 | ||
| 139 | AddApprovalDTO approvalDTO = getAddApprovalDTO(entity); | ||
| 140 | super.startWorkFlow(rqVO, approvalDTO, entity::setBizApproveState); | ||
| 141 | } | ||
| 142 | // 业务数据保存 | ||
| 143 | boolean flag = mfServicerMaintainService.save(entity); | ||
| 144 | if (!flag) { | ||
| 145 | throw new CsbrSystemException(SystemError.DATA_ADD_ERROR, rqVO.getImmediateApprove() ? | ||
| 146 | messageSourceUtil.submitMessage(FUNCTION_NAME) : messageSourceUtil.addMessage(FUNCTION_NAME)); | ||
| 147 | } | ||
| 148 | afterSave(entity, rqVO); | ||
| 149 | } | ||
| 150 | |||
| 151 | /** | ||
| 152 | * 服务商维护数据修改 | ||
| 153 | * @author xcq | ||
| 154 | * @date 2024-12-31 18:49 | ||
| 155 | * @param flowBaseVO | ||
| 156 | * @return void | ||
| 157 | */ | ||
| 158 | @GlobalTransactional(rollbackFor = Exception.class) | ||
| 159 | @Transactional(rollbackFor = Exception.class) | ||
| 160 | @Override | ||
| 161 | public void updateServicerMaintain(FlowRQBaseVO flowBaseVO) { | ||
| 162 | ServicerMaintainRQVO rqVO = (ServicerMaintainRQVO) flowBaseVO; | ||
| 163 | // 将修改前数据查出来缓存下来,传入到修改后方法中,用于一些特殊逻辑处理,如某个值变化才进行 | ||
| 164 | MfServicerMaintain oldEntity = mfServicerMaintainService.getById(rqVO.getGuid()); | ||
| 165 | beforeUpdate(rqVO); | ||
| 166 | MfServicerMaintain entity = convertToEntity(rqVO); | ||
| 167 | if("Y".equals(rqVO.getBizApproveState())){ | ||
| 168 | // 修改业务数据 | ||
| 169 | boolean flag = mfServicerMaintainService.updateById(entity); | ||
| 170 | if (!flag) { | ||
| 171 | throw new CsbrSystemException(SystemError.DATA_UPDATE_ERROR, rqVO.getImmediateApprove() ? | ||
| 172 | messageSourceUtil.submitMessage(FUNCTION_NAME) : messageSourceUtil.updateMessage(FUNCTION_NAME)); | ||
| 173 | } | ||
| 174 | afterUpdate(entity, rqVO); | ||
| 175 | } | ||
| 176 | else{ | ||
| 177 | // 发起审批流程或保存草稿 | ||
| 178 | AddApprovalDTO approvalDTO = getAddApprovalDTO(entity); | ||
| 179 | super.startOrRestartWorkFlow(rqVO, rqVO.getBizApproveState(), approvalDTO, entity::setBizApproveState); | ||
| 180 | if (rqVO.getIsRestart()) { | ||
| 181 | // 重新提交 | ||
| 182 | againSubmitFlow(entity, rqVO, approvalDTO); | ||
| 183 | } else { | ||
| 184 | // 修改业务数据 | ||
| 185 | boolean flag = mfServicerMaintainService.updateById(entity); | ||
| 186 | if (!flag) { | ||
| 187 | throw new CsbrSystemException(SystemError.DATA_UPDATE_ERROR, rqVO.getImmediateApprove() ? | ||
| 188 | messageSourceUtil.submitMessage(FUNCTION_NAME) : messageSourceUtil.updateMessage(FUNCTION_NAME)); | ||
| 189 | } | ||
| 190 | afterUpdate(entity, rqVO); | ||
| 191 | } | ||
| 192 | } | ||
| 193 | } | ||
| 194 | |||
| 195 | /** | ||
| 196 | * 重新提交服务商维护 | ||
| 197 | * @author xcq | ||
| 198 | * @date 2024-12-31 18:49 | ||
| 199 | * @param entity | ||
| 200 | * @param rqVO | ||
| 201 | * @param approvalDTO | ||
| 202 | * @return void | ||
| 203 | */ | ||
| 204 | private void againSubmitFlow(MfServicerMaintain entity, ServicerMaintainRQVO rqVO, AddApprovalDTO approvalDTO) { | ||
| 205 | entity.setGuid(CommonUtil.newGuid()); | ||
| 206 | mfServicerMaintainService.csbrBaseEntity(entity); | ||
| 207 | entity.setBizApproveState("A"); | ||
| 208 | // 保存新数据 | ||
| 209 | boolean flag = mfServicerMaintainService.save(entity); | ||
| 210 | if (!flag) { | ||
| 211 | throw new CsbrSystemException(SystemError.DATA_ADD_ERROR, messageSourceUtil.addMessage(String.format("重新提交%s",FUNCTION_NAME))); | ||
| 212 | } | ||
| 213 | // 发起新的流程 | ||
| 214 | approvalDTO.setBizGuid(entity.getGuid()); | ||
| 215 | approvalFlowUtil.addApproval(approvalDTO); | ||
| 216 | afterSave(entity, rqVO); | ||
| 217 | } | ||
| 218 | |||
| 219 | /** | ||
| 220 | * 服务商维护数据删除、并有相关的处理操作 | ||
| 221 | * @author xcq | ||
| 222 | * @date 2024-12-31 18:49 | ||
| 223 | * @param guids | ||
| 224 | * @return void | ||
| 225 | */ | ||
| 226 | @GlobalTransactional(rollbackFor = Exception.class) | ||
| 227 | @Transactional(rollbackFor = Exception.class) | ||
| 228 | @Override | ||
| 229 | public void removeByGuids(List<String> guids) { | ||
| 230 | if (CollectionUtils.isEmpty(guids)) { | ||
| 231 | // W00012 = {0}:参数[{1}]不能为空! | ||
| 232 | throw new CsbrSystemException(SystemError.DATA_INPUT_ERROR, messageSourceUtil.getMessage("W00012", | ||
| 233 | String.format("删除%s数据", FUNCTION_NAME), "数据唯一标识")); | ||
| 234 | } | ||
| 235 | for (String guid : guids) { | ||
| 236 | MfServicerMaintain entity = mfServicerMaintainService.getById(guid); | ||
| 237 | beforeRemove(entity); | ||
| 238 | boolean flag = mfServicerMaintainService.removeById(guid); | ||
| 239 | if (!flag) { | ||
| 240 | throw new CsbrSystemException(SystemError.DATA_DEL_ERROR, messageSourceUtil.delMessage(FUNCTION_NAME)); | ||
| 241 | } | ||
| 242 | afterRemove(entity); | ||
| 243 | } | ||
| 244 | // 删除流程数据 | ||
| 245 | approvalFlowUtil.removeApproveByBizGuids(guids); | ||
| 246 | } | ||
| 247 | |||
| 248 | /** | ||
| 249 | * 流程结束后进行业务回调 | ||
| 250 | * @author xcq | ||
| 251 | * @date 2024-12-31 18:49 | ||
| 252 | * @param dto | ||
| 253 | * @return void | ||
| 254 | */ | ||
| 255 | @Transactional(rollbackFor = Exception.class) | ||
| 256 | @Override | ||
| 257 | public void flowCallBack(BizCallbackDTO dto) { | ||
| 258 | MfServicerMaintain entity = mfServicerMaintainService.getById(dto.getBizGuid()); | ||
| 259 | if (entity == null) { | ||
| 260 | throw new CsbrSystemException(SystemError.DATA_NOT_EXISTS, messageSourceUtil.notExistsToSelectMessage(FUNCTION_NAME)); | ||
| 261 | } | ||
| 262 | if (ApprovalStateEnum.PASSED.getValue().equals(dto.getApprovalState())) { | ||
| 263 | // todo | ||
| 264 | } | ||
| 265 | // 同步更新审批状态 | ||
| 266 | LambdaUpdateWrapper<MfServicerMaintain> updateWrapper = new LambdaUpdateWrapper<>(); | ||
| 267 | updateWrapper.set(MfServicerMaintain::getBizApproveState, dto.getApprovalState()); | ||
| 268 | updateWrapper.eq(MfServicerMaintain::getGuid, dto.getBizGuid()); | ||
| 269 | boolean flag = mfServicerMaintainService.update(updateWrapper); | ||
| 270 | if (!flag) { | ||
| 271 | throw new CsbrSystemException(SystemError.DATA_UPDATE_ERROR, messageSourceUtil.updateMessage(String.format("%s的业务审批状态", FUNCTION_NAME))); | ||
| 272 | } | ||
| 273 | } | ||
| 274 | |||
| 275 | /** | ||
| 276 | * 获取发起流程参数 | ||
| 277 | * @author xcq | ||
| 278 | * @date 2024-12-31 18:49 | ||
| 279 | * @param entity | ||
| 280 | * @return com.csbr.cloud.workflow.domain.dto.appove.AddApprovalDTO | ||
| 281 | */ | ||
| 282 | private AddApprovalDTO getAddApprovalDTO(MfServicerMaintain entity) { | ||
| 283 | AddApprovalDTO approvalDTO = new AddApprovalDTO(FLOW_TYPE, entity.getGuid()); | ||
| 284 | // todo | ||
| 285 | approvalDTO.setFuncCode("FWSWH"); | ||
| 286 | // 流程消息中的变量替换参数 | ||
| 287 | approvalDTO.setFlowMessageBody(String.format("%s,%s",entity.getCreateUserName(),entity.getTenantName())); | ||
| 288 | // 流程列表数据核心param参数处理 | ||
| 289 | approvalDTO.setParam1(null); | ||
| 290 | approvalDTO.setParam2(null); | ||
| 291 | approvalDTO.setParam3(null); | ||
| 292 | approvalDTO.setParam4(null); | ||
| 293 | |||
| 294 | return approvalDTO; | ||
| 295 | } | ||
| 296 | |||
| 297 | /** | ||
| 298 | * 服务商维护新新增前置处理 | ||
| 299 | * @author xcq | ||
| 300 | * @date 2024-12-31 18:49 | ||
| 301 | * @param rqVO | ||
| 302 | * @return void | ||
| 303 | */ | ||
| 304 | private void beforeSave(ServicerMaintainRQVO rqVO) { | ||
| 305 | //region 1.输入基础验证 | ||
| 306 | //endregion | ||
| 307 | |||
| 308 | //region 2.数据验证特殊处理 | ||
| 309 | //region 2.1.业务合规性验证 | ||
| 310 | //endregion 2.1.业务合规性验证 | ||
| 311 | |||
| 312 | //region 2.2.业务数据验证 | ||
| 313 | //endregion 2.2.业务数据验证 | ||
| 314 | |||
| 315 | //endregion 2.数据验证特殊处理 | ||
| 316 | |||
| 317 | //region 3.数据转换处理 | ||
| 318 | |||
| 319 | //region 3.1.数据过程转换 | ||
| 320 | //endregion 3.1.数据过程转换 | ||
| 321 | |||
| 322 | //endregion 3.数据转换处理 | ||
| 323 | |||
| 324 | //region 4.数据过滤与补充处理 | ||
| 325 | |||
| 326 | //endregion 4.数据过滤与补充处理 | ||
| 327 | |||
| 328 | //region 5.过程处理 | ||
| 329 | |||
| 330 | //region 5.1.计算逻辑处理 | ||
| 331 | //endregion 5.1.计算逻辑处理 | ||
| 332 | |||
| 333 | //region 5.2.业务逻辑处理 | ||
| 334 | //endregion 5.2.业务逻辑处理 | ||
| 335 | |||
| 336 | //endregion 5.过程处理 | ||
| 337 | } | ||
| 338 | |||
| 339 | /** | ||
| 340 | * 服务商维护新增后置处理 | ||
| 341 | * @author xcq | ||
| 342 | * @date 2024-12-31 18:49 | ||
| 343 | * @param entity | ||
| 344 | * @param rqVO | ||
| 345 | * @return void | ||
| 346 | */ | ||
| 347 | private void afterSave(MfServicerMaintain entity, ServicerMaintainRQVO rqVO) { | ||
| 348 | List<MfServicerMaintainDetail> details = JSON.parseArray(entity.getMaintainJson(),MfServicerMaintainDetail.class); | ||
| 349 | for(MfServicerMaintainDetail item : details){ | ||
| 350 | item.setGuid(CommonUtil.newGuid()); | ||
| 351 | item.setTenantGuid(entity.getTenantGuid()); | ||
| 352 | item.setParentGuid(entity.getGuid()); | ||
| 353 | } | ||
| 354 | mfServicerMaintainDetailService.saveBatch(details); | ||
| 355 | } | ||
| 356 | |||
| 357 | /** | ||
| 358 | * 服务商维护修改前置校验、处理 | ||
| 359 | * @author xcq | ||
| 360 | * @date 2024-12-31 18:49 | ||
| 361 | * @param rqVO | ||
| 362 | * @return void | ||
| 363 | */ | ||
| 364 | private void beforeUpdate(ServicerMaintainRQVO rqVO) { | ||
| 365 | //region 1.输入基础验证 | ||
| 366 | if (StringUtils.isBlank(rqVO.getGuid())) { | ||
| 367 | // W00012 = {0}:参数[{1}]不能为空! | ||
| 368 | throw new CsbrSystemException(SystemError.DATA_INPUT_ERROR, messageSourceUtil.getMessage("W00010", String.format("修改%s数据",FUNCTION_NAME), "数据唯一标识")); | ||
| 369 | } | ||
| 370 | //endregion | ||
| 371 | |||
| 372 | //region 2.数据验证特殊处理 | ||
| 373 | //region 2.1.业务合规性验证 | ||
| 374 | //endregion 2.1.业务合规性验证 | ||
| 375 | |||
| 376 | //region 2.2.业务数据验证 | ||
| 377 | LambdaQueryWrapper<MfServicerMaintain> queryWrapper = new LambdaQueryWrapper<>(); | ||
| 378 | queryWrapper.eq(MfServicerMaintain::getGuid, rqVO.getGuid()); | ||
| 379 | queryWrapper.select(MfServicerMaintain::getGuid, MfServicerMaintain::getBizApproveState); | ||
| 380 | MfServicerMaintain entity = mfServicerMaintainService.getOne(queryWrapper); | ||
| 381 | if (entity == null) { | ||
| 382 | throw new CsbrSystemException(SystemError.DATA_NOT_EXISTS, messageSourceUtil.notExistsToUpdateMessage(FUNCTION_NAME)); | ||
| 383 | } | ||
| 384 | //endregion 2.2.业务数据验证 | ||
| 385 | |||
| 386 | //endregion 2.数据验证特殊处理 | ||
| 387 | |||
| 388 | //region 3.数据转换处理 | ||
| 389 | |||
| 390 | //region 3.1.数据过程转换 | ||
| 391 | //endregion 3.1.数据过程转换 | ||
| 392 | |||
| 393 | //endregion 3.数据转换处理 | ||
| 394 | |||
| 395 | //region 4.数据过滤与补充处理 | ||
| 396 | //endregion 4.数据过滤与补充处理 | ||
| 397 | |||
| 398 | //region 5.过程处理 | ||
| 399 | |||
| 400 | //region 5.1.计算逻辑处理 | ||
| 401 | //endregion 5.1.计算逻辑处理 | ||
| 402 | |||
| 403 | //region 5.2.业务逻辑处理 | ||
| 404 | //endregion 5.2.业务逻辑处理 | ||
| 405 | |||
| 406 | //endregion 5.过程处理 | ||
| 407 | } | ||
| 408 | |||
| 409 | /** | ||
| 410 | * 服务商维护修改后置处理 | ||
| 411 | * @author xcq | ||
| 412 | * @date 2024-12-31 18:49 | ||
| 413 | * @param entity | ||
| 414 | * @param rqVO | ||
| 415 | * @return void | ||
| 416 | */ | ||
| 417 | protected void afterUpdate(MfServicerMaintain entity, ServicerMaintainRQVO rqVO) { | ||
| 418 | LambdaUpdateWrapper<MfServicerMaintainDetail> updateWrapper = new LambdaUpdateWrapper<>(); | ||
| 419 | updateWrapper.eq(MfServicerMaintainDetail::getParentGuid,entity.getGuid()); | ||
| 420 | mfServicerMaintainDetailService.remove(updateWrapper); | ||
| 421 | |||
| 422 | List<MfServicerMaintainDetail> details = JSON.parseArray(entity.getMaintainJson(),MfServicerMaintainDetail.class); | ||
| 423 | for(MfServicerMaintainDetail item : details){ | ||
| 424 | item.setGuid(CommonUtil.newGuid()); | ||
| 425 | item.setTenantGuid(entity.getTenantGuid()); | ||
| 426 | item.setParentGuid(entity.getGuid()); | ||
| 427 | } | ||
| 428 | mfServicerMaintainDetailService.saveBatch(details); | ||
| 429 | } | ||
| 430 | |||
| 431 | |||
| 432 | /** | ||
| 433 | * 服务商维护删除前置处理 | ||
| 434 | * @author xcq | ||
| 435 | * @date 2024-12-31 18:49 | ||
| 436 | * @param entity | ||
| 437 | * @return void | ||
| 438 | */ | ||
| 439 | private void beforeRemove(MfServicerMaintain entity) { | ||
| 440 | if (entity == null) { | ||
| 441 | throw new CsbrSystemException(SystemError.DATA_DEL_ERROR, messageSourceUtil.notExistsToDelMessage(FUNCTION_NAME)); | ||
| 442 | } | ||
| 443 | if (ApprovalStateEnum.CHECKING.getValue().equals(entity.getBizApproveState()) || | ||
| 444 | ApprovalStateEnum.PASSED.getValue().equals(entity.getBizApproveState())) { | ||
| 445 | throw new CsbrSystemException(SystemError.DATA_DEL_ERROR, "审批中和审批通过的数据不能删除!"); | ||
| 446 | } | ||
| 447 | } | ||
| 448 | |||
| 449 | /** | ||
| 450 | * 服务商维护删除后置处理 | ||
| 451 | * @author xcq | ||
| 452 | * @date 2024-12-31 18:49 | ||
| 453 | * @param entity | ||
| 454 | * @return void | ||
| 455 | */ | ||
| 456 | private void afterRemove(MfServicerMaintain entity) { | ||
| 457 | |||
| 458 | } | ||
| 459 | |||
| 460 | /** | ||
| 461 | * 服务商维护查询方法前置验证、处理 | ||
| 462 | * @author xcq | ||
| 463 | * @date 2024-12-31 18:49 | ||
| 464 | * @param rqQueryVO | ||
| 465 | * @return void | ||
| 466 | */ | ||
| 467 | private void beforeQuery(ServicerMaintainQueryVO rqQueryVO) { | ||
| 468 | rqQueryVO.setIsNeedQuery(true); | ||
| 469 | if (approvalFlowUtil.isQueryBizGuid(rqQueryVO)) { | ||
| 470 | rqQueryVO.setFlowType(FLOW_TYPE); | ||
| 471 | List<String> bizGuidList = approvalFlowUtil.getApprovalBizGuids(rqQueryVO); | ||
| 472 | if (CollectionUtils.isEmpty(bizGuidList)) { | ||
| 473 | rqQueryVO.setIsNeedQuery(false); | ||
| 474 | } else { | ||
| 475 | rqQueryVO.setGuidList(bizGuidList); | ||
| 476 | } | ||
| 477 | } | ||
| 478 | } | ||
| 479 | |||
| 480 | /** | ||
| 481 | * 服务商维护查询方法后置数据转换、处理 | ||
| 482 | * @author xcq | ||
| 483 | * @date 2024-12-31 18:49 | ||
| 484 | * @param pageList 数据库查询数据 | ||
| 485 | * @param rsPageList 返回的最终数据 | ||
| 486 | * @return void | ||
| 487 | */ | ||
| 488 | private void afterQuery(PageListVO<MfServicerMaintain> pageList, PageListVO<ServicerMaintainRSVO> rsPageList) { | ||
| 489 | if (CollectionUtils.isNotEmpty(pageList.getRecords())) { | ||
| 490 | rsPageList.setRecords(convertToVO(pageList.getRecords())); | ||
| 491 | } | ||
| 492 | // 需要特殊处理数据时使用 | ||
| 493 | /*if(CollectionUtils.isNotEmpty(pageList.getRecords())){ | ||
| 494 | List<ServicerMaintainRSVO> results = new ArrayList<>(); | ||
| 495 | for (MfServicerMaintain item : pageList.getRecords()){ | ||
| 496 | ServicerMaintainRSVO vo = convertToVO(item); | ||
| 497 | results.add(vo); | ||
| 498 | } | ||
| 499 | rsPageList.setRecords(results); | ||
| 500 | }*/ | ||
| 501 | } | ||
| 502 | |||
| 503 | //region 辅助操作 | ||
| 504 | |||
| 505 | /** | ||
| 506 | * 服务商维护实体数据转换为视图对象数据(多个) | ||
| 507 | * @author xcq | ||
| 508 | * @date 2024-12-31 18:49 | ||
| 509 | * @param entityList 实体数据列表 | ||
| 510 | * @return java.util.List<com.csbr.qingcloud.portal.domain.vo.ServicerMaintainRSVO> 视图对象列表 | ||
| 511 | */ | ||
| 512 | private List<ServicerMaintainRSVO> convertToVO(List<MfServicerMaintain> entityList) { | ||
| 513 | if (CollectionUtils.isEmpty(entityList)) { | ||
| 514 | // W00012 = {0}:参数[{1}]不能为空! | ||
| 515 | throw new CsbrSystemException(SystemError.DATA_INPUT_ERROR, messageSourceUtil.getMessage("W00012", | ||
| 516 | "实体数据转换为视图对象实体数据", "实体数据")); | ||
| 517 | } | ||
| 518 | List<ServicerMaintainRSVO> voList = new ArrayList<>(entityList.size()); | ||
| 519 | for (MfServicerMaintain item : entityList) { | ||
| 520 | ServicerMaintainRSVO vo = convertToVO(item); | ||
| 521 | voList.add(vo); | ||
| 522 | } | ||
| 523 | return voList; | ||
| 524 | } | ||
| 525 | |||
| 526 | /** | ||
| 527 | * 服务商维护实体数据转换为视图对象数据 | ||
| 528 | * @author xcq | ||
| 529 | * @date 2024-12-31 18:49 | ||
| 530 | * @param entity | ||
| 531 | * @return com.csbr.qingcloud.portal.domain.vo.ServicerMaintainRSVO | ||
| 532 | */ | ||
| 533 | private ServicerMaintainRSVO convertToVO(MfServicerMaintain entity) { | ||
| 534 | ServicerMaintainRSVO vo = csbrBeanUtil.convert(entity, ServicerMaintainRSVO.class); | ||
| 535 | //流程数据处理 | ||
| 536 | vo.setApproveVO(approvalFlowUtil.getApprovalInfo(entity.getGuid())); | ||
| 537 | vo.setTenantTypeName(getTypeName(entity.getTenantType())); | ||
| 538 | return vo; | ||
| 539 | } | ||
| 540 | |||
| 541 | private List<DictModel> dicList = new ArrayList<>(); | ||
| 542 | |||
| 543 | private String getTypeName(String tenantType) { | ||
| 544 | if (CollectionUtils.isEmpty(dicList)) { | ||
| 545 | dicList = configureFeign.getDictListByType("客户类型").getData(); | ||
| 546 | } | ||
| 547 | for(DictModel item : dicList){ | ||
| 548 | if(item.getValue().equals(tenantType)){ | ||
| 549 | return item.getText(); | ||
| 550 | } | ||
| 551 | if(CollectionUtils.isNotEmpty(item.getChildDictList())){ | ||
| 552 | for(DictModel child : item.getChildDictList()){ | ||
| 553 | if(child.getValue().equals(tenantType)){ | ||
| 554 | return child.getText(); | ||
| 555 | } | ||
| 556 | } | ||
| 557 | } | ||
| 558 | } | ||
| 559 | return tenantType; | ||
| 560 | } | ||
| 561 | |||
| 562 | /** | ||
| 563 | * 服务商维护新增、修改和其他情况的参数转换为实体 | ||
| 564 | * @author xcq | ||
| 565 | * @date 2024-12-31 18:49 | ||
| 566 | * @param vo | ||
| 567 | * @return com.csbr.qingcloud.portal.mybatis.entity.MfServicerMaintain | ||
| 568 | */ | ||
| 569 | private MfServicerMaintain convertToEntity(ServicerMaintainRQVO vo) { | ||
| 570 | MfServicerMaintain entity = csbrBeanUtil.convert(vo, MfServicerMaintain.class); | ||
| 571 | // 新增时数据默认guid赋值,转换后该guid可能别使用 | ||
| 572 | if (StringUtils.isBlank(vo.getGuid())) { | ||
| 573 | entity.setGuid(CommonUtil.newGuid()); | ||
| 574 | } | ||
| 575 | return entity; | ||
| 576 | } | ||
| 577 | |||
| 578 | //endregion | ||
| 579 | |||
| 580 | } |
| 1 | package com.csbr.qingcloud.portal.util; | ||
| 2 | |||
| 3 | import com.csbr.cloud.common.util.CommonUtil; | ||
| 4 | import com.csbr.cloud.common.util.CsbrBeanUtil; | ||
| 5 | import com.csbr.qingcloud.portal.domain.vo.BoroughPOJO; | ||
| 6 | import com.csbr.qingcloud.portal.domain.vo.ChangeInfoVO; | ||
| 7 | import com.csbr.qingcloud.portal.domain.vo.CompareResult; | ||
| 8 | import com.csbr.qingcloud.portal.feign.ConfigureFeign; | ||
| 9 | import com.csbr.qingcloud.portal.service.impl.EnterpriseServiceImpl; | ||
| 10 | import jakarta.annotation.Resource; | ||
| 11 | import org.apache.commons.collections.CollectionUtils; | ||
| 12 | import org.apache.commons.lang3.StringUtils; | ||
| 13 | import org.springframework.stereotype.Component; | ||
| 14 | |||
| 15 | import java.math.BigDecimal; | ||
| 16 | import java.math.RoundingMode; | ||
| 17 | import java.util.ArrayList; | ||
| 18 | import java.util.Comparator; | ||
| 19 | import java.util.Date; | ||
| 20 | import java.util.List; | ||
| 21 | import java.util.stream.Collectors; | ||
| 22 | |||
| 23 | @Component | ||
| 24 | public class ChangeInfoUtil { | ||
| 25 | |||
| 26 | public static List<BoroughPOJO> areaList; | ||
| 27 | |||
| 28 | /** 计算变更信息 */ | ||
| 29 | public static List<ChangeInfoVO> getChangeList(List<EnterpriseServiceImpl.ChangeApproveBean> beanList) throws IllegalAccessException { | ||
| 30 | List<ChangeInfoVO> list = new ArrayList<>(); | ||
| 31 | //循环对比每组记录生来变更内容 | ||
| 32 | for(EnterpriseServiceImpl.ChangeApproveBean item : beanList){ | ||
| 33 | if(item.oldBean == null || item.newBean == null){ | ||
| 34 | continue; | ||
| 35 | } | ||
| 36 | List<CompareResult> diffList = ObjectUtil.getBeanDiff(item.oldBean,item.newBean); | ||
| 37 | getVenueResult(item,list); | ||
| 38 | getStartEndResult(item,list); | ||
| 39 | getRegistrationDateResult(item,list); | ||
| 40 | getRegisteredCapitalResult(item,list); | ||
| 41 | for(CompareResult diffItem : diffList){ | ||
| 42 | if(diffItem.getFieldComment().contains("审批状态") || diffItem.getFieldComment().contains("营业执照") | ||
| 43 | || diffItem.getFieldComment().contains("法人证件照") || diffItem.getFieldComment().contains("管理员证件照") | ||
| 44 | || diffItem.getFieldComment().contains("授权委托书") || diffItem.getFieldComment().contains("省") | ||
| 45 | || diffItem.getFieldComment().contains("市") || diffItem.getFieldComment().contains("区") | ||
| 46 | || diffItem.getFieldComment().contains("营业开始日期") || diffItem.getFieldComment().contains("营业结束日期") || diffItem.getFieldComment().contains("营业期限") | ||
| 47 | || diffItem.getFieldComment().contains("注册日期") || diffItem.getFieldComment().contains("注册资本")){ | ||
| 48 | continue; | ||
| 49 | } | ||
| 50 | list.add(getChangeInfoVO(item,diffItem)); | ||
| 51 | } | ||
| 52 | } | ||
| 53 | list = list.stream().sorted(Comparator.comparing(ChangeInfoVO::getNameEn).thenComparing(ChangeInfoVO::getDate).reversed()).collect(Collectors.toList()); | ||
| 54 | return list; | ||
| 55 | } | ||
| 56 | |||
| 57 | private static ChangeInfoVO getChangeInfoVO(EnterpriseServiceImpl.ChangeApproveBean item,CompareResult diffItem){ | ||
| 58 | ChangeInfoVO vo = new ChangeInfoVO(); | ||
| 59 | vo.setNameEn(diffItem.getFieldName()); | ||
| 60 | vo.setName(diffItem.getFieldComment()); | ||
| 61 | vo.setDate(DateUtil.getDateToString(item.oldBean.getCreateTime())); | ||
| 62 | vo.setBefore(diffItem.getOldValue() == null ? "" : diffItem.getOldValue().toString()); | ||
| 63 | vo.setAfter(diffItem.getNewValue() == null ? "" : diffItem.getNewValue().toString()); | ||
| 64 | vo.setGuid(CommonUtil.newGuid()); | ||
| 65 | return vo; | ||
| 66 | } | ||
| 67 | |||
| 68 | private static void getRegisteredCapitalResult(EnterpriseServiceImpl.ChangeApproveBean item, List<ChangeInfoVO> list) { | ||
| 69 | String oldValue = getRegisteredCapital(item.oldBean.getRegisteredCapital()); | ||
| 70 | String newValue = getRegisteredCapital(item.newBean.getRegisteredCapital()); | ||
| 71 | if(!oldValue.equals(newValue)){ | ||
| 72 | list.add(getChangeInfoVO(item,getCompareResult("注册资本(万元)","registeredCapital",oldValue,newValue))); | ||
| 73 | } | ||
| 74 | } | ||
| 75 | |||
| 76 | private static String getRegisteredCapital(BigDecimal v) { | ||
| 77 | if(v == null){ | ||
| 78 | return ""; | ||
| 79 | } | ||
| 80 | return v.setScale(2, RoundingMode.HALF_DOWN).toString(); | ||
| 81 | } | ||
| 82 | |||
| 83 | public static void getVenueResult(EnterpriseServiceImpl.ChangeApproveBean item, List<ChangeInfoVO> list) { | ||
| 84 | String oldValue = getVenue(item.oldBean.getProvince(),item.oldBean.getCity(),item.oldBean.getDistrict()); | ||
| 85 | String newValue = getVenue(item.newBean.getProvince(),item.newBean.getCity(),item.newBean.getDistrict()); | ||
| 86 | if(!oldValue.equals(newValue)){ | ||
| 87 | list.add(getChangeInfoVO(item,getCompareResult("注册地","venue",oldValue,newValue))); | ||
| 88 | } | ||
| 89 | } | ||
| 90 | |||
| 91 | public static void getRegistrationDateResult(EnterpriseServiceImpl.ChangeApproveBean item, List<ChangeInfoVO> list) { | ||
| 92 | String oldValue = getRegistrationDate(item.oldBean.getRegistrationDate()); | ||
| 93 | String newValue = getRegistrationDate(item.newBean.getRegistrationDate()); | ||
| 94 | if(!oldValue.equals(newValue)){ | ||
| 95 | list.add(getChangeInfoVO(item,getCompareResult("注册日期","registrationDate",oldValue,newValue))); | ||
| 96 | } | ||
| 97 | } | ||
| 98 | |||
| 99 | private static String getRegistrationDate(Date date) { | ||
| 100 | return DateUtil.getShortDateToString(date); | ||
| 101 | } | ||
| 102 | |||
| 103 | private static CompareResult getCompareResult(String comment,String name,String oldVenue,String newVenue){ | ||
| 104 | CompareResult result = new CompareResult(); | ||
| 105 | result.setFieldComment(comment); | ||
| 106 | result.setFieldName(name); | ||
| 107 | result.setOldValue(oldVenue); | ||
| 108 | result.setNewValue(newVenue); | ||
| 109 | return result; | ||
| 110 | } | ||
| 111 | |||
| 112 | public static void getStartEndResult(EnterpriseServiceImpl.ChangeApproveBean item, List<ChangeInfoVO> list) { | ||
| 113 | String oldValue = getStartEnd(item.oldBean.getBusinessLicenseTerm(),item.oldBean.getBusinessLicenseStartDate(),item.oldBean.getBusinessLicenseEndDate()); | ||
| 114 | String newValue = getStartEnd(item.newBean.getBusinessLicenseTerm(),item.newBean.getBusinessLicenseStartDate(),item.newBean.getBusinessLicenseEndDate()); | ||
| 115 | if(!oldValue.equals(newValue)){ | ||
| 116 | list.add(getChangeInfoVO(item,getCompareResult("营业期限","businessLicenseStartEnd",oldValue,newValue))); | ||
| 117 | } | ||
| 118 | } | ||
| 119 | |||
| 120 | public static String getVenue(String province, String city, String district) { | ||
| 121 | if(StringUtils.isBlank(district)){ | ||
| 122 | return String.format("%s/%s",getName(province),getName(city)); | ||
| 123 | } | ||
| 124 | else{ | ||
| 125 | return String.format("%s/%s/%s",getName(province),getName(city),getName(district)); | ||
| 126 | } | ||
| 127 | } | ||
| 128 | |||
| 129 | private static String getName(String code){ | ||
| 130 | List<String> names = areaList.stream().filter(x->x.getCode().equals(code)).map(BoroughPOJO::getName).collect(Collectors.toList()); | ||
| 131 | if(CollectionUtils.isEmpty(names)){ | ||
| 132 | return ""; | ||
| 133 | } | ||
| 134 | return names.get(0); | ||
| 135 | } | ||
| 136 | |||
| 137 | |||
| 138 | public static String getStartEnd(String businessLicenseTerm, Date businessLicenseStartDate, Date businessLicenseEndDate) { | ||
| 139 | if("1".equals(businessLicenseTerm)){ | ||
| 140 | return "长期有效"; | ||
| 141 | } | ||
| 142 | return String.format("%s至%s",DateUtil.getShortDateToString(businessLicenseStartDate),DateUtil.getShortDateToString(businessLicenseEndDate)); | ||
| 143 | } | ||
| 144 | |||
| 145 | } |
| 1 | package com.csbr.qingcloud.portal.util; | ||
| 2 | |||
| 3 | import java.text.SimpleDateFormat; | ||
| 4 | import java.time.LocalDateTime; | ||
| 5 | import java.time.ZoneId; | ||
| 6 | import java.util.Date; | ||
| 7 | |||
| 8 | public class DateUtil { | ||
| 9 | |||
| 10 | /** 时间相差多少天 无视小时 */ | ||
| 11 | public static int getDiffDay(Date one, Date two) { | ||
| 12 | if(one == null || two == null){ | ||
| 13 | return 0; | ||
| 14 | } | ||
| 15 | one = getDateByString(getShortDateToString(one)); | ||
| 16 | two = getDateByString(getShortDateToString(two)); | ||
| 17 | long difference = (one.getTime() - two.getTime()) / 86400000; | ||
| 18 | return (int) Math.abs(difference); | ||
| 19 | } | ||
| 20 | |||
| 21 | /** 字符串时间转日期 */ | ||
| 22 | public static Date getDateByString(String time){ | ||
| 23 | try { | ||
| 24 | return new SimpleDateFormat("yyyy-MM-dd").parse(time); | ||
| 25 | } catch (Exception e) { | ||
| 26 | return new Date(); | ||
| 27 | } | ||
| 28 | } | ||
| 29 | |||
| 30 | /** 时间转字符串 */ | ||
| 31 | public static String getDateToString(Date time){ | ||
| 32 | if(time == null) { | ||
| 33 | return ""; | ||
| 34 | } | ||
| 35 | return new SimpleDateFormat("yyyy-MM-dd HH:mm:ss").format(time); | ||
| 36 | } | ||
| 37 | |||
| 38 | /** 时间转字符串 */ | ||
| 39 | public static String getShortDateToString(Date time){ | ||
| 40 | if(time == null) { | ||
| 41 | return ""; | ||
| 42 | } | ||
| 43 | return new SimpleDateFormat("yyyy-MM-dd").format(time); | ||
| 44 | } | ||
| 45 | |||
| 46 | /** 时间转本地时间 */ | ||
| 47 | public static LocalDateTime getDateToLocal(Date time){ | ||
| 48 | if(time == null) { | ||
| 49 | return null; | ||
| 50 | } | ||
| 51 | return time.toInstant().atZone(ZoneId.systemDefault()).toLocalDateTime(); | ||
| 52 | } | ||
| 53 | |||
| 54 | /** 字符串时间转日期 */ | ||
| 55 | public static Date getShortDate(Date time){ | ||
| 56 | if(time == null) { | ||
| 57 | return null; | ||
| 58 | } | ||
| 59 | try { | ||
| 60 | return new SimpleDateFormat("yyyy-MM-dd").parse(getShortDateToString(time)); | ||
| 61 | } catch (Exception e) { | ||
| 62 | return new Date(); | ||
| 63 | } | ||
| 64 | } | ||
| 65 | |||
| 66 | } |
| 1 | package com.csbr.qingcloud.portal.util; | ||
| 2 | |||
| 3 | import com.alibaba.fastjson.JSON; | ||
| 4 | import com.alibaba.fastjson.JSONObject; | ||
| 5 | import com.csbr.cloud.common.enums.SystemError; | ||
| 6 | import com.csbr.cloud.common.exception.CsbrSystemException; | ||
| 7 | import com.csbr.cloud.common.response.CommonRes; | ||
| 8 | import lombok.extern.slf4j.Slf4j; | ||
| 9 | import org.apache.hc.client5.http.config.RequestConfig; | ||
| 10 | import org.apache.hc.client5.http.impl.classic.CloseableHttpClient; | ||
| 11 | import org.apache.hc.client5.http.impl.classic.HttpClientBuilder; | ||
| 12 | import org.apache.hc.core5.util.Timeout; | ||
| 13 | import org.springframework.beans.factory.annotation.Autowired; | ||
| 14 | import org.springframework.http.HttpEntity; | ||
| 15 | import org.springframework.http.HttpHeaders; | ||
| 16 | import org.springframework.http.MediaType; | ||
| 17 | import org.springframework.http.client.ClientHttpRequestFactory; | ||
| 18 | import org.springframework.http.client.HttpComponentsClientHttpRequestFactory; | ||
| 19 | import org.springframework.stereotype.Component; | ||
| 20 | import org.springframework.web.client.RestTemplate; | ||
| 21 | |||
| 22 | /** | ||
| 23 | * @program: daop-projects | ||
| 24 | * @description: | ||
| 25 | * @author: xiaojie | ||
| 26 | * @create: 2025-03-13 14:52 | ||
| 27 | **/ | ||
| 28 | @Component | ||
| 29 | @Slf4j | ||
| 30 | public class InvokeUtil { | ||
| 31 | |||
| 32 | @Autowired | ||
| 33 | private RestTemplate restTemplate; | ||
| 34 | |||
| 35 | /** | ||
| 36 | * open调用接口 | ||
| 37 | * @param jsonObject | ||
| 38 | * @param appKey | ||
| 39 | * @param zqDelUrl | ||
| 40 | */ | ||
| 41 | public void invokeMainDel(JSONObject jsonObject, String appKey, String zqDelUrl) { | ||
| 42 | HttpHeaders headers = new HttpHeaders(); | ||
| 43 | headers.setContentType(MediaType.APPLICATION_JSON); | ||
| 44 | headers.set("appKey", appKey); | ||
| 45 | HttpEntity<JSONObject> requestEntity = new HttpEntity<>(jsonObject, headers); | ||
| 46 | restTemplate.setRequestFactory(getFactory()); | ||
| 47 | CommonRes commonRes = restTemplate.postForObject(zqDelUrl, requestEntity, CommonRes.class); | ||
| 48 | if (!CommonRes.success().getCode().equals(commonRes.getCode())) { | ||
| 49 | throw new CsbrSystemException(SystemError.ERROR_CODE, commonRes.getMsg()); | ||
| 50 | } else { | ||
| 51 | CommonRes commonResData = JSON.parseObject(String.valueOf(commonRes.getData()), CommonRes.class); | ||
| 52 | if (!CommonRes.success().getCode().equals(commonResData.getCode())) { | ||
| 53 | throw new CsbrSystemException(SystemError.ERROR_CODE, commonResData.getMsg()); | ||
| 54 | } | ||
| 55 | } | ||
| 56 | } | ||
| 57 | |||
| 58 | private ClientHttpRequestFactory getFactory() { | ||
| 59 | RequestConfig config = RequestConfig.custom() | ||
| 60 | .setConnectTimeout(Timeout.ofSeconds(5000)) // 连接超时 | ||
| 61 | .setConnectionRequestTimeout(Timeout.ofSeconds(5000)) // 从连接池获取连接的超时时间 | ||
| 62 | .setResponseTimeout(Timeout.ofSeconds(10000)) // 数据读取超时 | ||
| 63 | .build(); | ||
| 64 | |||
| 65 | CloseableHttpClient httpClient = HttpClientBuilder.create() | ||
| 66 | .setDefaultRequestConfig(config) | ||
| 67 | .build(); | ||
| 68 | |||
| 69 | return new HttpComponentsClientHttpRequestFactory(httpClient); | ||
| 70 | } | ||
| 71 | } | ||
| ... | \ No newline at end of file | ... | \ No newline at end of file |
| 1 | package com.csbr.qingcloud.portal.util; | ||
| 2 | |||
| 3 | import com.csbr.qingcloud.portal.domain.vo.CompareResult; | ||
| 4 | import jdk.jfr.Name; | ||
| 5 | import java.lang.reflect.Field; | ||
| 6 | import java.math.BigDecimal; | ||
| 7 | import java.text.SimpleDateFormat; | ||
| 8 | import java.util.ArrayList; | ||
| 9 | import java.util.Date; | ||
| 10 | import java.util.List; | ||
| 11 | |||
| 12 | /** 对象工具 */ | ||
| 13 | public class ObjectUtil { | ||
| 14 | /** 对比两个对象 */ | ||
| 15 | public static List<CompareResult> getBeanDiff(Object oldObj, Object newObj) throws IllegalAccessException { | ||
| 16 | List<CompareResult> list = new ArrayList<>(); | ||
| 17 | //获取对象的class | ||
| 18 | Class<?> clazz1 = oldObj.getClass(); | ||
| 19 | Class<?> clazz2 = newObj.getClass(); | ||
| 20 | //获取对象的属性列表 | ||
| 21 | Field[] field1 = clazz1.getDeclaredFields(); | ||
| 22 | Field[] field2 = clazz2.getDeclaredFields(); | ||
| 23 | |||
| 24 | //遍历属性列表field1 | ||
| 25 | for (int i = 0; i < field1.length; i++) { | ||
| 26 | //遍历属性列表field2 | ||
| 27 | for (int j = 0; j < field2.length; j++) { | ||
| 28 | CompareResult r = getCompareResult(field1[i], field2[j], oldObj, newObj); | ||
| 29 | if (r == null) { | ||
| 30 | continue; | ||
| 31 | } | ||
| 32 | list.add(r); | ||
| 33 | break; | ||
| 34 | } | ||
| 35 | } | ||
| 36 | return list; | ||
| 37 | } | ||
| 38 | |||
| 39 | /** 对比两个字段 */ | ||
| 40 | public static CompareResult getCompareResult(Field oldField, Field newField, Object oldObj, Object newObj) throws IllegalAccessException { | ||
| 41 | //字段名称不同-返回空 | ||
| 42 | if (!oldField.getName().equals(newField.getName())) { | ||
| 43 | return null; | ||
| 44 | } | ||
| 45 | oldField.setAccessible(true); | ||
| 46 | newField.setAccessible(true); | ||
| 47 | //值相同-返回空 | ||
| 48 | if (compareTwo(oldField.get(oldObj), newField.get(newObj))) { | ||
| 49 | return null; | ||
| 50 | } | ||
| 51 | CompareResult r = new CompareResult(); | ||
| 52 | r.setFieldName(oldField.getName()); | ||
| 53 | r.setOldValue(oldField.get(oldObj)); | ||
| 54 | r.setNewValue(newField.get(newObj)); | ||
| 55 | try { | ||
| 56 | r.setFieldComment(oldField.getAnnotation(Name.class) == null ? "" : oldField.getAnnotation(Name.class).value()); | ||
| 57 | } catch (Exception e) { | ||
| 58 | r.setFieldComment(""); | ||
| 59 | } | ||
| 60 | if (oldField.getType() == Date.class) { | ||
| 61 | r.setOldValue(DateUtil.getDateToString((Date)oldField.get(oldObj))); | ||
| 62 | r.setNewValue(DateUtil.getDateToString((Date)oldField.get(newObj))); | ||
| 63 | } | ||
| 64 | return r; | ||
| 65 | } | ||
| 66 | |||
| 67 | /** 对比两个数据是否内容相同 */ | ||
| 68 | public static boolean compareTwo(Object object1, Object object2) { | ||
| 69 | if (object1 == null && object2 == null) { | ||
| 70 | return true; | ||
| 71 | } | ||
| 72 | if (object1 != null && object2 == null) { | ||
| 73 | return false; | ||
| 74 | } | ||
| 75 | if (object2 != null && object1 == null) { | ||
| 76 | return false; | ||
| 77 | } | ||
| 78 | if (object1.equals(object2)) { | ||
| 79 | return true; | ||
| 80 | } | ||
| 81 | if("BigDecimal".equals(object2.getClass().getSimpleName())){ | ||
| 82 | BigDecimal obj1 = (BigDecimal)object1; | ||
| 83 | BigDecimal obj2 = (BigDecimal)object2; | ||
| 84 | if(obj1.compareTo(obj2) == 0){ | ||
| 85 | return true; | ||
| 86 | } | ||
| 87 | } | ||
| 88 | String obj1 = object1.toString().replace("[","").replace("]","").replace("\"","").replace(" ",""); | ||
| 89 | String obj2 = object2.toString().replace("[","").replace("]","").replace("\"","").replace(" ",""); | ||
| 90 | if (obj1.equals(obj2)) { | ||
| 91 | return true; | ||
| 92 | } | ||
| 93 | return false; | ||
| 94 | } | ||
| 95 | } |
| 1 | package com.csbr.qingcloud.portal.util; | ||
| 2 | |||
| 3 | import lombok.Data; | ||
| 4 | import org.springframework.boot.context.properties.ConfigurationProperties; | ||
| 5 | import org.springframework.stereotype.Component; | ||
| 6 | |||
| 7 | /** | ||
| 8 | * @program: daop-projects | ||
| 9 | * @description: | ||
| 10 | * @author: xiaojie | ||
| 11 | * @create: 2025-02-28 14:09 | ||
| 12 | **/ | ||
| 13 | @Data | ||
| 14 | @Component | ||
| 15 | @ConfigurationProperties(prefix = "csbr.zq") | ||
| 16 | public class ZQConfig { | ||
| 17 | |||
| 18 | private String appKey = "672c2c38e4b0cac8732a6106"; | ||
| 19 | |||
| 20 | private String zqName = ""; | ||
| 21 | |||
| 22 | private String zqDelUrl = ""; | ||
| 23 | |||
| 24 | private String groundingPickUrl = ""; | ||
| 25 | |||
| 26 | private Boolean isMain = false; | ||
| 27 | |||
| 28 | } | ||
| ... | \ No newline at end of file | ... | \ No newline at end of file |
| ... | @@ -18,7 +18,7 @@ spring: | ... | @@ -18,7 +18,7 @@ spring: |
| 18 | enabled: true | 18 | enabled: true |
| 19 | server-addr: nacos-cluster-service-develop.nacos-cluster:8848 | 19 | server-addr: nacos-cluster-service-develop.nacos-cluster:8848 |
| 20 | ip: 192.168.6.20 | 20 | ip: 192.168.6.20 |
| 21 | port: 19207 | 21 | port: 19210 |
| 22 | group: develop | 22 | group: develop |
| 23 | namespace: daop-lt | 23 | namespace: daop-lt |
| 24 | metadata: | 24 | metadata: | ... | ... |
| 1 | spring: | ||
| 2 | main: | ||
| 3 | allow-bean-definition-overriding: true | ||
| 4 | application: | ||
| 5 | name: ms-data-circulation-portal-service | ||
| 6 | cloud: | ||
| 7 | nacos: | ||
| 8 | #配置中心 | ||
| 9 | config: | ||
| 10 | server-addr: nacos-cluster-service.nacos-cluster:8848 | ||
| 11 | file-extension: yaml | ||
| 12 | group: enterprise-release | ||
| 13 | namespace: daop-lt | ||
| 14 | # 开启nacos自动刷新,如果这个配置没有或者为false会导致配置不能自动刷新(auto-refresh、enable-remote-sync-config两者缺一不可) | ||
| 15 | auto-refresh: true | ||
| 16 | # 允许nacos服务端向本地同步配置 | ||
| 17 | enable-remote-sync-config: true | ||
| 18 | #注册中心 | ||
| 19 | discovery: | ||
| 20 | enabled: true | ||
| 21 | server-addr: nacos-cluster-service.nacos-cluster:8848 | ||
| 22 | group: enterprise-release | ||
| 23 | namespace: daop-lt | ||
| 24 | metadata: | ||
| 25 | code: "004" | ||
| 26 | user: | ||
| 27 | name: nacos | ||
| 28 | password: nacos | ||
| 29 | management: | ||
| 30 | context-path: /actuator | ||
| 31 | #接口限流 | ||
| 32 | sentinel: | ||
| 33 | transport: | ||
| 34 | # port: 7777 | ||
| 35 | dashboard: sentinel-service.nacos-cluster:8858 | ||
| 36 | #取消懒加载 | ||
| 37 | eager: true | ||
| 38 | management: | ||
| 39 | endpoint: | ||
| 40 | health: | ||
| 41 | show-details: always | ||
| 42 | endpoints: | ||
| 43 | web: | ||
| 44 | exposure: | ||
| 45 | include: '*' | ||
| 46 | ###暂时禁用rabbit的健康检查 | ||
| 47 | health: | ||
| 48 | rabbit: | ||
| 49 | enabled: false | ||
| 50 | sentinel: | ||
| 51 | enabled: false | ||
| 52 | feign: | ||
| 53 | sentinel: | ||
| 54 | enabled: true | ||
| ... | \ No newline at end of file | ... | \ No newline at end of file |
| ... | @@ -4,7 +4,7 @@ | ... | @@ -4,7 +4,7 @@ |
| 4 | <springProperty scope="context" name="app_name" source="spring.application.name"/> | 4 | <springProperty scope="context" name="app_name" source="spring.application.name"/> |
| 5 | <contextName>${app_name}</contextName> | 5 | <contextName>${app_name}</contextName> |
| 6 | <!-- 包含 logback 的基础配置,路径就是所在包 --> | 6 | <!-- 包含 logback 的基础配置,路径就是所在包 --> |
| 7 | <include resource="com/csbr/cloud/common/logback/logback-base.xml"/> | 7 | <include resource="com/csbr/cloud/base/logback/logback-base.xml"/> |
| 8 | <!-- 增加skywalking配置日志收集--> | 8 | <!-- 增加skywalking配置日志收集--> |
| 9 | <appender name="grpc-log" class="org.apache.skywalking.apm.toolkit.log.logback.v1.x.log.GRPCLogClientAppender"> | 9 | <appender name="grpc-log" class="org.apache.skywalking.apm.toolkit.log.logback.v1.x.log.GRPCLogClientAppender"> |
| 10 | <encoder class="ch.qos.logback.core.encoder.LayoutWrappingEncoder"> | 10 | <encoder class="ch.qos.logback.core.encoder.LayoutWrappingEncoder"> |
| ... | @@ -27,11 +27,11 @@ | ... | @@ -27,11 +27,11 @@ |
| 27 | <springProperty scope="context" name="topci_prefix" source="csbr.kafka.topic-prefix" /> | 27 | <springProperty scope="context" name="topci_prefix" source="csbr.kafka.topic-prefix" /> |
| 28 | 28 | ||
| 29 | <!-- 输出到Kafka --> | 29 | <!-- 输出到Kafka --> |
| 30 | <appender name="kafkaAppender" class="com.csbr.cloud.common.logback.KafkaAppender"> | 30 | <appender name="kafkaAppender" class="com.csbr.cloud.log.logback.KafkaAppender"> |
| 31 | <bootstrapServers>${kafka_server}</bootstrapServers> | 31 | <bootstrapServers>${kafka_server}</bootstrapServers> |
| 32 | <topic>csbr_fbt_log</topic> | 32 | <topic>csbr_fbt_log</topic> |
| 33 | <prefix>${topci_prefix}</prefix> | 33 | <prefix>${topci_prefix}</prefix> |
| 34 | <formatter class="com.csbr.cloud.common.logback.JsonFormatter"> | 34 | <formatter class="com.csbr.cloud.log.logback.JsonFormatter"> |
| 35 | <expectJson>false</expectJson> | 35 | <expectJson>false</expectJson> |
| 36 | </formatter> | 36 | </formatter> |
| 37 | </appender> | 37 | </appender> | ... | ... |
| ... | @@ -3,7 +3,7 @@ | ... | @@ -3,7 +3,7 @@ |
| 3 | <!-- 本地服务的名称 --> | 3 | <!-- 本地服务的名称 --> |
| 4 | <property name="app_name" value="ms-data-circulation-portal-service"/> | 4 | <property name="app_name" value="ms-data-circulation-portal-service"/> |
| 5 | <!-- 包含 logback 的基础配置,路径就是所在包 --> | 5 | <!-- 包含 logback 的基础配置,路径就是所在包 --> |
| 6 | <include resource="com/csbr/cloud/common/logback/logback-base.xml"/> | 6 | <include resource="com/csbr/cloud/base/logback/logback-base.xml"/> |
| 7 | <!-- 控制打印输出的内容 --> | 7 | <!-- 控制打印输出的内容 --> |
| 8 | <root level="INFO"> | 8 | <root level="INFO"> |
| 9 | <appender-ref ref="FILE_ERROR"/> | 9 | <appender-ref ref="FILE_ERROR"/> | ... | ... |
| ... | @@ -14,10 +14,10 @@ spring: | ... | @@ -14,10 +14,10 @@ spring: |
| 14 | compatibility-verifier: | 14 | compatibility-verifier: |
| 15 | enabled: false | 15 | enabled: false |
| 16 | gateway: | 16 | gateway: |
| 17 | gatewayServiceName: gateway-server | 17 | gatewayServiceName: ms-daop-gateway-server |
| 18 | host: 114.115.131.96 | 18 | host: https://daop-lt-test.zgsjzc.com/api |
| 19 | kafka: | 19 | kafka: |
| 20 | bootstrap-servers: kafka-cs-develop.daop:9092 | 20 | bootstrap-servers: kafka-cs-test.zk-kafka:9092 |
| 21 | producer: | 21 | producer: |
| 22 | retries: 3 | 22 | retries: 3 |
| 23 | main: | 23 | main: |
| ... | @@ -52,16 +52,16 @@ spring: | ... | @@ -52,16 +52,16 @@ spring: |
| 52 | ##由mycat管理读写分离 不用代码控制(填写mycat的链接库) | 52 | ##由mycat管理读写分离 不用代码控制(填写mycat的链接库) |
| 53 | datasource: | 53 | datasource: |
| 54 | master: | 54 | master: |
| 55 | url: jdbc:mysql://192.168.6.21:3307/csbr_data_circulation_portal?useUnicode=true&characterEncoding=UTF-8&useSSL=false&autoReconnect=true&serverTimezone=Asia/Shanghai&connectTimeout=60000&socketTimeout=60000 | 55 | url: jdbc:mysql://192.168.5.28:3307/csbr_data_circulation_portal?useUnicode=true&characterEncoding=UTF-8&useSSL=false&autoReconnect=true&serverTimezone=Asia/Shanghai&connectTimeout=60000&socketTimeout=60000 |
| 56 | username: prg | 56 | username: sharding |
| 57 | password: E5t391s349wT@3 | 57 | password: dJ5xF7qC |
| 58 | driver-class-name: com.mysql.cj.jdbc.Driver | 58 | driver-class-name: com.mysql.cj.jdbc.Driver |
| 59 | druid: | 59 | druid: |
| 60 | initial-size: 5 | 60 | initial-size: 5 |
| 61 | slave: | 61 | slave: |
| 62 | url: jdbc:mysql://192.168.6.21:3307/csbr_data_circulation_portal?useUnicode=true&characterEncoding=UTF-8&useSSL=false&autoReconnect=true&serverTimezone=Asia/Shanghai&connectTimeout=60000&socketTimeout=60000 | 62 | url: jdbc:mysql://192.168.5.28:3307/csbr_data_circulation_portal?useUnicode=true&characterEncoding=UTF-8&useSSL=false&autoReconnect=true&serverTimezone=Asia/Shanghai&connectTimeout=60000&socketTimeout=60000 |
| 63 | username: prg | 63 | username: sharding |
| 64 | password: E5t391s349wT@3 | 64 | password: dJ5xF7qC |
| 65 | driver-class-name: com.mysql.cj.jdbc.Driver | 65 | driver-class-name: com.mysql.cj.jdbc.Driver |
| 66 | druid: | 66 | druid: |
| 67 | initial-size: 5 | 67 | initial-size: 5 |
| ... | @@ -72,11 +72,11 @@ spring: | ... | @@ -72,11 +72,11 @@ spring: |
| 72 | #cluster: | 72 | #cluster: |
| 73 | # nodes: redis-service.redis:6379 | 73 | # nodes: redis-service.redis:6379 |
| 74 | # 单节点 | 74 | # 单节点 |
| 75 | host: redis-service.daop | 75 | host: redis-service.daop-test |
| 76 | port: 6379 | 76 | port: 6379 |
| 77 | password: "J7e411m693cA9" | 77 | password: "J7e411m693cA9" |
| 78 | timeout: 1000 | 78 | timeout: 1000 |
| 79 | prefix: daop-test | 79 | prefix: daop-develop |
| 80 | jedis: | 80 | jedis: |
| 81 | pool: | 81 | pool: |
| 82 | max-idle: 8 | 82 | max-idle: 8 |
| ... | @@ -91,7 +91,7 @@ spring: | ... | @@ -91,7 +91,7 @@ spring: |
| 91 | encoding: UTF-8 | 91 | encoding: UTF-8 |
| 92 | mode: never | 92 | mode: never |
| 93 | redisson: | 93 | redisson: |
| 94 | address: redis://redis-service.daop:6379 | 94 | address: redis://redis-service.daop-test:6379 |
| 95 | password: "J7e411m693cA9" | 95 | password: "J7e411m693cA9" |
| 96 | 96 | ||
| 97 | seata: | 97 | seata: |
| ... | @@ -101,12 +101,12 @@ seata: | ... | @@ -101,12 +101,12 @@ seata: |
| 101 | registry: | 101 | registry: |
| 102 | type: nacos | 102 | type: nacos |
| 103 | nacos: | 103 | nacos: |
| 104 | application: seata-server | 104 | application: ms-daop-seata-service |
| 105 | cluster: seata-cluster | 105 | cluster: seata-cluster |
| 106 | server-addr: nacos-cluster-service-develop.nacos-cluster:8848 | 106 | server-addr: nacos-cluster-service.nacos-cluster:8848 |
| 107 | password: U9u457p155vH@8 | 107 | password: Q1p534i9 |
| 108 | username: nacos | 108 | username: nacos |
| 109 | namespace: daop-lt | 109 | namespace: daop-master |
| 110 | group: test | 110 | group: test |
| 111 | service: | 111 | service: |
| 112 | vgroupMapping: | 112 | vgroupMapping: |
| ... | @@ -139,13 +139,13 @@ pagehelper: | ... | @@ -139,13 +139,13 @@ pagehelper: |
| 139 | 139 | ||
| 140 | csbr: | 140 | csbr: |
| 141 | kafka: | 141 | kafka: |
| 142 | topic-prefix: DAOP-LT-TEST | 142 | topic-prefix: DAOP-LT-DEVELOP |
| 143 | consumer: | 143 | consumer: |
| 144 | # 开启kafka消费者 | 144 | # 开启kafka消费者 |
| 145 | enable: true | 145 | enable: true |
| 146 | # kafka 服务集群地址,格式:HOST:PORT ,用逗号隔开 | 146 | # kafka 服务集群地址,格式:HOST:PORT ,用逗号隔开 |
| 147 | # bootstrap-servers: 210.12.100.201:9092 | 147 | # bootstrap-servers: 210.12.100.201:9092 |
| 148 | bootstrap-servers: kafka-cs-develop.daop:9092 | 148 | bootstrap-servers: kafka-cs-test.zk-kafka:9092 |
| 149 | # bootstrap-servers: 192.168.3.120:9092 | 149 | # bootstrap-servers: 192.168.3.120:9092 |
| 150 | # 是否启用自动提交 offset | 150 | # 是否启用自动提交 offset |
| 151 | enable-auto-commit: false | 151 | enable-auto-commit: false |
| ... | @@ -170,7 +170,7 @@ csbr: | ... | @@ -170,7 +170,7 @@ csbr: |
| 170 | enable: true | 170 | enable: true |
| 171 | # kafka 服务集群地址,格式:HOST:PORT ,多地址用逗号隔开 | 171 | # kafka 服务集群地址,格式:HOST:PORT ,多地址用逗号隔开 |
| 172 | # bootstrap-servers: 210.12.100.201:9092 | 172 | # bootstrap-servers: 210.12.100.201:9092 |
| 173 | bootstrap-servers: kafka-cs-develop.daop:9092 | 173 | bootstrap-servers: kafka-cs-test.zk-kafka:9092 |
| 174 | # bootstrap-servers: 192.168.3.120:9092 | 174 | # bootstrap-servers: 192.168.3.120:9092 |
| 175 | # 失败后的重发次数 | 175 | # 失败后的重发次数 |
| 176 | retries: 0 | 176 | retries: 0 |
| ... | @@ -187,3 +187,8 @@ feign: | ... | @@ -187,3 +187,8 @@ feign: |
| 187 | query-limit: | 187 | query-limit: |
| 188 | white: TrTaskValid | 188 | white: TrTaskValid |
| 189 | 189 | ||
| 190 | csbrcloud: | ||
| 191 | shardingFlag: true | ||
| 192 | |||
| 193 | logging: | ||
| 194 | config: classpath:logback.xml | ||
| ... | \ No newline at end of file | ... | \ No newline at end of file | ... | ... |
| ... | @@ -5,7 +5,7 @@ spring: | ... | @@ -5,7 +5,7 @@ spring: |
| 5 | nacos: | 5 | nacos: |
| 6 | #配置中心 | 6 | #配置中心 |
| 7 | config: | 7 | config: |
| 8 | server-addr: nacos-cluster-service-develop.nacos-cluster:8848 | 8 | server-addr: nacos-cluster-service.nacos-cluster:8848 |
| 9 | file-extension: yaml | 9 | file-extension: yaml |
| 10 | group: test | 10 | group: test |
| 11 | namespace: daop-lt | 11 | namespace: daop-lt |
| ... | @@ -16,14 +16,14 @@ spring: | ... | @@ -16,14 +16,14 @@ spring: |
| 16 | #注册中心 | 16 | #注册中心 |
| 17 | discovery: | 17 | discovery: |
| 18 | enabled: true | 18 | enabled: true |
| 19 | server-addr: nacos-cluster-service-develop.nacos-cluster:8848 | 19 | server-addr: nacos-cluster-service.nacos-cluster:8848 |
| 20 | group: test | 20 | group: test |
| 21 | namespace: daop-lt | 21 | namespace: daop-lt |
| 22 | metadata: | 22 | metadata: |
| 23 | code: "006" | 23 | code: "006" |
| 24 | user: | 24 | user: |
| 25 | name: nacos | 25 | name: nacos |
| 26 | password: nacos | 26 | password: Q1p534i9 |
| 27 | management: | 27 | management: |
| 28 | context-path: /actuator | 28 | context-path: /actuator |
| 29 | #接口限流 | 29 | #接口限流 | ... | ... |
| ... | @@ -65,34 +65,7 @@ spring: | ... | @@ -65,34 +65,7 @@ spring: |
| 65 | driver-class-name: com.mysql.cj.jdbc.Driver | 65 | driver-class-name: com.mysql.cj.jdbc.Driver |
| 66 | druid: | 66 | druid: |
| 67 | initial-size: 5 | 67 | initial-size: 5 |
| 68 | # redis配置 | 68 | |
| 69 | data: | ||
| 70 | redis: | ||
| 71 | # 集群 | ||
| 72 | #cluster: | ||
| 73 | # nodes: redis-service.redis:6379 | ||
| 74 | # 单节点 | ||
| 75 | host: redis-service.daop | ||
| 76 | port: 6379 | ||
| 77 | password: "J7e411m693cA9" | ||
| 78 | timeout: 1000 | ||
| 79 | prefix: daop-release | ||
| 80 | jedis: | ||
| 81 | pool: | ||
| 82 | max-idle: 8 | ||
| 83 | max-wait: 2000 | ||
| 84 | min-idle: 0 | ||
| 85 | max-active: 100 | ||
| 86 | test-on-borrow: true | ||
| 87 | test-while-idle: true | ||
| 88 | sql: | ||
| 89 | init: | ||
| 90 | schema-locations: classpath*:init.sql | ||
| 91 | encoding: UTF-8 | ||
| 92 | mode: never | ||
| 93 | redisson: | ||
| 94 | address: redis://redis-service.daop:6379 | ||
| 95 | password: "J7e411m693cA9" | ||
| 96 | 69 | ||
| 97 | seata: | 70 | seata: |
| 98 | enabled: true # 1.0新特性,需要依赖seata-spring-boot-starter,默认为true | 71 | enabled: true # 1.0新特性,需要依赖seata-spring-boot-starter,默认为true | ... | ... |
| ... | @@ -5,7 +5,7 @@ spring: | ... | @@ -5,7 +5,7 @@ spring: |
| 5 | nacos: | 5 | nacos: |
| 6 | #配置中心 | 6 | #配置中心 |
| 7 | config: | 7 | config: |
| 8 | server-addr: nacos-cluster-service-develop.nacos-cluster:8848 | 8 | server-addr: nacos-cluster-service.nacos-cluster:8848 |
| 9 | file-extension: yaml | 9 | file-extension: yaml |
| 10 | group: release | 10 | group: release |
| 11 | namespace: daop-master | 11 | namespace: daop-master |
| ... | @@ -16,7 +16,7 @@ spring: | ... | @@ -16,7 +16,7 @@ spring: |
| 16 | #注册中心 | 16 | #注册中心 |
| 17 | discovery: | 17 | discovery: |
| 18 | enabled: true | 18 | enabled: true |
| 19 | server-addr: nacos-cluster-service-develop.nacos-cluster:8848 | 19 | server-addr: nacos-cluster-service.nacos-cluster:8848 |
| 20 | group: release | 20 | group: release |
| 21 | namespace: daop-master | 21 | namespace: daop-master |
| 22 | metadata: | 22 | metadata: | ... | ... |
| ... | @@ -65,34 +65,7 @@ spring: | ... | @@ -65,34 +65,7 @@ spring: |
| 65 | driver-class-name: com.mysql.cj.jdbc.Driver | 65 | driver-class-name: com.mysql.cj.jdbc.Driver |
| 66 | druid: | 66 | druid: |
| 67 | initial-size: 5 | 67 | initial-size: 5 |
| 68 | # redis配置 | 68 | |
| 69 | data: | ||
| 70 | redis: | ||
| 71 | # 集群 | ||
| 72 | #cluster: | ||
| 73 | # nodes: redis-service.redis:6379 | ||
| 74 | # 单节点 | ||
| 75 | host: redis-service.daop | ||
| 76 | port: 6379 | ||
| 77 | password: "J7e411m693cA9" | ||
| 78 | timeout: 1000 | ||
| 79 | prefix: daop-release | ||
| 80 | jedis: | ||
| 81 | pool: | ||
| 82 | max-idle: 8 | ||
| 83 | max-wait: 2000 | ||
| 84 | min-idle: 0 | ||
| 85 | max-active: 100 | ||
| 86 | test-on-borrow: true | ||
| 87 | test-while-idle: true | ||
| 88 | sql: | ||
| 89 | init: | ||
| 90 | schema-locations: classpath*:init.sql | ||
| 91 | encoding: UTF-8 | ||
| 92 | mode: never | ||
| 93 | redisson: | ||
| 94 | address: redis://redis-service.daop:6379 | ||
| 95 | password: "J7e411m693cA9" | ||
| 96 | 69 | ||
| 97 | seata: | 70 | seata: |
| 98 | enabled: true # 1.0新特性,需要依赖seata-spring-boot-starter,默认为true | 71 | enabled: true # 1.0新特性,需要依赖seata-spring-boot-starter,默认为true |
| ... | @@ -187,3 +160,5 @@ feign: | ... | @@ -187,3 +160,5 @@ feign: |
| 187 | query-limit: | 160 | query-limit: |
| 188 | white: TrTaskValid | 161 | white: TrTaskValid |
| 189 | 162 | ||
| 163 | isTenantAndHospital: false | ||
| 164 | ... | ... |
| ... | @@ -5,7 +5,7 @@ spring: | ... | @@ -5,7 +5,7 @@ spring: |
| 5 | nacos: | 5 | nacos: |
| 6 | #配置中心 | 6 | #配置中心 |
| 7 | config: | 7 | config: |
| 8 | server-addr: nacos-cluster-service-develop.nacos-cluster:8848 | 8 | server-addr: nacos-cluster-service.nacos-cluster:8848 |
| 9 | file-extension: yaml | 9 | file-extension: yaml |
| 10 | group: release | 10 | group: release |
| 11 | namespace: daop-lt | 11 | namespace: daop-lt |
| ... | @@ -16,7 +16,7 @@ spring: | ... | @@ -16,7 +16,7 @@ spring: |
| 16 | #注册中心 | 16 | #注册中心 |
| 17 | discovery: | 17 | discovery: |
| 18 | enabled: true | 18 | enabled: true |
| 19 | server-addr: nacos-cluster-service-develop.nacos-cluster:8848 | 19 | server-addr: nacos-cluster-service.nacos-cluster:8848 |
| 20 | group: release | 20 | group: release |
| 21 | namespace: daop-lt | 21 | namespace: daop-lt |
| 22 | metadata: | 22 | metadata: | ... | ... |
| 1 | server: | ||
| 2 | port: 19210 | ||
| 3 | monitor: | ||
| 4 | log-white: | ||
| 5 | #服务全局名称 | ||
| 6 | spring: | ||
| 7 | application: | ||
| 8 | name: ms-data-circulation-portal-service | ||
| 9 | jackson: | ||
| 10 | time-zone: Asia/Shanghai | ||
| 11 | cloud: | ||
| 12 | inetutils: | ||
| 13 | ignored-interfaces: docker0 # 让应用忽略docker0网卡 | ||
| 14 | compatibility-verifier: | ||
| 15 | enabled: false | ||
| 16 | gateway: | ||
| 17 | gatewayServiceName: gateway-server | ||
| 18 | host: 114.115.131.96 | ||
| 19 | kafka: | ||
| 20 | bootstrap-servers: kafka-cs-develop.daop:9092 | ||
| 21 | producer: | ||
| 22 | retries: 3 | ||
| 23 | main: | ||
| 24 | allow-bean-definition-overriding: true | ||
| 25 | datasource: | ||
| 26 | sql-script-encoding: utf-8 | ||
| 27 | #type: org.apache.commons.dbcp2.BasicDataSource | ||
| 28 | #如果使用TCC事务这个type必须指定,否则会抛出: org.springframework.jdbc.CannotGetJdbcConnectionException: Failed to obtain JDBC Connection; | ||
| 29 | dynamic: | ||
| 30 | primary: master | ||
| 31 | druid: | ||
| 32 | initial-size: 0 | ||
| 33 | max-active: 50 | ||
| 34 | min-idle: 2 | ||
| 35 | max-wait: -1 | ||
| 36 | min-evictable-idle-time-millis: 30000 | ||
| 37 | max-evictable-idle-time-millis: 30000 | ||
| 38 | time-between-eviction-runs-millis: 0 | ||
| 39 | validation-query: select 1 | ||
| 40 | validation-query-timeout: -1 | ||
| 41 | test-on-borrow: false | ||
| 42 | test-on-return: false | ||
| 43 | test-while-idle: true | ||
| 44 | pool-prepared-statements: true | ||
| 45 | # max-open-prepared-statements: 100 | ||
| 46 | filters: stat,wall | ||
| 47 | share-prepared-statements: true | ||
| 48 | wall: | ||
| 49 | config: | ||
| 50 | condition-double-const-allow: true | ||
| 51 | condition-and-alway-true-allow: true | ||
| 52 | ##由mycat管理读写分离 不用代码控制(填写mycat的链接库) | ||
| 53 | datasource: | ||
| 54 | master: | ||
| 55 | url: jdbc:mysql://192.168.6.21:3306/csbr_data_circulation_portal?useUnicode=true&characterEncoding=UTF-8&useSSL=false&autoReconnect=true&serverTimezone=Asia/Shanghai&connectTimeout=60000&socketTimeout=60000 | ||
| 56 | username: sharding | ||
| 57 | password: dJ5xF7qC | ||
| 58 | driver-class-name: com.mysql.cj.jdbc.Driver | ||
| 59 | druid: | ||
| 60 | initial-size: 5 | ||
| 61 | slave: | ||
| 62 | url: jdbc:mysql://192.168.6.21:3306/csbr_data_circulation_portal?useUnicode=true&characterEncoding=UTF-8&useSSL=false&autoReconnect=true&serverTimezone=Asia/Shanghai&connectTimeout=60000&socketTimeout=60000 | ||
| 63 | username: sharding | ||
| 64 | password: dJ5xF7qC | ||
| 65 | driver-class-name: com.mysql.cj.jdbc.Driver | ||
| 66 | druid: | ||
| 67 | initial-size: 5 | ||
| 68 | # redis配置 | ||
| 69 | data: | ||
| 70 | redis: | ||
| 71 | # 集群 | ||
| 72 | #cluster: | ||
| 73 | # nodes: redis-service.redis:6379 | ||
| 74 | # 单节点 | ||
| 75 | #host: redis-service.daop | ||
| 76 | #port: 6379 | ||
| 77 | #password: "J7e411m693cA9" | ||
| 78 | timeout: 1000 | ||
| 79 | prefix: daop-release | ||
| 80 | jedis: | ||
| 81 | pool: | ||
| 82 | max-idle: 8 | ||
| 83 | max-wait: 2000 | ||
| 84 | min-idle: 0 | ||
| 85 | max-active: 100 | ||
| 86 | test-on-borrow: true | ||
| 87 | test-while-idle: true | ||
| 88 | sql: | ||
| 89 | init: | ||
| 90 | schema-locations: classpath*:init.sql | ||
| 91 | encoding: UTF-8 | ||
| 92 | mode: never | ||
| 93 | redisson: | ||
| 94 | address: redis://redis-service.daop:6379 | ||
| 95 | password: "J7e411m693cA9" | ||
| 96 | |||
| 97 | seata: | ||
| 98 | enabled: true # 1.0新特性,需要依赖seata-spring-boot-starter,默认为true | ||
| 99 | tx-service-group: my_test_tx_group | ||
| 100 | application-id: ms-data-circulation-portal-service | ||
| 101 | registry: | ||
| 102 | type: nacos | ||
| 103 | nacos: | ||
| 104 | application: seata-server | ||
| 105 | cluster: seata-cluster | ||
| 106 | server-addr: nacos-cluster-service-develop.nacos-cluster:8848 | ||
| 107 | password: U9u457p155vH@8 | ||
| 108 | username: nacos | ||
| 109 | namespace: daop-lt | ||
| 110 | group: release | ||
| 111 | service: | ||
| 112 | vgroupMapping: | ||
| 113 | my_test_tx_group: seata-cluster | ||
| 114 | grouplist: | ||
| 115 | default: ms-daop-seata-service-release:8091 | ||
| 116 | |||
| 117 | #数据库字段开启驼峰 | ||
| 118 | mybatis: | ||
| 119 | configuration: | ||
| 120 | map-underscore-to-camel-case: true | ||
| 121 | callSettersOnNulls: true | ||
| 122 | log-impl: org.apache.ibatis.logging.stdout.StdOutImpl | ||
| 123 | mybatis-plus: | ||
| 124 | global-config: | ||
| 125 | db-config: | ||
| 126 | id-type: ASSIGN_UUID | ||
| 127 | logic-delete-value: "null" | ||
| 128 | logic-not-delete-value: N | ||
| 129 | mapper-locations: classpath*:mapper/**/*Mapper.xml | ||
| 130 | type-aliases-package: com.csbr.qingcloud.common.mybatis | ||
| 131 | ##生产环境屏蔽此配置 优化性能 | ||
| 132 | configuration: | ||
| 133 | log-impl: org.apache.ibatis.logging.stdout.StdOutImpl | ||
| 134 | pagehelper: | ||
| 135 | helperDialect: mysql | ||
| 136 | reasonable: true | ||
| 137 | supportMethodsArguments: true | ||
| 138 | params: count=countSql | ||
| 139 | |||
| 140 | csbr: | ||
| 141 | kafka: | ||
| 142 | topic-prefix: DAOP-LT-RELEASE | ||
| 143 | consumer: | ||
| 144 | # 开启kafka消费者 | ||
| 145 | enable: true | ||
| 146 | # kafka 服务集群地址,格式:HOST:PORT ,用逗号隔开 | ||
| 147 | # bootstrap-servers: 210.12.100.201:9092 | ||
| 148 | bootstrap-servers: kafka-cs-develop.daop:9092 | ||
| 149 | # bootstrap-servers: 192.168.3.120:9092 | ||
| 150 | # 是否启用自动提交 offset | ||
| 151 | enable-auto-commit: false | ||
| 152 | # 自动提交间隔时间(MS),仅在自动提交开启时有效 | ||
| 153 | auto-commit-interval: 100 | ||
| 154 | # 自动重置 offset。 latest:从最后开始,earliest: 从 offset 为 0 开始 | ||
| 155 | auto-offset-reset: latest | ||
| 156 | # 消息 key 的反序列化方法 | ||
| 157 | key-deserializer: org.apache.kafka.common.serialization.StringDeserializer | ||
| 158 | # 消息 value 的反序列化方法 | ||
| 159 | value-deserializer: org.apache.kafka.common.serialization.StringDeserializer | ||
| 160 | # listener 开启的线程数 | ||
| 161 | concurrency: 2 | ||
| 162 | # session 超时时间 | ||
| 163 | session-timeout: 60000 | ||
| 164 | # 最大 poll 消息间隔时间,如果处理时间过长会导致异常 | ||
| 165 | max-poll-interval: 10000 | ||
| 166 | # 最大 poll 消息数量 | ||
| 167 | max-poll-records: 2 | ||
| 168 | producer: | ||
| 169 | # 开启kafka生产者 | ||
| 170 | enable: true | ||
| 171 | # kafka 服务集群地址,格式:HOST:PORT ,多地址用逗号隔开 | ||
| 172 | # bootstrap-servers: 210.12.100.201:9092 | ||
| 173 | bootstrap-servers: kafka-cs-develop.daop:9092 | ||
| 174 | # bootstrap-servers: 192.168.3.120:9092 | ||
| 175 | # 失败后的重发次数 | ||
| 176 | retries: 0 | ||
| 177 | # 一次最多发送的数据量 | ||
| 178 | batch-size: 4096 | ||
| 179 | # 32M批处理缓冲区 | ||
| 180 | buffer-memory: 33554432 | ||
| 181 | # 生产者生产消息间隔,数值越大,间隔越长,用来减缓消费压力 | ||
| 182 | linger: 1 | ||
| 183 | feign: | ||
| 184 | hystrix: | ||
| 185 | enabled: false | ||
| 186 | |||
| 187 | query-limit: | ||
| 188 | white: TrTaskValid | ||
| 189 | |||
| 190 | isTenantAndHospital: false | ||
| 191 |
| 1 | spring: | ||
| 2 | application: | ||
| 3 | name: ms-data-circulation-portal-service | ||
| 4 | cloud: | ||
| 5 | nacos: | ||
| 6 | #配置中心 | ||
| 7 | config: | ||
| 8 | server-addr: nacos-cluster-service.nacos-cluster:8848 | ||
| 9 | file-extension: yaml | ||
| 10 | group: zq-release | ||
| 11 | namespace: daop-lt | ||
| 12 | # 开启nacos自动刷新,如果这个配置没有或者为false会导致配置不能自动刷新(auto-refresh、enable-remote-sync-config两者缺一不可) | ||
| 13 | auto-refresh: true | ||
| 14 | # 允许nacos服务端向本地同步配置 | ||
| 15 | enable-remote-sync-config: true | ||
| 16 | #注册中心 | ||
| 17 | discovery: | ||
| 18 | enabled: true | ||
| 19 | server-addr: nacos-cluster-service.nacos-cluster:8848 | ||
| 20 | group: zq-release | ||
| 21 | namespace: daop-lt | ||
| 22 | metadata: | ||
| 23 | code: "004" | ||
| 24 | user: | ||
| 25 | name: nacos | ||
| 26 | password: nacos | ||
| 27 | management: | ||
| 28 | context-path: /actuator | ||
| 29 | #接口限流 | ||
| 30 | sentinel: | ||
| 31 | transport: | ||
| 32 | # port: 7777 | ||
| 33 | dashboard: sentinel-service.nacos-cluster:8858 | ||
| 34 | #取消懒加载 | ||
| 35 | eager: true | ||
| 36 | management: | ||
| 37 | endpoint: | ||
| 38 | health: | ||
| 39 | show-details: always | ||
| 40 | endpoints: | ||
| 41 | web: | ||
| 42 | exposure: | ||
| 43 | include: '*' | ||
| 44 | ###暂时禁用rabbit的健康检查 | ||
| 45 | health: | ||
| 46 | rabbit: | ||
| 47 | enabled: false | ||
| 48 | sentinel: | ||
| 49 | enabled: false | ||
| 50 | feign: | ||
| 51 | sentinel: | ||
| 52 | enabled: true | ||
| ... | \ No newline at end of file | ... | \ No newline at end of file |
-
Please register or sign in to post a comment