/*
|
* 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_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 = "`remarks`")
|
@ApiModelProperty(value = "备注信息")
|
private String remarks;
|
|
public void copy(Contract source){
|
BeanUtil.copyProperties(source,this, CopyOptions.create().setIgnoreNullValue(true));
|
}
|
}
|