From d08fd7c3f0d3b11c19314b8f9677ee8626d50a49 Mon Sep 17 00:00:00 2001
From: xiangpei <xiangpei@timesnew.cn>
Date: 星期六, 22 二月 2025 21:08:57 +0800
Subject: [PATCH] 项目投资及资金来源增设:地方政府专项债券、超长期特别国债

---
 business/src/main/java/com/ycl/domain/form/ProjectInvestmentFundingForm.java |   19 ++++++---
 business/src/main/resources/mapper/ProjectInfoMapper.xml                     |    3 +
 business/src/main/java/com/ycl/domain/entity/ProjectInvestmentFunding.java   |    8 ++++
 business/src/main/java/com/ycl/domain/excel/ProjectExcelTemplate.java        |   10 +++++
 business/src/main/java/com/ycl/service/impl/ProjectInfoServiceImpl.java      |    9 ++--
 business/src/main/resources/mapper/ProjectInvestmentFundingMapper.xml        |    6 +++
 business/src/main/java/com/ycl/domain/vo/ProjectInvestmentFundingVO.java     |    6 +++
 7 files changed, 49 insertions(+), 12 deletions(-)

diff --git a/business/src/main/java/com/ycl/domain/entity/ProjectInvestmentFunding.java b/business/src/main/java/com/ycl/domain/entity/ProjectInvestmentFunding.java
index 93486e7..5244337 100644
--- a/business/src/main/java/com/ycl/domain/entity/ProjectInvestmentFunding.java
+++ b/business/src/main/java/com/ycl/domain/entity/ProjectInvestmentFunding.java
@@ -23,6 +23,14 @@
     /** 椤圭洰id */
     private Long projectId;
 
+    @TableField("dept_bond")
+    /** 鍦版柟鏀垮簻涓撻」鍊哄埜 */
+    private String deptBond;
+
+    @TableField("national_debt")
+    /** 瓒呴暱鏈熺壒鍒浗鍊� */
+    private String nationalDebt;
+
     @TableField("total_investment")
     /** 椤圭洰鎬绘姇璧勯 */
     private String totalInvestment;
diff --git a/business/src/main/java/com/ycl/domain/excel/ProjectExcelTemplate.java b/business/src/main/java/com/ycl/domain/excel/ProjectExcelTemplate.java
index 741d6f6..13146c7 100644
--- a/business/src/main/java/com/ycl/domain/excel/ProjectExcelTemplate.java
+++ b/business/src/main/java/com/ycl/domain/excel/ProjectExcelTemplate.java
@@ -203,6 +203,10 @@
     @ExcelProperty(value = "寤鸿鎬ц川")
     private String constructionNature;
 
+    @ExcelProperty(value = "鏄惁鎷涘晢寮曡祫椤圭洰")
+    /** 鏄惁鎷涘晢寮曡祫椤圭洰锛�0 涓嶆槸  1 鏄� */
+    private String attractInvestment;
+
     /**
      * 鑱旂郴鏂瑰紡
      */
@@ -342,6 +346,12 @@
     @ExcelProperty(value = "椤圭洰鎬绘姇璧勯")
     private String totalInvestment;
 
+    @ExcelProperty(value = "鍦版柟鏀垮簻涓撻」鍊哄埜")
+    private String deptBond;
+
+    @ExcelProperty(value = "瓒呴暱鏈熺壒鍒浗鍊�")
+    private String nationalDebt;
+
     /**
      * 椤圭洰鏈噾
      */
diff --git a/business/src/main/java/com/ycl/domain/form/ProjectInvestmentFundingForm.java b/business/src/main/java/com/ycl/domain/form/ProjectInvestmentFundingForm.java
index d565403..aff965e 100644
--- a/business/src/main/java/com/ycl/domain/form/ProjectInvestmentFundingForm.java
+++ b/business/src/main/java/com/ycl/domain/form/ProjectInvestmentFundingForm.java
@@ -1,17 +1,16 @@
 package com.ycl.domain.form;
 
-import com.ycl.common.group.Update;
 import com.ycl.common.group.Add;
-import com.ycl.system.domain.base.AbsForm;
+import com.ycl.common.group.Update;
 import com.ycl.domain.entity.ProjectInvestmentFunding;
-import org.springframework.beans.BeanUtils;
-import javax.validation.constraints.NotBlank;
-import javax.validation.constraints.NotNull;
-import org.springframework.lang.NonNull;
+import com.ycl.system.domain.base.AbsForm;
 import io.swagger.annotations.ApiModel;
 import io.swagger.annotations.ApiModelProperty;
 import lombok.Data;
-import java.util.Date;
+import org.springframework.beans.BeanUtils;
+import org.springframework.lang.NonNull;
+
+import javax.validation.constraints.NotNull;
 
 /**
  * 椤圭洰鎶曡祫鍙婅祫閲戞潵婧愭儏鍐佃〃琛ㄥ崟
@@ -26,6 +25,12 @@
     @ApiModelProperty("椤圭洰id")
     private Long projectId;
 
+    @ApiModelProperty("鍦版柟鏀垮簻涓撻」鍊哄埜")
+    private String deptBond;
+
+    @ApiModelProperty("瓒呴暱鏈熺壒鍒浗鍊�")
+    private String nationalDebt;
+
     @ApiModelProperty("椤圭洰鎬绘姇璧勯")
     private String totalInvestment;
 
diff --git a/business/src/main/java/com/ycl/domain/vo/ProjectInvestmentFundingVO.java b/business/src/main/java/com/ycl/domain/vo/ProjectInvestmentFundingVO.java
index 55cfaec..fa229ab 100644
--- a/business/src/main/java/com/ycl/domain/vo/ProjectInvestmentFundingVO.java
+++ b/business/src/main/java/com/ycl/domain/vo/ProjectInvestmentFundingVO.java
@@ -24,6 +24,12 @@
     @ApiModelProperty("椤圭洰id")
     private Long projectId;
 
+    @ApiModelProperty("鍦版柟鏀垮簻涓撻」鍊哄埜")
+    private String deptBond;
+
+    @ApiModelProperty("瓒呴暱鏈熺壒鍒浗鍊�")
+    private String nationalDebt;
+
     /** 椤圭洰鎬绘姇璧勯 */
     @ApiModelProperty("椤圭洰鎬绘姇璧勯")
     private String totalInvestment;
diff --git a/business/src/main/java/com/ycl/service/impl/ProjectInfoServiceImpl.java b/business/src/main/java/com/ycl/service/impl/ProjectInfoServiceImpl.java
index 7f9ff2e..9e6ed0b 100644
--- a/business/src/main/java/com/ycl/service/impl/ProjectInfoServiceImpl.java
+++ b/business/src/main/java/com/ycl/service/impl/ProjectInfoServiceImpl.java
@@ -117,7 +117,7 @@
             entity.setUsedStatus(ProjectConstant.PASS);
         }
         if(!checkProjectNameAndIdIsUnique(entity,null)){
-            return Result.error("椤圭洰閲嶅锛岄」鐩悕绉般�侀」鐩爜宸插瓨鍦�");
+            throw new RuntimeException("椤圭洰閲嶅锛岄」鐩悕绉般�侀」鐩爜宸插瓨鍦�");
         }
         baseMapper.insert(entity);
         addPlan(entity.getId()); //娣诲姞璁″垝琛�
@@ -194,7 +194,7 @@
             entity.setUsedStatus(ProjectConstant.PASS);
         }
         if(!checkProjectNameAndIdIsUnique(entity,form.getId())){
-            return Result.error("椤圭洰閲嶅锛岄」鐩悕绉般�侀」鐩爜宸插瓨鍦�");
+            throw new RuntimeException("椤圭洰閲嶅锛岄」鐩悕绉般�侀」鐩爜宸插瓨鍦�");
         }
         //鏇存柊椤圭洰淇℃伅
         baseMapper.updateById(entity);
@@ -811,11 +811,10 @@
 
             if (ObjectUtil.isNull(form.getProjectInfoForm().getId())) {
                 //鏂板
-                return ((ProjectInfoServiceImpl) AopContext.currentProxy()).add(form.getProjectInfoForm());
-
+                ((ProjectInfoServiceImpl) AopContext.currentProxy()).add(form.getProjectInfoForm());
             } else {
                 //鏇存柊
-                return ((ProjectInfoServiceImpl) AopContext.currentProxy()).update(form.getProjectInfoForm());
+                ((ProjectInfoServiceImpl) AopContext.currentProxy()).update(form.getProjectInfoForm());
             }
         }
         if (ObjectUtil.isNotNull(form.getProjectInvestmentInfoForm())) {
diff --git a/business/src/main/resources/mapper/ProjectInfoMapper.xml b/business/src/main/resources/mapper/ProjectInfoMapper.xml
index 2400833..c6db4ae 100644
--- a/business/src/main/resources/mapper/ProjectInfoMapper.xml
+++ b/business/src/main/resources/mapper/ProjectInfoMapper.xml
@@ -74,6 +74,7 @@
             TPIF.county_fiscal_investment as TPIF_county_fiscal_investment,TPIF.county_special_fund_investment as TPIF_county_special_fund_investment,
             TPIF.domestic_loan_total as TPIF_domestic_loan_total,TPIF.bank_loan as TPIF_bank_loan,TPIF.foreign_investment_total as TPIF_foreign_investment_total,
             TPIF.enterprise_self_raised_total as TPIF_enterprise_self_raised_total,TPIF.other_investment_total as TPIF_other_investment_total,
+            TPIF.dept_bond as TPIF_dept_bond,TPIF.national_debt as TPID_national_debt,
             TPII.be_cross_region as TPII_be_cross_region,TPII.construction_location as TPII_construction_location,
             TPII.detailed_address as TPII_detailed_address,TPII.be_compensation_project as TPII_be_compensation_project,TPII.compensation_reason as TPII_compensation_reason,
             TPII.planned_start_date as TPII_planned_start_date,TPII.expected_completion_date as TPII_expected_completion_date,
@@ -205,6 +206,8 @@
         TPIF.county_investment_total,TPIF.county_budget_investment,TPIF.county_fiscal_investment,
         TPIF.county_special_fund_investment,TPIF.domestic_loan_total,TPIF.bank_loan,TPIF.foreign_investment_total,TPIF.enterprise_self_raised_total,TPIF.other_investment_total,TPIF.gmt_create,
         TPIF.create_by,TPIF.gmt_update,TPIF.update_by,
+        TPIF.dept_bond,
+        TPIF.national_debt,
         TPII.id,TPII.project_id,TPII.be_cross_region,TPII.construction_location,TPII.detailed_address,TPII.be_compensation_project,TPII.compensation_reason,TPII.planned_start_date,
         TPII.expected_completion_date,TPII.national_industry_classification,TPII.industry_classification,TPII.project_nature,TPII.project_attribute,
         TPII.use_earth,TPII.content_scale,TPII.code,TPII.gmt_create,TPII.create_by,TPII.gmt_update, TPII.update_by,
diff --git a/business/src/main/resources/mapper/ProjectInvestmentFundingMapper.xml b/business/src/main/resources/mapper/ProjectInvestmentFundingMapper.xml
index c894c7c..3ccb767 100644
--- a/business/src/main/resources/mapper/ProjectInvestmentFundingMapper.xml
+++ b/business/src/main/resources/mapper/ProjectInvestmentFundingMapper.xml
@@ -7,6 +7,8 @@
         <result column="project_id" property="projectId" />
         <result column="total_investment" property="totalInvestment" />
         <result column="principal" property="principal" />
+        <result column="dept_bond" property="deptBond" />
+        <result column="national_debt" property="nationalDebt" />
         <result column="government_investment_total" property="governmentInvestmentTotal" />
         <result column="central_investment_total" property="centralInvestmentTotal" />
         <result column="central_budget_investment" property="centralBudgetInvestment" />
@@ -45,6 +47,8 @@
     <select id="getById" resultMap="BaseResultMap">
         SELECT
             TPIF.project_id,
+            TPIF.dept_bond,
+            TPIF.national_debt,
             TPIF.total_investment,
             TPIF.principal,
             TPIF.government_investment_total,
@@ -85,6 +89,8 @@
     <select id="getPage" resultMap="BaseResultMap">
         SELECT
             TPIF.project_id,
+            TPIF.dept_bond,
+            TPIF.national_debt,
             TPIF.total_investment,
             TPIF.principal,
             TPIF.government_investment_total,

--
Gitblit v1.8.0