From 6c87e763e74d57a14a617b0970e04618ee1aa599 Mon Sep 17 00:00:00 2001 From: PoffyZhang <99775271@qq.com> Date: Mon, 29 May 2023 10:57:58 +0800 Subject: [PATCH] =?UTF-8?q?=E5=BE=85=E5=8A=9E=E5=88=97=E8=A1=A8=E6=8A=A5?= =?UTF-8?q?=E9=94=99?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- kingbasesql/nd_purchase.sql | 32 ++++ .../controller/PurchaseController.java | 61 +++++++ .../projectdeclared/manage/PurchaseManage.java | 185 +++++++++++++++++++++ .../projectdeclared/mapper/PurchaseMapper.java | 16 ++ .../projectdeclared/mapper/PurchaseMapper.xml | 5 + .../projectdeclared/model/dto/PurchaseSaveDTO.java | 57 +++++++ .../projectdeclared/model/entity/Purchase.java | 78 +++++++++ .../pmapi/projectdeclared/model/vo/PurchaseVO.java | 70 ++++++++ .../projectdeclared/service/IPurchaseService.java | 16 ++ .../service/impl/PurchaseServiceImpl.java | 21 +++ .../pmapi/todocenter/manage/TodoCenterManage.java | 4 +- 11 files changed, 544 insertions(+), 1 deletion(-) create mode 100644 kingbasesql/nd_purchase.sql create mode 100644 pmapi/src/main/java/com/ningdatech/pmapi/projectdeclared/controller/PurchaseController.java create mode 100644 pmapi/src/main/java/com/ningdatech/pmapi/projectdeclared/manage/PurchaseManage.java create mode 100644 pmapi/src/main/java/com/ningdatech/pmapi/projectdeclared/mapper/PurchaseMapper.java create mode 100644 pmapi/src/main/java/com/ningdatech/pmapi/projectdeclared/mapper/PurchaseMapper.xml create mode 100644 pmapi/src/main/java/com/ningdatech/pmapi/projectdeclared/model/dto/PurchaseSaveDTO.java create mode 100644 pmapi/src/main/java/com/ningdatech/pmapi/projectdeclared/model/entity/Purchase.java create mode 100644 pmapi/src/main/java/com/ningdatech/pmapi/projectdeclared/model/vo/PurchaseVO.java create mode 100644 pmapi/src/main/java/com/ningdatech/pmapi/projectdeclared/service/IPurchaseService.java create mode 100644 pmapi/src/main/java/com/ningdatech/pmapi/projectdeclared/service/impl/PurchaseServiceImpl.java diff --git a/kingbasesql/nd_purchase.sql b/kingbasesql/nd_purchase.sql new file mode 100644 index 0000000..31b0c2f --- /dev/null +++ b/kingbasesql/nd_purchase.sql @@ -0,0 +1,32 @@ +CREATE TABLE PUBLIC."nd_purchase" ( + "id" BIGSERIAL NOT NULL, + "project_id" int8, + "create_on" TIMESTAMP, + "update_on" TIMESTAMP, + "create_by" VARCHAR(128), + "update_by" VARCHAR(128), + "supplier" VARCHAR(256) NOT NULL, + "supplier_contact" VARCHAR(256), + "supplier_contact_info" VARCHAR(256), + "purchase_method" INT2, + "transaction_amount" NUMERIC(12,2), + "transaction_time" TIMESTAMP, + "agency" VARCHAR(256), + "bidding_doc" TEXT, + "bid_doc" TEXT, + "acceptance_letter" TEXT, + CONSTRAINT "nd_purchase_PK" PRIMARY KEY ("id") +); + +comment ON COLUMN nd_purchase.id IS 'id'; +comment ON COLUMN nd_purchase.project_id IS '项目ID'; +comment ON COLUMN nd_purchase.supplier IS '供应商'; +comment ON COLUMN nd_purchase.supplier_contact IS '供应商联系人'; +comment ON COLUMN nd_purchase.supplier_contact_info IS '供应商联系方式'; +comment ON COLUMN nd_purchase.purchase_method IS '采购方式'; +comment ON COLUMN nd_purchase.transaction_amount IS '成交金额'; +comment ON COLUMN nd_purchase.transaction_time IS '成交时间'; +comment ON COLUMN nd_purchase.agency IS '代理机构'; +comment ON COLUMN nd_purchase.bidding_doc IS '投标文件'; +comment ON COLUMN nd_purchase.bid_doc IS '招标文件'; +comment ON COLUMN nd_purchase.acceptance_letter IS '中标通知书'; \ No newline at end of file diff --git a/pmapi/src/main/java/com/ningdatech/pmapi/projectdeclared/controller/PurchaseController.java b/pmapi/src/main/java/com/ningdatech/pmapi/projectdeclared/controller/PurchaseController.java new file mode 100644 index 0000000..ffca41c --- /dev/null +++ b/pmapi/src/main/java/com/ningdatech/pmapi/projectdeclared/controller/PurchaseController.java @@ -0,0 +1,61 @@ +package com.ningdatech.pmapi.projectdeclared.controller; + +import com.ningdatech.basic.model.PageVo; +import com.ningdatech.pmapi.common.util.ExcelDownUtil; +import com.ningdatech.pmapi.projectdeclared.manage.ProjectAdjustmentManage; +import com.ningdatech.pmapi.projectdeclared.manage.PurchaseManage; +import com.ningdatech.pmapi.projectdeclared.model.dto.PurchaseSaveDTO; +import com.ningdatech.pmapi.projectdeclared.model.vo.PurchaseVO; +import com.ningdatech.pmapi.projectlib.model.req.ProjectListReq; +import com.ningdatech.pmapi.projectlib.model.vo.ProjectLibListItemVO; +import io.swagger.annotations.Api; +import io.swagger.annotations.ApiOperation; +import lombok.RequiredArgsConstructor; +import lombok.extern.slf4j.Slf4j; +import org.springframework.validation.annotation.Validated; +import org.springframework.web.bind.annotation.*; +import javax.servlet.http.HttpServletResponse; + +/** + * @Classname PurchaseController + * @Description 申报项目-采购结果备案 + * @Date 2023/5/29 09:29 + * @Author PoffyZhang + */ +@Slf4j +@Validated +@RestController +@RequestMapping("/api/v1/declared/purchase") +@Api(value = "PurchaseController", tags = "申报管理-采购结果备案") +@RequiredArgsConstructor +public class PurchaseController { + private final PurchaseManage purchaseManage; + + private final ProjectAdjustmentManage projectAdjustmentManage; + + @ApiOperation(value = "待采购结果备案列表", notes = "待采购结果备案列表") + @GetMapping("/project-list") + public PageVo projectlist(@ModelAttribute ProjectListReq req) { + return purchaseManage.projectLibList(req); + } + + @ApiOperation(value = "采购结果备案详情", notes = "采购结果备案详情") + @GetMapping("/detail/{ProjectId}") + public PurchaseVO detailByProjectId(@PathVariable Long ProjectId) { + return purchaseManage.detailByProjectId(ProjectId); + } + + @GetMapping("/export") + @ApiOperation("待采购结果备案列表导出") + public void exportList(ProjectListReq req, HttpServletResponse response){ + ExcelDownUtil.downXls(response,req,purchaseManage::exportList); + } + + @ApiOperation(value = "填写采购结果", notes = "填写采购结果") + @PostMapping("/submit-result") + public String submitResult(@Validated @RequestBody PurchaseSaveDTO dto) { + return purchaseManage.submitResult(dto); + } + + +} diff --git a/pmapi/src/main/java/com/ningdatech/pmapi/projectdeclared/manage/PurchaseManage.java b/pmapi/src/main/java/com/ningdatech/pmapi/projectdeclared/manage/PurchaseManage.java new file mode 100644 index 0000000..ab38ab4 --- /dev/null +++ b/pmapi/src/main/java/com/ningdatech/pmapi/projectdeclared/manage/PurchaseManage.java @@ -0,0 +1,185 @@ +package com.ningdatech.pmapi.projectdeclared.manage; + +import cn.hutool.core.bean.BeanUtil; +import com.alibaba.excel.EasyExcel; +import com.baomidou.mybatisplus.core.conditions.query.LambdaQueryWrapper; +import com.baomidou.mybatisplus.core.toolkit.Wrappers; +import com.baomidou.mybatisplus.extension.plugins.pagination.Page; +import com.ningdatech.basic.function.VUtils; +import com.ningdatech.basic.model.PageVo; +import com.ningdatech.basic.util.CollUtils; +import com.ningdatech.basic.util.NdDateUtils; +import com.ningdatech.pmapi.common.constant.BizConst; +import com.ningdatech.pmapi.common.enumeration.ProjectProcessStageEnum; +import com.ningdatech.pmapi.common.helper.UserInfoHelper; +import com.ningdatech.pmapi.common.util.ExcelDownUtil; +import com.ningdatech.pmapi.common.util.ExcelExportStyle; +import com.ningdatech.pmapi.projectdeclared.model.dto.*; +import com.ningdatech.pmapi.projectdeclared.model.entity.Purchase; +import com.ningdatech.pmapi.projectdeclared.model.vo.PurchaseVO; +import com.ningdatech.pmapi.projectdeclared.service.IProjectDraftService; +import com.ningdatech.pmapi.projectdeclared.service.IPurchaseService; +import com.ningdatech.pmapi.projectlib.enumeration.ProjectStatusEnum; +import com.ningdatech.pmapi.projectlib.enumeration.ProjectTypeEnum; +import com.ningdatech.pmapi.projectlib.helper.ProjectHelper; +import com.ningdatech.pmapi.projectlib.model.dto.ProjectDTO; +import com.ningdatech.pmapi.projectlib.model.entity.Project; +import com.ningdatech.pmapi.projectlib.model.req.ProjectListReq; +import com.ningdatech.pmapi.projectlib.model.vo.ProjectLibListItemVO; +import com.ningdatech.pmapi.projectlib.service.IProjectService; +import com.ningdatech.pmapi.user.security.auth.model.UserFullInfoDTO; +import com.ningdatech.pmapi.user.util.LoginUserUtil; +import com.wflow.bean.entity.WflowModels; +import com.wflow.exception.BusinessException; +import lombok.RequiredArgsConstructor; +import lombok.extern.slf4j.Slf4j; +import org.apache.commons.lang3.StringUtils; +import org.springframework.beans.BeanUtils; +import org.springframework.stereotype.Component; +import javax.servlet.http.HttpServletResponse; +import java.io.IOException; +import java.time.LocalDateTime; +import java.util.List; +import java.util.Objects; +import java.util.concurrent.atomic.AtomicInteger; +import java.util.stream.Collectors; + +/** + * @Classname PurchaseManage + * @Description + * @Date 2023/5/29 14:48 + * @Author PoffyZhang + */ +@Component +@Slf4j +@RequiredArgsConstructor +public class PurchaseManage { + + private final IProjectService projectService; + private final UserInfoHelper userInfoHelper; + + private final IPurchaseService purchaseService; + + /** + * 待采购的-项目列表 + * @param req + * @return + */ + public PageVo projectLibList(ProjectListReq req) { + UserFullInfoDTO user = userInfoHelper.getUserFullInfo(LoginUserUtil.getUserId()); + VUtils.isTrue(Objects.isNull(user)).throwMessage("获取登录用户失败!"); + LambdaQueryWrapper query = ProjectHelper.projectQuery(req); + //待采购状态 + query.eq(Project::getStatus,ProjectStatusEnum.TO_BE_PURCHASED.getCode()); + query.eq(Project::getStage,ProjectStatusEnum.PROJECT_APPROVED.getCode()); + query.eq(Project::getNewest,Boolean.TRUE); + Page page = projectService.page(req.page(), query); + long total; + if ((total = page.getTotal()) == 0) { + return PageVo.empty(); + } + List records = CollUtils.convert(page.getRecords(), w -> { + ProjectLibListItemVO item = new ProjectLibListItemVO(); + item.setId(w.getId()); + item.setProjectName(w.getProjectName()); + item.setCreateOn(w.getCreateOn()); + item.setDeclaredAmount(w.getDeclareAmount()); + item.setStage(w.getStage()); + item.setStatus(w.getStatus()); + item.setProjectType(w.getProjectType()); + item.setProjectYear(w.getProjectYear()); + item.setBuildOrg(w.getBuildOrgName()); + item.setBizDomain(w.getBizDomain()); + item.setProcessStatus(w.getProcessStatus()); + item.setInstCode(w.getInstCode()); + item.setIsHigherSuperOrg(w.getIsHigherSuperOrg()); + return item; + }); + return PageVo.of(records, total); + } + + public void exportList(HttpServletResponse response, ProjectListReq param) { + UserFullInfoDTO user = userInfoHelper.getUserFullInfo(LoginUserUtil.getUserId()); + VUtils.isTrue(Objects.isNull(user)).throwMessage("获取登录用户失败!"); + LambdaQueryWrapper query = ProjectHelper.projectQuery(param); + //待采购状态 + query.eq(Project::getStatus,ProjectStatusEnum.TO_BE_PURCHASED.getCode()); + query.eq(Project::getStage,ProjectStatusEnum.PROJECT_APPROVED.getCode()); + query.eq(Project::getNewest,Boolean.TRUE); + List records = projectService.list(query); + + AtomicInteger serialNumber = new AtomicInteger(0); + List collect = records.stream().map(r -> { + DeclaredProjectExportDTO exportDTO = new DeclaredProjectExportDTO(); + BeanUtils.copyProperties(r, exportDTO); + exportDTO.setProjectTypeName(ProjectTypeEnum.getDesc(r.getProjectType())); + exportDTO.setStatusName(ProjectStatusEnum.getDesc(r.getStatus())); + String createOnStr = NdDateUtils.format(r.getCreateOn(), "yyyy-MM-dd HH:mm"); + exportDTO.setCreateOn(createOnStr); + exportDTO.setSerialNumber(serialNumber.incrementAndGet()); + return exportDTO; + }).collect(Collectors.toList()); + String fileName = "采购结果待备案项目列表"; + ExcelDownUtil.setFileName(fileName,response); + //数据导出处理函数 + try { + EasyExcel.write(response.getOutputStream(), DeclaredProjectExportDTO.class) + .autoCloseStream(false) + .registerWriteHandler(ExcelExportStyle.formalStyle()) + .sheet(fileName) + .doWrite(collect); + } catch (IOException e) { + throw new RuntimeException(e); + } + } + + /** + * 获取采购结果备案详情 + * @param projectId + * @return + */ + public PurchaseVO detailByProjectId(Long projectId) { + Purchase purchase = purchaseService.getOne(Wrappers.lambdaQuery(Purchase.class) + .eq(Purchase::getProjectId, projectId) + .last(BizConst.LIMIT_1)); + + return BeanUtil.copyProperties(purchase,PurchaseVO.class); + } + + /** + * 填写采购结果 + * @param dto + * @return + */ + public String submitResult(PurchaseSaveDTO dto) { + UserFullInfoDTO user = userInfoHelper.getUserFullInfo(LoginUserUtil.getUserId()); + String employeeCode = user.getEmployeeCode(); + VUtils.isTrue(StringUtils.isBlank(employeeCode)).throwMessage("获取登录用户 员工号 失败!"); + + Long projectId = dto.getProjectId(); + VUtils.isTrue(Objects.isNull(projectId)).throwMessage("提交失败 缺少项目ID!"); + Project projectInfo = projectService.getById(projectId); + VUtils.isTrue(Objects.isNull(projectInfo)).throwMessage("提交失败 此项目不存在!"); + + //首先要判断 项目当前状态 是不是 采购结果备案 + VUtils.isTrue(!ProjectStatusEnum.TO_BE_PURCHASED.getCode().equals(projectInfo.getStatus()) || + !ProjectStatusEnum.PROJECT_APPROVED.getCode().equals(projectInfo.getStage())) + .throwMessage("提交失败 该项目不是 待采购备案状态或者已立项阶段"); + + Purchase purchaseEntity = new Purchase(); + Purchase purchase = purchaseService.getOne(Wrappers.lambdaQuery(Purchase.class) + .eq(Purchase::getProjectId, projectId) + .last(BizConst.LIMIT_1)); + + BeanUtil.copyProperties(dto,purchaseEntity); + if(Objects.isNull(purchase)){ + purchaseEntity.setCreateOn(LocalDateTime.now()); + purchaseEntity.setCreateBy(employeeCode); + }else{ + purchaseEntity.setId(purchase.getId()); + } + purchaseEntity.setProjectId(projectId); + purchaseService.saveOrUpdate(purchaseEntity); + return "填写成功"; + } +} diff --git a/pmapi/src/main/java/com/ningdatech/pmapi/projectdeclared/mapper/PurchaseMapper.java b/pmapi/src/main/java/com/ningdatech/pmapi/projectdeclared/mapper/PurchaseMapper.java new file mode 100644 index 0000000..121ace6 --- /dev/null +++ b/pmapi/src/main/java/com/ningdatech/pmapi/projectdeclared/mapper/PurchaseMapper.java @@ -0,0 +1,16 @@ +package com.ningdatech.pmapi.projectdeclared.mapper; + +import com.baomidou.mybatisplus.core.mapper.BaseMapper; +import com.ningdatech.pmapi.projectdeclared.model.entity.Purchase; + +/** + *

+ * Mapper 接口 + *

+ * + * @author zpf + * @since 2023-02-05 + */ +public interface PurchaseMapper extends BaseMapper { + +} diff --git a/pmapi/src/main/java/com/ningdatech/pmapi/projectdeclared/mapper/PurchaseMapper.xml b/pmapi/src/main/java/com/ningdatech/pmapi/projectdeclared/mapper/PurchaseMapper.xml new file mode 100644 index 0000000..ad43270 --- /dev/null +++ b/pmapi/src/main/java/com/ningdatech/pmapi/projectdeclared/mapper/PurchaseMapper.xml @@ -0,0 +1,5 @@ + + + + + diff --git a/pmapi/src/main/java/com/ningdatech/pmapi/projectdeclared/model/dto/PurchaseSaveDTO.java b/pmapi/src/main/java/com/ningdatech/pmapi/projectdeclared/model/dto/PurchaseSaveDTO.java new file mode 100644 index 0000000..2d3d6b6 --- /dev/null +++ b/pmapi/src/main/java/com/ningdatech/pmapi/projectdeclared/model/dto/PurchaseSaveDTO.java @@ -0,0 +1,57 @@ +package com.ningdatech.pmapi.projectdeclared.model.dto; + +import io.swagger.annotations.ApiModel; +import io.swagger.annotations.ApiModelProperty; +import lombok.AllArgsConstructor; +import lombok.Data; + +import javax.validation.constraints.NotNull; +import java.math.BigDecimal; +import java.time.LocalDateTime; + +/** + * @Classname Purchase + * @Description + * @Date 2023/5/29 10:00 + * @Author PoffyZhang + */ +@ApiModel(value = "采购对象", description = "采购对象") +@Data +@AllArgsConstructor +public class PurchaseSaveDTO { + + @ApiModelProperty("项目ID") + @NotNull(message = "请传项目ID") + private Long projectId; + + @ApiModelProperty("供应商") + private String supplier; + + @ApiModelProperty("供应商联系人") + private String supplierContact; + + @ApiModelProperty("供应商联系方式") + private String supplierContactInfo; + + @ApiModelProperty("采购方式 1公开招标 2自行采购") + private Integer purchaseMethod; + + @ApiModelProperty("成交金额") + private BigDecimal transactionAmount; + + @ApiModelProperty("成交时间") + private LocalDateTime transactionTime; + + @ApiModelProperty("代理机构") + private String agency; + + @ApiModelProperty("投标文件") + private String biddingDoc; + + @ApiModelProperty("招标文件") + private String bidDoc; + + @ApiModelProperty("中标通知书") + private String acceptanceLetter; + +} diff --git a/pmapi/src/main/java/com/ningdatech/pmapi/projectdeclared/model/entity/Purchase.java b/pmapi/src/main/java/com/ningdatech/pmapi/projectdeclared/model/entity/Purchase.java new file mode 100644 index 0000000..fdc1c8a --- /dev/null +++ b/pmapi/src/main/java/com/ningdatech/pmapi/projectdeclared/model/entity/Purchase.java @@ -0,0 +1,78 @@ +package com.ningdatech.pmapi.projectdeclared.model.entity; + +import com.baomidou.mybatisplus.annotation.IdType; +import com.baomidou.mybatisplus.annotation.TableId; +import com.baomidou.mybatisplus.annotation.TableName; +import io.swagger.annotations.ApiModel; +import io.swagger.annotations.ApiModelProperty; +import lombok.AllArgsConstructor; +import lombok.Data; +import lombok.NoArgsConstructor; + +import javax.validation.constraints.NotNull; +import java.math.BigDecimal; +import java.time.LocalDateTime; + +/** + * @Classname Purchase + * @Description + * @Date 2023/5/29 10:00 + * @Author PoffyZhang + */ +@TableName("nd_purchase") +@ApiModel(value = "采购对象", description = "采购对象") +@Data +@AllArgsConstructor +@NoArgsConstructor +public class Purchase { + + @TableId(type = IdType.AUTO) + @ApiModelProperty("id") + private Long id; + + @ApiModelProperty("项目ID") + private Long projectId; + + @ApiModelProperty("创建时间") + private LocalDateTime createOn; + + @ApiModelProperty("修改时间") + private LocalDateTime updateOn; + + @ApiModelProperty("创建人 工号") + private String createBy; + + @ApiModelProperty("修改人 工号") + private String updateBy; + + @ApiModelProperty("供应商") + private String supplier; + + @ApiModelProperty("供应商联系人") + private String supplierContact; + + @ApiModelProperty("供应商联系方式") + private String supplierContactInfo; + + @ApiModelProperty("采购方式 1公开招标 2自行采购") + private Integer purchaseMethod; + + @ApiModelProperty("成交金额") + private BigDecimal transactionAmount; + + @ApiModelProperty("成交时间") + private LocalDateTime transactionTime; + + @ApiModelProperty("代理机构") + private String agency; + + @ApiModelProperty("投标文件") + private String biddingDoc; + + @ApiModelProperty("招标文件") + private String bidDoc; + + @ApiModelProperty("中标通知书") + private String acceptanceLetter; + +} diff --git a/pmapi/src/main/java/com/ningdatech/pmapi/projectdeclared/model/vo/PurchaseVO.java b/pmapi/src/main/java/com/ningdatech/pmapi/projectdeclared/model/vo/PurchaseVO.java new file mode 100644 index 0000000..e800520 --- /dev/null +++ b/pmapi/src/main/java/com/ningdatech/pmapi/projectdeclared/model/vo/PurchaseVO.java @@ -0,0 +1,70 @@ +package com.ningdatech.pmapi.projectdeclared.model.vo; + +import io.swagger.annotations.ApiModel; +import io.swagger.annotations.ApiModelProperty; +import lombok.AllArgsConstructor; +import lombok.Data; + +import java.math.BigDecimal; +import java.time.LocalDateTime; + +/** + * @Classname Purchase + * @Description + * @Date 2023/5/29 10:00 + * @Author PoffyZhang + */ +@ApiModel(value = "采购对象", description = "采购对象") +@Data +@AllArgsConstructor +public class PurchaseVO { + + @ApiModelProperty("id") + private Long id; + + @ApiModelProperty("项目ID") + private Long projectId; + + @ApiModelProperty("创建时间") + private LocalDateTime createOn; + + @ApiModelProperty("修改时间") + private LocalDateTime updateOn; + + @ApiModelProperty("创建人 工号") + private String createBy; + + @ApiModelProperty("修改人 工号") + private String updateBy; + + @ApiModelProperty("供应商") + private String supplier; + + @ApiModelProperty("供应商联系人") + private String supplierContact; + + @ApiModelProperty("供应商联系方式") + private String supplierContactInfo; + + @ApiModelProperty("采购方式 1公开招标 2自行采购") + private Integer purchaseMethod; + + @ApiModelProperty("成交金额") + private BigDecimal transactionAmount; + + @ApiModelProperty("成交时间") + private LocalDateTime transactionTime; + + @ApiModelProperty("代理机构") + private String agency; + + @ApiModelProperty("投标文件") + private String biddingDoc; + + @ApiModelProperty("招标文件") + private String bidDoc; + + @ApiModelProperty("中标通知书") + private String acceptanceLetter; + +} diff --git a/pmapi/src/main/java/com/ningdatech/pmapi/projectdeclared/service/IPurchaseService.java b/pmapi/src/main/java/com/ningdatech/pmapi/projectdeclared/service/IPurchaseService.java new file mode 100644 index 0000000..017da01 --- /dev/null +++ b/pmapi/src/main/java/com/ningdatech/pmapi/projectdeclared/service/IPurchaseService.java @@ -0,0 +1,16 @@ +package com.ningdatech.pmapi.projectdeclared.service; + +import com.baomidou.mybatisplus.extension.service.IService; +import com.ningdatech.pmapi.projectdeclared.model.entity.Purchase; + +/** + *

+ * 服务类 + *

+ * + * @author zpf + * @since 2023-05-29 + */ +public interface IPurchaseService extends IService { + +} diff --git a/pmapi/src/main/java/com/ningdatech/pmapi/projectdeclared/service/impl/PurchaseServiceImpl.java b/pmapi/src/main/java/com/ningdatech/pmapi/projectdeclared/service/impl/PurchaseServiceImpl.java new file mode 100644 index 0000000..5155258 --- /dev/null +++ b/pmapi/src/main/java/com/ningdatech/pmapi/projectdeclared/service/impl/PurchaseServiceImpl.java @@ -0,0 +1,21 @@ +package com.ningdatech.pmapi.projectdeclared.service.impl; + +import com.baomidou.mybatisplus.extension.service.impl.ServiceImpl; +import com.ningdatech.pmapi.projectdeclared.mapper.PurchaseMapper; +import com.ningdatech.pmapi.projectdeclared.model.entity.Purchase; +import com.ningdatech.pmapi.projectdeclared.service.IPurchaseService; +import org.springframework.stereotype.Service; + +/** + *

+ * 服务实现类 + *

+ * + * @author zpf + * @since 2023-02-05 + */ +@Service +public class PurchaseServiceImpl extends ServiceImpl + implements IPurchaseService { + +} diff --git a/pmapi/src/main/java/com/ningdatech/pmapi/todocenter/manage/TodoCenterManage.java b/pmapi/src/main/java/com/ningdatech/pmapi/todocenter/manage/TodoCenterManage.java index 5f934e3..c65e4b8 100644 --- a/pmapi/src/main/java/com/ningdatech/pmapi/todocenter/manage/TodoCenterManage.java +++ b/pmapi/src/main/java/com/ningdatech/pmapi/todocenter/manage/TodoCenterManage.java @@ -230,7 +230,9 @@ public class TodoCenterManage { } private String findSubProcessName(ProcessTaskVo d) { - + if(StringUtils.isBlank(d.getProcessDefId())){ + return null; + } BpmnModel bpmnModel = repositoryService.getBpmnModel(d.getProcessDefId()); if(Objects.nonNull(bpmnModel)){