baolhyhzhg
2024-12-02 bd0c44077bb6e84f2750f65786a587375339f0bc
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
132
133
134
135
136
137
138
139
140
141
142
143
144
145
146
/*
*  Copyright 2019-2020 Zheng Jie
*
*  Licensed under the Apache License, Version 2.0 (the "License");
*  you may not use this file except in compliance with the License.
*  You may obtain a copy of the License at
*
*  http://www.apache.org/licenses/LICENSE-2.0
*
*  Unless required by applicable law or agreed to in writing, software
*  distributed under the License is distributed on an "AS IS" BASIS,
*  WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
*  See the License for the specific language governing permissions and
*  limitations under the License.
*/
package me.zhengjie.modules.contract.domain;
 
import lombok.Data;
import cn.hutool.core.bean.BeanUtil;
import io.swagger.annotations.ApiModelProperty;
import cn.hutool.core.bean.copier.CopyOptions;
import me.zhengjie.base.BaseEntity;
 
import javax.persistence.*;
import javax.validation.constraints.*;
import java.sql.Timestamp;
import java.math.BigDecimal;
import java.io.Serializable;
 
/**
* @website https://eladmin.vip
* @description /
* @author 赵士淞
* @date 2023-02-02
**/
@Entity
@Data
@Table(name="contract")
public class Contract extends BaseEntity implements Serializable {
 
    @Id
    @GeneratedValue(strategy = GenerationType.IDENTITY)
    @Column(name = "`contract_id`")
    @ApiModelProperty(value = "ID")
    private Long contractId;
 
    @Column(name = "`contract_number`")
    @ApiModelProperty(value = "合同编号")
    private String contractNumber;
 
    @Column(name = "`contract_name`")
    @ApiModelProperty(value = "合同名称")
    private String contractName;
 
    @Column(name = "`first_id`")
    @ApiModelProperty(value = "甲方信息ID")
    private Long firstId;
 
    @Column(name = "`second_id`")
    @ApiModelProperty(value = "乙方信息ID")
    private Long secondId;
 
    @Column(name = "`sign_date`")
    @ApiModelProperty(value = "签订日期")
    private Timestamp signDate;
 
    @Column(name = "`start_date`")
    @ApiModelProperty(value = "起始日期")
    private Timestamp startDate;
 
    @Column(name = "`end_date`")
    @ApiModelProperty(value = "截止日期")
    private Timestamp endDate;
 
    @Column(name = "`contract_area_code`")
    @ApiModelProperty(value = "合同所属地区编码")
    private String contractAreaCode;
 
    @Column(name = "`contract_area`")
    @ApiModelProperty(value = "合同所属地区")
    private String contractArea;
 
    @Column(name = "`contract_type`")
    @ApiModelProperty(value = "合同类型(一级)")
    private String contractType;
 
    @Column(name = "`contract_second_type`")
    @ApiModelProperty(value = "合同类型(二级)")
    private String contractSecondType;
 
    @Column(name = "`contract_content`")
    @ApiModelProperty(value = "合同内容")
    private String contractContent;
 
    @Column(name = "`contract_amount`")
    @ApiModelProperty(value = "合同费金额")
    private BigDecimal contractAmount;
 
    @Column(name = "`contract_payment_date`")
    @ApiModelProperty(value = "预计付款日期")
    private Timestamp contractPaymentDate;
 
    @Column(name = "`contract_payment_state`")
    @ApiModelProperty(value = "付款状态")
    private String contractPaymentState;
 
    @Column(name = "`service_starts_date`")
    @ApiModelProperty(value = "服务开始日期")
    private Timestamp serviceStartsDate;
 
    @Column(name = "`service_amount`")
    @ApiModelProperty(value = "服务费金额")
    private BigDecimal serviceAmount;
 
    @Column(name = "`service_payment_date`")
    @ApiModelProperty(value = "预计付款日期")
    private Timestamp servicePaymentDate;
 
    @Column(name = "`service_payment_state`")
    @ApiModelProperty(value = "付款状态")
    private String servicePaymentState;
 
    @Column(name = "`related_documents_first`")
    @ApiModelProperty(value = "合同初版文件")
    private String relatedDocumentsFirst;
 
    @Column(name = "`related_documents_final`")
    @ApiModelProperty(value = "合同终版文件")
    private String relatedDocumentsFinal;
 
    @Column(name = "`contract_status`")
    @ApiModelProperty(value = "合同状态")
    private String contractStatus;
 
    @Column(name = "`accept_status`")
    @ApiModelProperty(value = "验收状态")
    private String acceptStatus;
 
    @Column(name = "`remarks`")
    @ApiModelProperty(value = "备注信息")
    private String remarks;
 
    public void copy(Contract source){
        BeanUtil.copyProperties(source,this, CopyOptions.create().setIgnoreNullValue(true));
    }
}