package com.storlead.sales.pojo.vo.customer;

import com.alibaba.fastjson.annotation.JSONField;
import com.baomidou.mybatisplus.annotation.FieldFill;
import com.baomidou.mybatisplus.annotation.TableField;
import com.fasterxml.jackson.annotation.JsonFormat;
import com.storlead.framework.mybatis.entity.SysBaseField;
import io.swagger.annotations.ApiModelProperty;
import lombok.Data;
import lombok.EqualsAndHashCode;
import lombok.experimental.Accessors;
import org.springframework.format.annotation.DateTimeFormat;

import java.time.LocalDateTime;
import java.util.Date;

@Data
@EqualsAndHashCode(callSuper = false)
@Accessors(chain = true)
public class SimilarityErrorVO extends SysBaseField {
    //资源类型
    private Long errorId;
    private String resourceType;
    @ApiModelProperty(value = "客户Id")
    private Long customerId;

    private String errorMsg;
    private Boolean canSave = false;
    private Object object;
    @ApiModelProperty(value = "被查重复字段")
    private String duplicateFieldNow;
    @ApiModelProperty(value = "被查重复值")
    private String duplicateValueNow;

    @ApiModelProperty(value = "重复字段")
    private String duplicateField;
    @ApiModelProperty(value = "重复值")
    private String duplicateValue;

    @ApiModelProperty(value = "最后跟进时间")
    @JsonFormat(timezone = "GMT+8",pattern = "yyyy-MM-dd HH:mm:ss")
    @DateTimeFormat(pattern="yyyy-MM-dd HH:mm:ss")
    @JSONField(format ="yyyy-MM-dd HH:mm:ss")
    @TableField("last_follow_up_time")
    private LocalDateTime lastFollowUpTime;
    private Integer noFollowUpDate;

    @ApiModelProperty(value = "客户名称")
    private String customerName;
    @ApiModelProperty(value = "联系人姓名")
    private String name;

    @JsonFormat(timezone = "GMT+8",pattern = "yyyy-MM-dd HH:mm:ss")
    @DateTimeFormat(pattern="yyyy-MM-dd HH:mm:ss")
    @JSONField(format ="yyyy-MM-dd HH:mm:ss")
    @TableField(fill = FieldFill.INSERT)
    private Date createTime;

    private String ownerByName;
}
