package com.ningdatech.pmapi.projectdeclared.model.vo;

import com.baomidou.mybatisplus.annotation.*;
import com.fasterxml.jackson.annotation.JsonFormat;
import io.swagger.annotations.ApiModel;
import io.swagger.annotations.ApiModelProperty;
import lombok.Data;

import java.math.BigDecimal;
import java.time.LocalDate;
import java.time.LocalDateTime;
import java.util.List;

/**
 * @Classname Contract
 * @Description
 * @Date 2023/5/30 15:35
 * @Author PoffyZhang
 */
@Data
@ApiModel(value = "ContractVO", description = "")
public class ContractVO {

    private static final long serialVersionUID = 1L;

    @ApiModelProperty("主键")
    private Long id;

    @ApiModelProperty("创建人")
    @TableField(fill = FieldFill.INSERT)
    private String createBy;

    @ApiModelProperty("修改人人")
    @TableField(fill = FieldFill.INSERT_UPDATE)
    private String updateBy;

    @ApiModelProperty("创建时间")
    private LocalDateTime createOn;

    @ApiModelProperty("修改时间")
    private LocalDateTime updateOn;

    @ApiModelProperty("合同名称")
    private String name;

    @ApiModelProperty("合同总金额")
    private BigDecimal totalAmount;

    @ApiModelProperty("供应商开户行")
    private String supplierBank;

    @ApiModelProperty("供应商开户行帐号")
    private String supplierAccount;

    @ApiModelProperty("质保期 年")
    private Integer warrantyPeriod;

    @ApiModelProperty("质保金")
    private BigDecimal retentionMoney;

    @ApiModelProperty("合同完成时间")
    @JsonFormat(pattern = "yyyy-MM-dd")
    private LocalDateTime contractTime;

    @ApiModelProperty("交货日期")
    @JsonFormat(pattern = "yyyy-MM-dd")
    private LocalDateTime deliveryTime;

    @ApiModelProperty("附件")
    private String attachment;

    @ApiModelProperty("项目ID")
    private Long projectId;

    @ApiModelProperty("支付计划")
    private List<PaymentPlanVO> payments;
}
