map = new HashMap<>(4);
+ map.put("mapList", list);
+ map.put("mapList1", null);
+ Workbook workbook = ExcelExportUtil.exportExcel(temp, map);
+ if (workbook == null) {
+ throw new BizException("读取模板失败!");
+ }
+ // 重置响应对象
+ response.reset();
+ try {
+ response.setHeader("Content-disposition",
+ "attachment;filename*=utf-8''" + URLEncoder.encode(Objects.requireNonNull(fileName), "UTF-8") + ".xls");
+ } catch (UnsupportedEncodingException e) {
+ e.printStackTrace();
+ }
+ response.setContentType(ExcelUtil.XLS_CONTENT_TYPE);
+ response.setHeader("Pragma", "no-cache");
+ response.setHeader("Cache-Control", "no-cache");
+ response.setDateHeader("Expires", 0);
+ // 写出数据输出流到页面
+ try {
+ OutputStream output = response.getOutputStream();
+ BufferedOutputStream bufferedOutPut = new BufferedOutputStream(output);
+ workbook.write(bufferedOutPut);
+ bufferedOutPut.flush();
+ bufferedOutPut.close();
+ output.close();
+ } catch (IOException e) {
+ e.printStackTrace();
+ }
+ }
}
diff --git a/pmapi/src/main/java/com/ningdatech/pmapi/projectlib/manage/ProjectLibManage.java b/pmapi/src/main/java/com/ningdatech/pmapi/projectlib/manage/ProjectLibManage.java
index 424bc86..b4003e4 100644
--- a/pmapi/src/main/java/com/ningdatech/pmapi/projectlib/manage/ProjectLibManage.java
+++ b/pmapi/src/main/java/com/ningdatech/pmapi/projectlib/manage/ProjectLibManage.java
@@ -1,38 +1,47 @@
package com.ningdatech.pmapi.projectlib.manage;
+import cn.hutool.core.bean.BeanUtil;
+import cn.hutool.core.bean.copier.CopyOptions;
+import cn.hutool.core.collection.CollUtil;
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.google.common.collect.Lists;
+import com.ningdatech.basic.function.VUtils;
import com.ningdatech.basic.model.PageVo;
import com.ningdatech.basic.util.CollUtils;
import com.ningdatech.file.entity.File;
import com.ningdatech.file.service.FileService;
import com.ningdatech.pmapi.common.constant.CommonConst;
import com.ningdatech.pmapi.common.constant.RegionConst;
+import com.ningdatech.pmapi.common.enumeration.CommonEnum;
+import com.ningdatech.pmapi.common.enumeration.ProjectProcessStageEnum;
import com.ningdatech.pmapi.common.helper.RegionCacheHelper;
import com.ningdatech.pmapi.common.helper.UserInfoHelper;
import com.ningdatech.pmapi.common.model.entity.ExcelExportWriter;
+import com.ningdatech.pmapi.common.statemachine.util.StateMachineUtils;
import com.ningdatech.pmapi.common.util.BizUtils;
import com.ningdatech.pmapi.common.util.ExcelDownUtil;
import com.ningdatech.pmapi.datascope.model.DataScopeDTO;
import com.ningdatech.pmapi.datascope.utils.DataScopeUtil;
+import com.ningdatech.pmapi.projectdeclared.utils.GenerateProjectCodeUtil;
import com.ningdatech.pmapi.projectlib.enumeration.ProjectStatusEnum;
import com.ningdatech.pmapi.projectlib.handle.ProcessExecuteChainHandle;
import com.ningdatech.pmapi.projectlib.helper.ProjectHelper;
+import com.ningdatech.pmapi.projectlib.model.dto.ProjectApplicationDTO;
+import com.ningdatech.pmapi.projectlib.model.dto.ProjectDTO;
import com.ningdatech.pmapi.projectlib.model.entity.Project;
import com.ningdatech.pmapi.projectlib.model.entity.ProjectApplication;
+import com.ningdatech.pmapi.projectlib.model.entity.ProjectInst;
import com.ningdatech.pmapi.projectlib.model.entity.ProjectRenewalFundDeclaration;
import com.ningdatech.pmapi.projectlib.model.req.ProjectListReq;
import com.ningdatech.pmapi.projectlib.model.vo.AnnualAmountVO;
import com.ningdatech.pmapi.projectlib.model.vo.ProjectDetailVO;
import com.ningdatech.pmapi.projectlib.model.vo.ProjectLibListItemVO;
-import com.ningdatech.pmapi.projectlib.service.INdProjectStatusChangeService;
-import com.ningdatech.pmapi.projectlib.service.IProjectApplicationService;
-import com.ningdatech.pmapi.projectlib.service.IProjectRenewalFundDeclarationService;
-import com.ningdatech.pmapi.projectlib.service.IProjectService;
+import com.ningdatech.pmapi.projectlib.service.*;
import com.ningdatech.pmapi.user.security.auth.model.UserFullInfoDTO;
import com.ningdatech.pmapi.user.util.LoginUserUtil;
+import com.wflow.exception.BusinessException;
import com.wflow.workflow.bean.vo.ProcessDetailVO;
import lombok.RequiredArgsConstructor;
import lombok.extern.slf4j.Slf4j;
@@ -41,7 +50,9 @@ import org.springframework.beans.BeanUtils;
import org.springframework.stereotype.Component;
import javax.servlet.http.HttpServletResponse;
+import java.time.LocalDateTime;
import java.util.*;
+import java.util.stream.Collectors;
/**
*
@@ -60,14 +71,18 @@ public class ProjectLibManage {
private final IProjectApplicationService applicationService;
private final IProjectRenewalFundDeclarationService renewalFundDeclarationService;
private final ProcessExecuteChainHandle processExecuteHandle;
- private final INdProjectStatusChangeService projectStatusChangeService;
private final RegionCacheHelper regionCacheHelper;
private final FileService fileService;
-
private final UserInfoHelper userInfoHelper;
+ private final IProjectApplicationService projectApplicationService;
+ private final GenerateProjectCodeUtil generateProjectCodeUtil;
+ private final IProjectInstService projectInstService;
+
+ private final StateMachineUtils stateMachineUtils;
public PageVo projectLibList(ProjectListReq req) {
LambdaQueryWrapper query = ProjectHelper.projectQuery(req);
+ query.eq(Project::getNewest,Boolean.TRUE);
Page page = projectService.page(req.page(), query);
long total;
if ((total = page.getTotal()) == 0) {
@@ -96,6 +111,8 @@ public class ProjectLibManage {
public PageVo projectLibListWithPermission(ProjectListReq req) {
LambdaQueryWrapper query = ProjectHelper.projectQuery(req);
UserFullInfoDTO user = buildProjectLibPermission(query);
+ //项目查最新
+ query.eq(Project::getNewest,Boolean.TRUE);
Page page = projectService.page(req.page(), query);
long total;
if ((total = page.getTotal()) == 0) {
@@ -133,6 +150,187 @@ public class ProjectLibManage {
}
/**
+ * 申报新项目时 保存项目信息和其它相关联的信息
+ * @param projectDto
+ * @param instanceId
+ * @param employeeCode
+ * @return
+ */
+ public Project saveProjectInDeclared(ProjectDTO projectDto, String instanceId,
+ String employeeCode) {
+ Project project = saveProjectNewVersion(projectDto,instanceId,employeeCode);
+ //保存项目和实例的关系
+ ProjectInst projectInst = new ProjectInst();
+ projectInst.setProjectId(project.getId());
+ projectInst.setInstCode(instanceId);
+ projectInst.setCreatOn(LocalDateTime.now());
+ projectInst.setUpdateOn(LocalDateTime.now());
+ projectInst.setInstType(ProjectProcessStageEnum.ORG_INTERNAL_APPROVAL_PROCESS.getCode());
+ projectInstService.save(projectInst);
+ return project;
+ }
+
+ /**
+ * 申报新项目时 保存项目信息和其它相关联的信息
+ * @param projectDto
+ * @param instanceId
+ * @param employeeCode
+ * @return
+ */
+ public Project saveProjectNewVersion(ProjectDTO projectDto, String instanceId,
+ String employeeCode) {
+ //流程启动之后 入库项目 重要业务信息 用于列表查询 展示
+ try {
+ Project project = new Project();
+ //为空 代表是新申报的
+ if(Objects.isNull(projectDto.getId())){
+ BeanUtils.copyProperties(projectDto, project);
+ project.setCreateOn(LocalDateTime.now());
+ project.setUpdateOn(LocalDateTime.now());
+ project.setStage(ProjectStatusEnum.NOT_APPROVED.getCode());
+ project.setStatus(ProjectStatusEnum.UNDER_INTERNAL_AUDIT.getCode());
+ project.setInstCode(instanceId);
+ project.setSponsor(employeeCode);
+ String projectCode = generateProjectCodeUtil.generateProjectCode(projectDto);
+ project.setProjectCode(projectCode);
+ projectService.save(project);
+ }else{
+ //否则是重新提交的 新生成一个新版本的项目
+ project = newProjectWithVersion(projectDto);
+ project.setInstCode(instanceId);
+ project.setSponsor(employeeCode);
+ projectService.updateById(project);
+ }
+
+ //保存项目应用
+ Boolean isApp = Objects.nonNull(projectDto.getIncludeApplication()) && CommonEnum.YES.getCode().equals(projectDto.getIncludeApplication())
+ ? Boolean.TRUE : Boolean.FALSE;
+ //采取批量删除 批量添加的方式
+ projectApplicationService.remove(Wrappers.lambdaQuery(ProjectApplication.class)
+ .eq(ProjectApplication::getProjectId,project.getId()));
+ if (isApp && CollUtil.isNotEmpty(projectDto.getApplicationList())) {
+ Project finalProject = project;
+ List applications = projectDto.getApplicationList().stream().map(application -> {
+ ProjectApplication projectApplication = new ProjectApplication();
+ BeanUtils.copyProperties(application, projectApplication);
+ projectApplication.setProjectId(finalProject.getId());
+ return projectApplication;
+ }).collect(Collectors.toList());
+ projectApplicationService.saveOrUpdateBatch(applications);
+ }
+ return project;
+ } catch (Exception e) {
+ log.error("项目信息入库错误 " + e);
+ throw new BusinessException("项目信息入库错误 :" + e);
+ }
+ }
+
+ /**
+ * 在其它项目阶段 保存项目信息和其它相关联的信息
+ * @param projectDto
+ * @return
+ */
+ public Project reSaveProjectNewVersion(ProjectDTO projectDto) {
+ //流程启动之后 入库项目 重要业务信息 用于列表查询 展示
+ try {
+ Project project = newProjectWithVersion(projectDto);
+
+ //保存项目应用
+ Boolean isApp = Objects.nonNull(projectDto.getIncludeApplication()) && CommonEnum.YES.getCode().equals(projectDto.getIncludeApplication())
+ ? Boolean.TRUE : Boolean.FALSE;
+ //采取批量删除 批量添加的方式
+ projectApplicationService.remove(Wrappers.lambdaQuery(ProjectApplication.class)
+ .eq(ProjectApplication::getProjectId,project.getId()));
+ if (isApp && CollUtil.isNotEmpty(projectDto.getApplicationList())) {
+ Project finalProject = project;
+ List applications = projectDto.getApplicationList().stream().map(application -> {
+ ProjectApplication projectApplication = new ProjectApplication();
+ BeanUtils.copyProperties(application, projectApplication);
+ projectApplication.setProjectId(finalProject.getId());
+ return projectApplication;
+ }).collect(Collectors.toList());
+ projectApplicationService.saveOrUpdateBatch(applications);
+ }
+ return project;
+ } catch (Exception e) {
+ log.error("项目信息入库错误 " + e);
+ throw new BusinessException("项目信息入库错误 :" + e);
+ }
+ }
+
+ /**
+ * 重新提交工作流时 舍弃在原有项目修改
+ * 新增一个新的项目 新的版本号
+ */
+ public Project newProjectWithVersion(ProjectDTO projecDto){
+ Project oldProject = projectService.getById(projecDto.getId());
+ Project project = new Project();
+ VUtils.isTrue(Objects.isNull(oldProject))
+ .throwMessage("项目不存在!");
+ BeanUtil.copyProperties(oldProject,project, CopyOptions.create()
+ .setIgnoreError(Boolean.TRUE).setIgnoreNullValue(Boolean.TRUE));
+ BeanUtil.copyProperties(projecDto,project, CopyOptions.create()
+ .setIgnoreError(Boolean.TRUE).setIgnoreNullValue(Boolean.TRUE));
+ project.setVersion(oldProject.getVersion() + 1);
+ project.setId(null);
+ project.setCreateOn(LocalDateTime.now());
+ project.setUpdateOn(LocalDateTime.now());
+ stateMachineUtils.pass(project);
+ projectService.save(project);
+
+ projectService.update(Wrappers.lambdaUpdate(Project.class)
+ .set(Project::getNewest,Boolean.FALSE)
+ .ne(Project::getId,project.getId())
+ .eq(Project::getProjectCode,project.getProjectCode()));
+
+ return project;
+ }
+
+ public Project saveProjectWithVersionAndStatus(ProjectDTO projecDto,Integer stageCode,Integer statusCode){
+ Project oldProject = projectService.getById(projecDto.getId());
+ Project project = new Project();
+ VUtils.isTrue(Objects.isNull(oldProject))
+ .throwMessage("项目不存在!");
+ BeanUtil.copyProperties(oldProject,project, CopyOptions.create()
+ .setIgnoreError(Boolean.TRUE).setIgnoreNullValue(Boolean.TRUE));
+ BeanUtil.copyProperties(projecDto,project, CopyOptions.create()
+ .setIgnoreError(Boolean.TRUE).setIgnoreNullValue(Boolean.TRUE));
+ project.setVersion(oldProject.getVersion() + 1);
+ project.setId(null);
+ project.setCreateOn(LocalDateTime.now());
+ project.setUpdateOn(LocalDateTime.now());
+ if(Objects.nonNull(stageCode)){
+ project.setStage(stageCode);
+ }
+ if(Objects.nonNull(statusCode)){
+ project.setStatus(statusCode);
+ }
+
+ if(projectService.save(project)){
+ projectService.update(Wrappers.lambdaUpdate(Project.class)
+ .set(Project::getNewest,Boolean.FALSE)
+ .ne(Project::getId,project.getId())
+ .eq(Project::getProjectCode,project.getProjectCode()));
+
+ //app
+ List applicationList = projecDto.getApplicationList();
+ if(CollUtil.isNotEmpty(applicationList)){
+ List apps = applicationList.stream()
+ .map(a -> {
+ ProjectApplication app = BeanUtil.copyProperties(a,ProjectApplication.class);
+ app.setId(null);
+ app.setProjectId(project.getId());
+ return app;
+ })
+ .collect(Collectors.toList());
+ projectApplicationService.saveBatch(apps);
+ }
+ }
+
+ return project;
+ }
+
+ /**
* @param projectId 项目详情
* @return com.ningdatech.pmapi.projectlib.model.entity.vo.ProjectDetailVO
* @author ZPF
@@ -199,6 +397,7 @@ public class ProjectLibManage {
param.setPageNumber(CommonConst.EXPORT_PAGE_NUMBER);
param.setPageSize(CommonConst.EXPORT_PAGE_SIZE);
LambdaQueryWrapper query = ProjectHelper.projectQuery(param);
+ query.eq(Project::getNewest,Boolean.TRUE);
List projects = projectService.list(query);
ExcelExportWriter excelExportWriter = new ExcelExportWriter();
@@ -271,4 +470,8 @@ public class ProjectLibManage {
}
return user;
}
+
+ private void copyProperties(ProjectDTO projecDto, Project project) {
+
+ }
}
diff --git a/pmapi/src/main/java/com/ningdatech/pmapi/projectlib/model/dto/AnnualLibExportDTO.java b/pmapi/src/main/java/com/ningdatech/pmapi/projectlib/model/dto/AnnualLibExportDTO.java
new file mode 100644
index 0000000..7635e3f
--- /dev/null
+++ b/pmapi/src/main/java/com/ningdatech/pmapi/projectlib/model/dto/AnnualLibExportDTO.java
@@ -0,0 +1,102 @@
+package com.ningdatech.pmapi.projectlib.model.dto;
+
+import java.math.BigDecimal;
+
+import javax.validation.constraints.NotBlank;
+import javax.validation.constraints.NotNull;
+
+import cn.afterturn.easypoi.excel.annotation.Excel;
+import lombok.Data;
+
+/**
+ *
+ * AnnualLibImportDTO
+ *
+ *
+ * @author WendyYang
+ * @since 13:46 2023/2/13
+ */
+@Data
+public class AnnualLibExportDTO {
+
+ @NotNull(message = "年度投资额不能为空")
+ @Excel(name = "年度投资额",groupName = "2023年计划")
+ private BigDecimal annualPlanAmount;
+
+ @NotNull(message = "自由资金不能为空")
+ @Excel(name = "自有资金",groupName = "资金来源")
+ private BigDecimal declareHaveAmount;
+ @Excel(name = "政府投资-本级财政资金")
+ @NotNull(message = "政府投资-本级财政不能为空")
+ private BigDecimal declareGovOwnFinanceAmount;
+ @Excel(name = "政府投资-上级补助资金")
+ @NotNull(message = "政府投资-上级补助资金不能为空")
+ private BigDecimal declareGovSuperiorFinanceAmount;
+ @Excel(name = "银行贷款")
+ @NotNull(message = "银行贷款不能为空")
+ private BigDecimal declareBankLendingAmount;
+ @Excel(name = "其他")
+ @NotNull(message = "其他不能为空")
+ private BigDecimal declareOtherAmount;
+
+ @Excel(name = "一季度",groupName = "进度和支付计划")
+ @NotBlank(message = "一季度不能为空")
+ private String firstQuarter;
+ @Excel(name = "二季度")
+ @NotBlank(message = "二季度不能为空")
+ private String secondQuarter;
+ @Excel(name = "三季度")
+ @NotBlank(message = "三季度不能为空")
+ private String thirdQuarter;
+ @Excel(name = "四季度")
+ @NotBlank(message = "四季度不能为空")
+ private String fourthQuarter;
+
+ @NotNull(message = "序号不能为空")
+ @Excel(name = "序号")
+ private Integer serialNumber;
+
+ @Excel(name = "项目id")
+ @NotNull(message = "项目ID不能为空")
+ private Long projectId;
+
+ @Excel(name = "项目名称")
+ @NotBlank(message = "项目名称不能为空")
+ private String projectName;
+
+ @NotBlank(message = "建设内容不能为空")
+ @Excel(name = "建设内容")
+ private String projectIntroduction;
+
+ @NotBlank(message = "建设依据不能为空")
+ @Excel(name = "建设依据")
+ private String buildBasis;
+
+ @Excel(name = "建设性质")
+ @NotBlank(message = "建设性质不能为空")
+ private String isFirst;
+
+ @Excel(name = "建设起止年限(填写到月)")
+ @NotBlank(message = "建设起止年限不能为空")
+ private String buildCycle;
+
+ @NotBlank(message = "总投资不能为空")
+ @Excel(name = "总投资")
+ private BigDecimal declaredAmount;
+
+ @Excel(name = "建设单位")
+ @NotBlank(message = "建设单位不能为空")
+ private String buildUnitName;
+
+ @Excel(name = "项目联系人")
+ @NotBlank(message = "项目联系人不能为空")
+ private String contactName;
+
+ @Excel(name = "项目分管领导")
+ @NotBlank(message = "项目分管领导不能为空")
+ private String responsibleMan;
+
+ @Excel(name = "备注")
+ private String projectRemarks;
+
+}
diff --git a/pmapi/src/main/java/com/ningdatech/pmapi/projectlib/model/dto/AnnualLibImportDTO.java b/pmapi/src/main/java/com/ningdatech/pmapi/projectlib/model/dto/AnnualLibImportDTO.java
index 69f35a2..4e2bf9c 100644
--- a/pmapi/src/main/java/com/ningdatech/pmapi/projectlib/model/dto/AnnualLibImportDTO.java
+++ b/pmapi/src/main/java/com/ningdatech/pmapi/projectlib/model/dto/AnnualLibImportDTO.java
@@ -1,5 +1,6 @@
package com.ningdatech.pmapi.projectlib.model.dto;
+import cn.afterturn.easypoi.excel.annotation.Excel;
import com.alibaba.excel.annotation.ExcelProperty;
import lombok.Data;
@@ -18,91 +19,104 @@ import java.math.BigDecimal;
@Data
public class AnnualLibImportDTO {
- @ExcelProperty("序号")
- @NotNull(message = "序号不能为空")
- private Integer serialNumber;
-
- @ExcelProperty("项目id")
- @NotNull(message = "项目ID不能为空")
- private Long projectId;
-
- @ExcelProperty("项目名称")
- @NotBlank(message = "项目名称不能为空")
- private String projectName;
-
- @NotBlank(message = "建设内容不能为空")
- @ExcelProperty("建设内容")
- private String projectIntroduction;
-
- @NotBlank(message = "建设依据不能为空")
- @ExcelProperty("建设依据")
- private String buildBasis;
-
- @ExcelProperty("建设性质")
- @NotBlank(message = "建设性质不能为空")
- private String isFirst;
-
- @ExcelProperty("建设起止年限")
- @NotBlank(message = "建设起止年限不能为空")
- private String buildCycle;
-
- @NotBlank(message = "总投资不能为空")
- @ExcelProperty("总投资")
- private BigDecimal declaredAmount;
+ @Excel(name = "项目进展",groupName = "到2022年底完成情况")
+ @NotNull(message = "项目进展不能为空")
+ private String projectProgress;
+ @Excel(name = "累计投资")
+ @NotNull(message = "累计投资不能为空")
+ private BigDecimal cumulativeInvest;
@NotNull(message = "年度投资额不能为空")
- @ExcelProperty("年度投资额")
+ @Excel(name = "年度投资额",groupName = "2023年计划")
private BigDecimal annualPlanAmount;
- @ExcelProperty("自有资金")
@NotNull(message = "自由资金不能为空")
+ @Excel(name = "自有资金",groupName = "资金来源")
private BigDecimal declareHaveAmount;
-
- @ExcelProperty("政府投资-本级财政")
+ @Excel(name = "政府投资-本级财政资金")
@NotNull(message = "政府投资-本级财政不能为空")
private BigDecimal declareGovOwnFinanceAmount;
-
- @ExcelProperty("政府投资-上级补助资金")
+ @Excel(name = "政府投资-上级补助资金")
@NotNull(message = "政府投资-上级补助资金不能为空")
private BigDecimal declareGovSuperiorFinanceAmount;
-
- @ExcelProperty("银行贷款")
+ @Excel(name = "银行贷款")
@NotNull(message = "银行贷款不能为空")
private BigDecimal declareBankLendingAmount;
-
- @ExcelProperty("其他")
+ @Excel(name = "国家、省补助",groupName = "资金来源")
+ @NotNull(message = "国家、省补助不能为空")
+ private BigDecimal govSuperiorFinanceAmount;
+ @Excel(name = "地方财政统筹")
+ @NotNull(message = "地方财政统筹不能为空")
+ private BigDecimal govOwnFinanceAmount;
+ @Excel(name = "建设单位自筹")
+ @NotNull(message = "建设单位自筹不能为空")
+ private BigDecimal haveAmount;
+ @Excel(name = "其他")
@NotNull(message = "其他不能为空")
private BigDecimal declareOtherAmount;
- @ExcelProperty("一季度")
+ @Excel(name = "一季度",groupName = "进度和支付计划")
@NotBlank(message = "一季度不能为空")
private String firstQuarter;
-
- @ExcelProperty("二季度")
+ @Excel(name = "二季度")
@NotBlank(message = "二季度不能为空")
private String secondQuarter;
-
- @ExcelProperty("三季度")
+ @Excel(name = "三季度")
@NotBlank(message = "三季度不能为空")
private String thirdQuarter;
-
- @ExcelProperty("四季度")
+ @Excel(name = "四季度")
@NotBlank(message = "四季度不能为空")
private String fourthQuarter;
- @ExcelProperty("建设单位")
+ @NotNull(message = "序号不能为空")
+ @Excel(name = "序号")
+ private Integer serialNumber;
+
+ @Excel(name = "项目id")
+ @NotNull(message = "项目ID不能为空")
+ private Long projectId;
+
+ @Excel(name = "项目名称")
+ @NotBlank(message = "项目名称不能为空")
+ private String projectName;
+
+ @NotBlank(message = "建设内容不能为空")
+ @Excel(name = "建设内容")
+ private String projectIntroduction;
+
+ @NotBlank(message = "建设依据不能为空")
+ @Excel(name = "建设依据")
+ private String buildBasis;
+
+ @Excel(name = "建设性质")
+ @NotBlank(message = "建设性质不能为空")
+ private String isFirst;
+
+ @Excel(name = "建设周期")
+ @NotBlank(message = "建设周期不能为空")
+ private String constructionCycle;
+
+ @Excel(name = "建设起止年限(填写到月)")
+ @NotBlank(message = "建设起止年限不能为空")
+ private String buildCycle;
+
+ @NotBlank(message = "总投资不能为空")
+ @Excel(name = "总投资")
+ private BigDecimal declaredAmount;
+
+ @Excel(name = "建设单位")
@NotBlank(message = "建设单位不能为空")
private String buildUnitName;
- @ExcelProperty("项目联系人")
+ @Excel(name = "项目联系人")
@NotBlank(message = "项目联系人不能为空")
private String contactName;
- @ExcelProperty("项目分管领导")
+ @Excel(name = "项目分管领导")
@NotBlank(message = "项目分管领导不能为空")
private String responsibleMan;
- @ExcelProperty("备注")
+ @Excel(name = "备注")
private String projectRemarks;
}
diff --git a/pmapi/src/main/java/com/ningdatech/pmapi/projectlib/model/dto/ProjectDTO.java b/pmapi/src/main/java/com/ningdatech/pmapi/projectlib/model/dto/ProjectDTO.java
index 31ddadf..3811a99 100644
--- a/pmapi/src/main/java/com/ningdatech/pmapi/projectlib/model/dto/ProjectDTO.java
+++ b/pmapi/src/main/java/com/ningdatech/pmapi/projectlib/model/dto/ProjectDTO.java
@@ -282,6 +282,9 @@ public class ProjectDTO implements Serializable {
@ApiModelProperty("项目发起人 员工code")
private String sponsor;
+ @ApiModelProperty("预审发起人 员工code")
+ private String preStartUserId;
+
@ApiModelProperty("上级条线单位审核意见")
private String higherLineSuperOrgReviewComments;
diff --git a/pmapi/src/main/java/com/ningdatech/pmapi/projectlib/model/entity/AnalysisEventMonitor.java b/pmapi/src/main/java/com/ningdatech/pmapi/projectlib/model/entity/AnalysisEventMonitor.java
new file mode 100644
index 0000000..41416a5
--- /dev/null
+++ b/pmapi/src/main/java/com/ningdatech/pmapi/projectlib/model/entity/AnalysisEventMonitor.java
@@ -0,0 +1,92 @@
+package com.ningdatech.pmapi.projectlib.model.entity;
+
+import com.alibaba.excel.context.AnalysisContext;
+import com.alibaba.excel.event.AnalysisEventListener;
+import com.baomidou.mybatisplus.core.toolkit.Wrappers;
+import com.ningdatech.basic.exception.BizException;
+import com.ningdatech.basic.util.CollUtils;
+import com.ningdatech.pmapi.common.constant.CommonConst;
+import com.ningdatech.pmapi.projectlib.service.IProjectService;
+import lombok.AllArgsConstructor;
+import lombok.Data;
+import lombok.NoArgsConstructor;
+import lombok.RequiredArgsConstructor;
+
+import java.util.*;
+
+/**
+ * @author CMM
+ * @since 2023/04/17 18:26
+ */
+@Data
+public class AnalysisEventMonitor extends AnalysisEventListener