From fd60f7ce6025c761e2836ffcbbb70894aee946fa Mon Sep 17 00:00:00 2001
From: cuida <xiaocuijustsoso@163.com>
Date: 星期三, 29 四月 2026 16:32:21 +0800
Subject: [PATCH] feat:合同,合同标的物,收款实体

---
 platformx-business-finance-api/src/main/java/com/by4cloud/platformx/business/entity/Contract.java                  |  124 +++++++++++++
 platformx-business-finance-biz/src/main/resources/mapper/ContractMapper.xml                                        |    7 
 platformx-boot/src/main/resources/application-dev.yml                                                              |    1 
 platformx-business-finance-biz/src/main/java/com/by4cloud/platformx/business/service/impl/ContractServiceImpl.java |   17 +
 platformx-business-finance-biz/src/main/java/com/by4cloud/platformx/business/mapper/ContractMapper.java            |   12 +
 platformx-business-finance-api/src/main/java/com/by4cloud/platformx/business/entity/ContractSubjectMatter.java     |  141 +++++++++++++++
 platformx-business-finance-biz/src/main/java/com/by4cloud/platformx/business/controller/ContractController.java    |   24 ++
 platformx-business-finance-api/src/main/java/com/by4cloud/platformx/business/entity/ContractPaymentSchedule.java   |  165 ++++++++++++++++++
 platformx-business-finance-biz/src/main/java/com/by4cloud/platformx/business/service/ContractService.java          |   12 +
 9 files changed, 503 insertions(+), 0 deletions(-)

diff --git a/platformx-boot/src/main/resources/application-dev.yml b/platformx-boot/src/main/resources/application-dev.yml
index 650fa26..62f079a 100644
--- a/platformx-boot/src/main/resources/application-dev.yml
+++ b/platformx-boot/src/main/resources/application-dev.yml
@@ -2,6 +2,7 @@
   data:
     redis:
       host: 127.0.0.1
+      password: 123456
       database: 0
   # 鏁版嵁搴撶浉鍏抽厤缃�
   datasource:
diff --git a/platformx-business-finance-api/src/main/java/com/by4cloud/platformx/business/entity/Contract.java b/platformx-business-finance-api/src/main/java/com/by4cloud/platformx/business/entity/Contract.java
new file mode 100644
index 0000000..0b27ee2
--- /dev/null
+++ b/platformx-business-finance-api/src/main/java/com/by4cloud/platformx/business/entity/Contract.java
@@ -0,0 +1,124 @@
+package com.by4cloud.platformx.business.entity;
+
+import com.baomidou.mybatisplus.annotation.TableField;
+import com.by4cloud.platformx.common.data.mybatis.BaseModel;
+import io.swagger.v3.oas.annotations.media.Schema;
+import jakarta.persistence.Column;
+import jakarta.persistence.Entity;
+import lombok.Data;
+import org.hibernate.annotations.Table;
+
+import javax.persistence.Transient;
+import java.math.BigDecimal;
+
+import org.springframework.format.annotation.DateTimeFormat;
+import com.fasterxml.jackson.annotation.JsonFormat;
+
+/**
+ * @author cd
+ * @description
+ * @date 2026/4/29 10:51
+ **/
+@Data
+@Entity
+@Table(appliesTo = "contract", comment = "鍚堝悓绠$悊")
+public class Contract extends BaseModel<Contract> {
+
+
+    @Schema(description = "鍚堝悓缂栧彿")
+    @Column(columnDefinition = "VARCHAR(64) comment '鍚堝悓缂栧彿'")
+    private String contractNo;
+
+    @Schema(description = "鍚堝悓鍚嶇О")
+    @Column(columnDefinition = "VARCHAR(200) comment '鍚堝悓鍚嶇О'")
+    private String contractName;
+
+    @Schema(description = "鐢叉柟id")
+    @Column(columnDefinition = "bigint comment '鐢叉柟id'")
+    private Long partyAId;
+
+    @Schema(description = "鐢叉柟鍚嶇О")
+    @Column(columnDefinition = "VARCHAR(100) comment '鐢叉柟鍚嶇О'")
+    private String partyA;
+
+    @Schema(description = "涔欐柟id")
+    @Column(columnDefinition = "VARCHAR(100) comment '涔欐柟id'")
+    private String partyBId;
+
+    @Schema(description = "涔欐柟鍚嶇О")
+    @Column(columnDefinition = "VARCHAR(100) comment '涔欐柟鍚嶇О'")
+    private String partyB;
+
+    @Schema(description = "鍚堝悓閲戦")
+    @Column(columnDefinition = "double comment '鍚堝悓閲戦'")
+    private Double amount;
+
+    @Schema(description = "甯佺锛圕NY/USD绛夛級")
+    @Column(columnDefinition = "VARCHAR(10) default 'CNY' comment '甯佺'")
+    private String currency;
+
+    @Schema(description = "鍚堝悓绫诲瀷锛�0-鐢熸垚寮� 1-澶囨寮忥級")
+    @Column(columnDefinition = "tinyint(2) default 0 comment '鍚堝悓绫诲瀷'")
+    private Integer contractType;
+
+    @Schema(description = "鍚堝悓鐘舵�侊紙0-鑽夌 1-宸茬敓鏁� 2-宸茬粓姝� 3-宸茶繃鏈燂級")
+    @Column(columnDefinition = "tinyint(2) default 0 comment '鍚堝悓鐘舵��'")
+    private Integer contractStatus;
+
+    @Schema(description = "鍚堝悓鏈嶅姟灞炴�э紙0-浜у搧閿�鍞� 1-鏃犲舰鏈嶅姟锛�")
+    @Column(columnDefinition = "tinyint(2) default 0 comment '鍚堝悓鏈嶅姟灞炴��'")
+    private Integer contractAttribute;
+
+    @DateTimeFormat(pattern = "yyyy-MM-dd HH:mm")
+    @JsonFormat(pattern = "yyyy-MM-dd HH:mm")
+    @Schema(description = "绛剧讲鏃ユ湡")
+    @Column(columnDefinition = "VARCHAR(64) comment '绛剧讲鏃ユ湡'")
+    private String signDate;
+
+    @DateTimeFormat(pattern = "yyyy-MM-dd HH:mm")
+    @JsonFormat(pattern = "yyyy-MM-dd HH:mm")
+    @Schema(description = "鐢熸晥鏃ユ湡")
+    @Column(columnDefinition = "VARCHAR(64) comment '鐢熸晥鏃ユ湡'")
+    private String effectiveDate;
+
+    @DateTimeFormat(pattern = "yyyy-MM-dd HH:mm")
+    @JsonFormat(pattern = "yyyy-MM-dd HH:mm")
+    @Schema(description = "鍒版湡鏃ユ湡")
+    @Column(columnDefinition = "VARCHAR(64) comment '鍒版湡鏃ユ湡'")
+    private String expirationDate;
+
+    @Schema(description = "鍚堝悓闄勪欢URL")
+    @Column(columnDefinition = "VARCHAR(500) comment '鍚堝悓闄勪欢URL'")
+    private String attachmentUrl;
+
+    @Schema(description = "澶囨敞")
+    @Column(columnDefinition = "TEXT comment '澶囨敞'")
+    private String remark;
+
+    @Schema(description = "鍏宠仈鐖跺悎鍚宨d锛堢敤浜庡悎鍚屽彉鏇存椂鎸囧悜鍘熷悎鍚岋級")
+    @Column(columnDefinition = "bigint comment '鍏宠仈鐖跺悎鍚宨d'")
+    private Long parentId;
+
+
+    @DateTimeFormat(pattern = "yyyy-MM-dd HH:mm")
+    @JsonFormat(pattern = "yyyy-MM-dd HH:mm")
+    @Schema(description = "瀹℃壒鏃堕棿")
+    @Column(columnDefinition = "datetime comment '瀹℃壒鏃堕棿'")
+    private String approveTime;
+
+    /**
+     * 涓存椂瀛楁 - 鐢ㄤ簬鎺ユ敹瀹℃壒浜哄悕绉扮瓑鍏宠仈鏌ヨ缁撴灉
+     */
+    @Transient
+    @TableField(exist = false)
+    @Schema(description = "瀹℃壒浜哄鍚嶏紙涓存椂瀛楁锛�")
+    private String approverName;
+
+    /**
+     * 涓存椂瀛楁 - 鍚堝悓鍓╀綑澶╂暟
+     */
+    @Transient
+    @TableField(exist = false)
+    @Schema(description = "鍚堝悓鍓╀綑澶╂暟锛堜复鏃跺瓧娈碉級")
+    private Long remainingDays;
+}
diff --git a/platformx-business-finance-api/src/main/java/com/by4cloud/platformx/business/entity/ContractPaymentSchedule.java b/platformx-business-finance-api/src/main/java/com/by4cloud/platformx/business/entity/ContractPaymentSchedule.java
new file mode 100644
index 0000000..04ff428
--- /dev/null
+++ b/platformx-business-finance-api/src/main/java/com/by4cloud/platformx/business/entity/ContractPaymentSchedule.java
@@ -0,0 +1,165 @@
+package com.by4cloud.platformx.business.entity;
+
+import com.baomidou.mybatisplus.annotation.TableField;
+import com.by4cloud.platformx.common.data.mybatis.BaseModel;
+import com.fasterxml.jackson.annotation.JsonFormat;
+import io.swagger.v3.oas.annotations.media.Schema;
+import jakarta.persistence.Column;
+import jakarta.persistence.Entity;
+import jakarta.persistence.Transient;
+import lombok.Data;
+import org.hibernate.annotations.Table;
+import org.springframework.format.annotation.DateTimeFormat;
+
+import java.math.BigDecimal;
+import java.util.Date;
+
+/**
+ * 鍚堝悓鏀舵璁″垝/灞ョ害鑺傜偣瀹炰綋绫�
+ * 缁熶竴绠$悊鍚堝悓鐨勬敹娆鹃樁娈点�佸饱绾﹁妭鐐广�佹敹娆炬瘮渚嬪強灞ョ害鏃堕棿鑺傜偣
+ *
+ * @author xfei
+ * @date 2024-01-15
+ */
+@Data
+@Entity
+@Table(appliesTo = "contract_payment_schedule", comment = "鍚堝悓鏀舵璁″垝/灞ョ害鑺傜偣琛�")
+public class ContractPaymentSchedule extends BaseModel<ContractPaymentSchedule> {
+
+    // ==================== 鍏宠仈淇℃伅 ====================
+
+    @Schema(description = "鍏宠仈鍚堝悓ID")
+    @Column(columnDefinition = "bigint not null comment '鍏宠仈鍚堝悓ID'")
+    private Long contractId;
+
+    @Schema(description = "鍚堝悓鍚嶇О")
+    @Column(columnDefinition = "VARCHAR(64) comment '鍚堝悓鍚嶇О'")
+    private String contractName;
+
+    @Schema(description = "鍏宠仈鏍囩殑鐗㊣D锛堝彲閫夛紝濡傛灉涓虹┖鍒欓�傜敤浜庡悎鍚屾暣浣擄級")
+    @Column(columnDefinition = "bigint comment '鍏宠仈鏍囩殑鐗㊣D'")
+    private Long subjectMatterId;
+
+    @Schema(description = "鏍囩殑鐗╁悕绉�")
+    @Column(columnDefinition = "VARCHAR(64) comment '鏍囩殑鐗╁悕绉�'")
+    private String subjectMatterName;
+
+    // ==================== 鏀舵闃舵/灞ョ害鑺傜偣鍩烘湰淇℃伅 ====================
+
+//    @Schema(description = "鏀舵闃舵/鑺傜偣缂栫爜锛堝锛歋TAGE_001锛�")
+//    @Column(columnDefinition = "VARCHAR(64) comment '鏀舵闃舵/鑺傜偣缂栫爜'")
+//    private String stageCode;
+
+    @Schema(description = "鏀舵闃舵鍚嶇О锛堟樉鎬ц绱狅紝濡傦細鍚堝悓绛捐棰勪粯銆佸彂璐у墠浠樻銆佽揣鍒扮鏀朵粯娆俱�佽皟璇曞畬鎴愪粯娆俱�佽川淇濋噾锛�")
+    @Column(columnDefinition = "VARCHAR(100) not null comment '鏀舵闃舵鍚嶇О'")
+    private String stageName;
+
+//    @Schema(description = "鑺傜偣绫诲瀷锛�0-鏍囧噯棰勫畾涔夎妭鐐� 1-鑷畾涔夎妭鐐癸級")
+//    @Column(columnDefinition = "tinyint(1) default 0 comment '鑺傜偣绫诲瀷'")
+//    private Integer nodeType;
+
+//    @Schema(description = "灞ョ害鑺傜偣缂栫爜锛堜笌鏀舵闃舵鍏宠仈鐨勫饱绾﹁妭鐐癸紝濡傦細SIGN銆丳RE_DELIVERY銆丏ELIVERY_RECEIPT銆丆OMMISSIONING銆乄ARRANTY锛�")
+//    @Column(columnDefinition = "VARCHAR(50) comment '灞ョ害鑺傜偣缂栫爜'")
+//    private String fulfillmentNodeCode;
+
+//    @Schema(description = "灞ョ害鑺傜偣鍚嶇О")
+//    @Column(columnDefinition = "VARCHAR(100) comment '灞ョ害鑺傜偣鍚嶇О'")
+//    private String fulfillmentNodeName;
+
+    // ==================== 鏀舵姣斾緥/閲戦 ====================
+
+    @Schema(description = "鏀舵姣斾緥锛�%锛屽30琛ㄧず30%锛夛紙鏄炬�ц绱狅級")
+    @Column(columnDefinition = "double comment '鏀舵姣斾緥锛�%锛�'")
+    private Double paymentRatio;
+
+    @Schema(description = "璁″垝鏀舵閲戦锛堟牴鎹悎鍚屾�婚噾棰�*姣斾緥鑷姩璁$畻锛�")
+    @Column(columnDefinition = "double comment '璁″垝鏀舵閲戦'")
+    private Double plannedAmount;
+
+    @Schema(description = "瀹為檯鏀舵閲戦")
+    @Column(columnDefinition = "double default 0.00 comment '瀹為檯鏀舵閲戦'")
+    private Double actualAmount;
+
+    // ==================== 鏃跺簭鎺у埗 ====================
+
+    @Schema(description = "闃舵椤哄簭锛堢鍑犳湡锛�")
+    @Column(columnDefinition = "int not null comment '闃舵椤哄簭'")
+    private Integer stageOrder;
+
+    @Schema(description = "璁″垝鏀舵鏃ユ湡锛堝熀浜庡悎鍚岀璁㈡棩鏈�+绾﹀畾澶╂暟璁$畻锛�")
+    @DateTimeFormat(pattern = "yyyy-MM-dd HH:mm")
+    @JsonFormat(pattern = "yyyy-MM-dd HH:mm")
+    @Column(columnDefinition = "VARCHAR(64) comment '璁″垝鏀舵鏃ユ湡'")
+    private String plannedPaymentDate;
+
+    @Schema(description = "鏀舵闃舵鐢熸晥鏃ユ湡锛堥殣鎬ц绱� - 灞ョ害鏃堕棿璧风偣锛屽嵆璇ヨ妭鐐瑰疄闄呰揪鎴愮殑鏃ユ湡锛�")
+    @DateTimeFormat(pattern = "yyyy-MM-dd HH:mm")
+    @JsonFormat(pattern = "yyyy-MM-dd HH:mm")
+    @Column(columnDefinition = "VARCHAR(64) comment '鏀舵闃舵鐢熸晥鏃ユ湡锛堝饱绾﹁妭鐐瑰疄闄呰揪鎴愭棩鏈燂級'")
+    private String effectiveDate;
+
+    @Schema(description = "绾﹀畾澶╂暟锛堝悎鍚岀璁㈠悗X澶╁唴浠樻/璐у埌鍚嶺澶╁唴浠樻绛夛級")
+    @Column(columnDefinition = "int default 0 comment '绾﹀畾澶╂暟'")
+    private Integer agreedDays;
+
+    @Schema(description = "澶╂暟璁$畻鍩哄噯锛�0-鍚堝悓绛捐鏃� 1-涓婁竴鑺傜偣鐢熸晥鏃� 2-璐у埌鏃� 3-楠屾敹鏃ワ級")
+    @Column(columnDefinition = "tinyint(1) default 0 comment '澶╂暟璁$畻鍩哄噯'")
+    private Integer calculationBasis;
+
+    // ==================== 鐘舵�佹帶鍒� ====================
+
+    @Schema(description = "灞ョ害鑺傜偣鐘舵�侊紙0-鏈紑濮� 1-杩涜涓� 2-宸茶揪鎴� 3-宸查�炬湡锛�")
+    @Column(columnDefinition = "tinyint(1) default 0 comment '灞ョ害鑺傜偣鐘舵��'")
+    private Integer fulfillmentStatus;
+
+    @Schema(description = "鏀舵鐘舵�侊紙0-鏈敹娆� 1-閮ㄥ垎鏀舵 2-宸叉敹娆� 3-閫炬湡锛�")
+    @Column(columnDefinition = "tinyint(1) default 0 comment '鏀舵鐘舵��'")
+    private Integer paymentStatus;
+
+//    @Schema(description = "鏄惁鑷姩瑙﹀彂锛�0-鎵嬪姩褰曞叆鑺傜偣鏃堕棿 1-绯荤粺鑷姩鑾峰彇鑺傜偣鏃堕棿锛�")
+//    @Column(columnDefinition = "tinyint(1) default 0 comment '鏄惁鑷姩瑙﹀彂'")
+//    private Integer isAutoTrigger;
+
+    // ==================== 鍏宠仈鍗曟嵁锛堢敤浜庣郴缁熻嚜鍔ㄨ幏鍙栬妭鐐规椂闂达級 ====================
+
+//    @Schema(description = "鍏宠仈鍗曟嵁绫诲瀷锛�0-鏃� 1-璋冭瘯鍗� 2-楠屾敹鍗� 3-鍙戣揣鍗� 4-绛炬敹鍗曪級")
+//    @Column(columnDefinition = "tinyint(2) comment '鍏宠仈鍗曟嵁绫诲瀷'")
+//    private Integer relatedDocType;
+//
+//    @Schema(description = "鍏宠仈鍗曟嵁ID锛堝璋冭瘯鍗旾D銆侀獙鏀跺崟ID绛夛級")
+//    @Column(columnDefinition = "bigint comment '鍏宠仈鍗曟嵁ID'")
+//    private Long relatedDocId;
+//
+//    @Schema(description = "鍏宠仈鍗曟嵁缂栧彿")
+//    @Column(columnDefinition = "VARCHAR(64) comment '鍏宠仈鍗曟嵁缂栧彿'")
+//    private String relatedDocNo;
+
+    // ==================== 鍙戠エ鍏宠仈 ====================
+
+//    @Schema(description = "鍏宠仈鍙戠エID")
+//    @Column(columnDefinition = "bigint comment '鍏宠仈鍙戠エID'")
+//    private Long invoiceId;
+//
+//    @Schema(description = "鏄惁宸插紑绁紙0-鏈紑绁� 1-宸插紑绁級")
+//    @Column(columnDefinition = "tinyint(1) default 0 comment '鏄惁宸插紑绁�'")
+//    private Integer isInvoiced;
+
+    // ==================== 涓氬姟鎵╁睍 ====================
+
+    @Schema(description = "澶囨敞")
+    @Column(columnDefinition = "VARCHAR(500) comment '澶囨敞'")
+    private String remark;
+
+//    @Schema(description = "鎺掑簭鍙�")
+//    @Column(columnDefinition = "int default 0 comment '鎺掑簭鍙�'")
+//    private Integer sortOrder;
+
+    // ==================== 涓存椂瀛楁锛堢敤浜庢煡璇㈠睍绀猴級 ====================
+
+
+
+//    @Transient
+//    @TableField(exist = false)
+//    @Schema(description = "閫炬湡澶╂暟锛堜复鏃跺瓧娈碉級")
+//    private Long overdueDays;
+}
\ No newline at end of file
diff --git a/platformx-business-finance-api/src/main/java/com/by4cloud/platformx/business/entity/ContractSubjectMatter.java b/platformx-business-finance-api/src/main/java/com/by4cloud/platformx/business/entity/ContractSubjectMatter.java
new file mode 100644
index 0000000..a9ef21c
--- /dev/null
+++ b/platformx-business-finance-api/src/main/java/com/by4cloud/platformx/business/entity/ContractSubjectMatter.java
@@ -0,0 +1,141 @@
+package com.by4cloud.platformx.business.entity;
+
+import com.baomidou.mybatisplus.annotation.TableField;
+import com.by4cloud.platformx.common.data.mybatis.BaseModel;
+import com.fasterxml.jackson.annotation.JsonFormat;
+import io.swagger.v3.oas.annotations.media.Schema;
+import jakarta.persistence.Column;
+import jakarta.persistence.Entity;
+import jakarta.persistence.Transient;
+import lombok.Data;
+import org.hibernate.annotations.Table;
+import org.springframework.format.annotation.DateTimeFormat;
+
+import java.math.BigDecimal;
+import java.util.Date;
+
+/**
+ * 鍚堝悓鏍囩殑鐗╂槑缁嗗疄浣撶被
+ * @author xfei
+ * @date 2024-01-15
+ */
+@Data
+@Entity
+@Table(appliesTo = "contract_subject_matter", comment = "鍚堝悓鏍囩殑鐗╂槑缁嗚〃")
+public class ContractSubjectMatter extends BaseModel<ContractSubjectMatter> {
+
+    @Schema(description = "鍏宠仈鍚堝悓ID")
+    @Column(columnDefinition = "bigint comment '鍏宠仈鍚堝悓ID'")
+    private Long contractId;
+
+    @Schema(description = "鍚堝悓鍚嶇О")
+    @Column(columnDefinition = "VARCHAR(200) comment '鍚堝悓鍚嶇О'")
+    private String contractName;
+
+    @Schema(description = "鏍囩殑鐗╁悕绉�")
+    @Column(columnDefinition = "VARCHAR(200) comment '鏍囩殑鐗╁悕绉�'")
+    private String materialName;
+
+    @Schema(description = "鏍囩殑鐗╃紪鐮侊紙鍐呴儴鍞竴缂栫爜锛�")
+    @Column(columnDefinition = "VARCHAR(64) comment '鏍囩殑鐗╃紪鐮�'")
+    private String materialCode;
+
+    @Schema(description = "鏍囩殑鐗╃紪鐮侊紙鍐呴儴鍞竴鍚嶇О锛�")
+    @Column(columnDefinition = "VARCHAR(64) comment '鏍囩殑鐗╁悕绉�(鍐呴儴)'")
+    private String materialInternalName;
+
+    @Schema(description = "鏍囩殑鐗╄鏍�/鍨嬪彿")
+    @Column(columnDefinition = "VARCHAR(200) comment '鏍囩殑鐗╄鏍�/鍨嬪彿'")
+    private String specification;
+
+    @Schema(description = "鏍囩殑鐗╁搧鐗�")
+    @Column(columnDefinition = "VARCHAR(100) comment '鏍囩殑鐗╁搧鐗�'")
+    private String brand;
+
+    @Schema(description = "鏍囩殑鐗╁垎绫伙紙0-浜у搧 1-鏈嶅姟锛�")
+    @Column(columnDefinition = "tinyint(2) default 0 comment '鏍囩殑鐗╁垎绫�'")
+    private Integer category;
+
+    @Schema(description = "鏁伴噺")
+    @Column(columnDefinition = "double comment '鏁伴噺'")
+    private Double quantity;
+
+    @Schema(description = "璁¢噺鍗曚綅锛堜釜/鍙�/鍚�/椤�/濂楃瓑锛�")
+    @Column(columnDefinition = "VARCHAR(20) comment '璁¢噺鍗曚綅'")
+    private String unit;
+
+    @Schema(description = "鍗曚环")
+    @Column(columnDefinition = "double comment '鍗曚环'")
+    private Double unitPrice;
+
+    @Schema(description = "绋庣巼锛堢櫨鍒嗘瘮锛屽13琛ㄧず13%锛�")
+    @Column(columnDefinition = "double default 0.00 comment '绋庣巼'")
+    private Double taxRate;
+
+    @Schema(description = "绋庨")
+    @Column(columnDefinition = "double default 0.00 comment '绋庨'")
+    private Double taxAmount;
+
+    @Schema(description = "鍚◣鎬讳环")
+    @Column(columnDefinition = "double comment '鍚◣鎬讳环'")
+    private Double totalAmount;
+
+    @Schema(description = "涓嶅惈绋庢�讳环")
+    @Column(columnDefinition = "double comment '涓嶅惈绋庢�讳环'")
+    private Double totalAmountExcludingTax;
+
+    @Schema(description = "浜よ揣/浜や粯鍦扮偣")
+    @Column(columnDefinition = "VARCHAR(500) comment '浜よ揣/浜や粯鍦扮偣'")
+    private String deliveryPlace;
+
+    @DateTimeFormat(pattern = "yyyy-MM-dd HH:mm")
+    @JsonFormat(pattern = "yyyy-MM-dd HH:mm")
+    @Schema(description = "璁″垝浜や粯鏃ユ湡")
+    @Column(columnDefinition = "datetime comment '璁″垝浜や粯鏃ユ湡'")
+    private Date plannedDeliveryDate;
+
+    @DateTimeFormat(pattern = "yyyy-MM-dd HH:mm")
+    @JsonFormat(pattern = "yyyy-MM-dd HH:mm")
+    @Schema(description = "瀹為檯浜や粯鏃ユ湡")
+    @Column(columnDefinition = "datetime comment '瀹為檯浜や粯鏃ユ湡'")
+    private Date actualDeliveryDate;
+
+    @Schema(description = "浜や粯鐘舵�侊紙0-鏈氦浠� 1-閮ㄥ垎浜や粯 2-宸蹭氦浠� 3-閫炬湡锛�")
+    @Column(columnDefinition = "tinyint(2) default 0 comment '浜や粯鐘舵��'")
+    private Integer deliveryStatus;
+
+    @Schema(description = "璐ㄤ繚鏈燂紙鏈堬級")
+    @Column(columnDefinition = "int default 12 comment '璐ㄤ繚鏈燂紙鏈堬級'")
+    private Integer warrantyPeriod;
+
+    @Schema(description = "鏍囩殑鐗╂弿杩�/澶囨敞")
+    @Column(columnDefinition = "TEXT comment '鏍囩殑鐗╂弿杩�/澶囨敞'")
+    private String description;
+
+    @Schema(description = "闄勪欢URL锛堜骇鍝佽鏄庝功銆佹妧鏈枃妗g瓑锛�")
+    @Column(columnDefinition = "VARCHAR(500) comment '闄勪欢URL'")
+    private String attachmentUrl;
+
+    @Schema(description = "鎺掑簭鍙�")
+    @Column(columnDefinition = "int default 0 comment '鎺掑簭鍙�'")
+    private Integer sortOrder;
+
+    @Schema(description = "鏄惁楠屾敹閫氳繃锛�0-鏈獙鏀� 1-宸查獙鏀讹級")
+    @Column(columnDefinition = "tinyint(1) default 0 comment '鏄惁楠屾敹閫氳繃'")
+    private Integer isAccepted;
+
+    @DateTimeFormat(pattern = "yyyy-MM-dd HH:mm")
+    @JsonFormat(pattern = "yyyy-MM-dd HH:mm")
+    @Schema(description = "楠屾敹鏃堕棿")
+    @Column(columnDefinition = "datetime comment '楠屾敹鏃堕棿'")
+    private Date acceptTime;
+
+
+    /**
+     * 涓存椂瀛楁 - 宸蹭氦浠樻暟閲忥紙鐢ㄤ簬浜や粯杩涘害缁熻锛�
+     */
+    @Transient
+    @TableField(exist = false)
+    @Schema(description = "宸蹭氦浠樻暟閲忥紙涓存椂瀛楁锛�")
+    private BigDecimal deliveredQuantity;
+}
\ No newline at end of file
diff --git a/platformx-business-finance-biz/src/main/java/com/by4cloud/platformx/business/controller/ContractController.java b/platformx-business-finance-biz/src/main/java/com/by4cloud/platformx/business/controller/ContractController.java
new file mode 100644
index 0000000..dc4df91
--- /dev/null
+++ b/platformx-business-finance-biz/src/main/java/com/by4cloud/platformx/business/controller/ContractController.java
@@ -0,0 +1,24 @@
+package com.by4cloud.platformx.business.controller;
+
+import com.by4cloud.platformx.business.service.ContractService;
+import io.swagger.v3.oas.annotations.security.SecurityRequirement;
+import io.swagger.v3.oas.annotations.tags.Tag;
+import lombok.RequiredArgsConstructor;
+import org.springframework.http.HttpHeaders;
+import org.springframework.web.bind.annotation.RequestMapping;
+import org.springframework.web.bind.annotation.RestController;
+
+/**
+ * @author cd
+ * @description
+ * @date 2026/4/29 14:05
+ **/
+@RestController
+@RequiredArgsConstructor
+@RequestMapping("/contract" )
+@Tag(description = "contract" , name = "鍚堝悓琛ㄧ鐞�" )
+@SecurityRequirement(name = HttpHeaders.AUTHORIZATION)
+public class ContractController {
+
+    private final ContractService contractService;
+}
diff --git a/platformx-business-finance-biz/src/main/java/com/by4cloud/platformx/business/mapper/ContractMapper.java b/platformx-business-finance-biz/src/main/java/com/by4cloud/platformx/business/mapper/ContractMapper.java
new file mode 100644
index 0000000..8068932
--- /dev/null
+++ b/platformx-business-finance-biz/src/main/java/com/by4cloud/platformx/business/mapper/ContractMapper.java
@@ -0,0 +1,12 @@
+package com.by4cloud.platformx.business.mapper;
+
+import com.by4cloud.platformx.business.entity.Contract;
+import com.by4cloud.platformx.common.data.datascope.PlatformxBaseMapper;
+import org.apache.ibatis.annotations.Mapper;
+
+/**
+ * @author 28254
+ */
+@Mapper
+public interface ContractMapper extends PlatformxBaseMapper<Contract> {
+}
diff --git a/platformx-business-finance-biz/src/main/java/com/by4cloud/platformx/business/service/ContractService.java b/platformx-business-finance-biz/src/main/java/com/by4cloud/platformx/business/service/ContractService.java
new file mode 100644
index 0000000..44dda29
--- /dev/null
+++ b/platformx-business-finance-biz/src/main/java/com/by4cloud/platformx/business/service/ContractService.java
@@ -0,0 +1,12 @@
+package com.by4cloud.platformx.business.service;
+
+
+import com.by4cloud.platformx.business.entity.Contract;
+import com.by4cloud.platformx.common.data.mybatis.IIService;
+
+/**
+ * @author 28254
+ */
+public interface ContractService extends IIService<Contract> {
+
+}
diff --git a/platformx-business-finance-biz/src/main/java/com/by4cloud/platformx/business/service/impl/ContractServiceImpl.java b/platformx-business-finance-biz/src/main/java/com/by4cloud/platformx/business/service/impl/ContractServiceImpl.java
new file mode 100644
index 0000000..2997cf9
--- /dev/null
+++ b/platformx-business-finance-biz/src/main/java/com/by4cloud/platformx/business/service/impl/ContractServiceImpl.java
@@ -0,0 +1,17 @@
+package com.by4cloud.platformx.business.service.impl;
+
+import com.baomidou.mybatisplus.extension.service.impl.ServiceImpl;
+import com.by4cloud.platformx.business.entity.Contract;
+import com.by4cloud.platformx.business.mapper.ContractMapper;
+import com.by4cloud.platformx.business.service.ContractService;
+import org.springframework.stereotype.Service;
+
+/**
+ * @author cd
+ * @description
+ * @date 2026/4/29 14:07
+ **/
+@Service
+public class ContractServiceImpl extends ServiceImpl<ContractMapper, Contract> implements ContractService {
+
+}
diff --git a/platformx-business-finance-biz/src/main/resources/mapper/ContractMapper.xml b/platformx-business-finance-biz/src/main/resources/mapper/ContractMapper.xml
new file mode 100644
index 0000000..a251b1e
--- /dev/null
+++ b/platformx-business-finance-biz/src/main/resources/mapper/ContractMapper.xml
@@ -0,0 +1,7 @@
+<?xml version="1.0" encoding="UTF-8"?>
+
+<!DOCTYPE mapper PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN" "http://mybatis.org/dtd/mybatis-3-mapper.dtd">
+
+<mapper namespace="com.by4cloud.platformx.business.mapper.ContractMapper">
+
+</mapper>
\ No newline at end of file

--
Gitblit v1.9.1