/*
 * Author: wangjian
 * 生成entity
 */
package com.tofly.watermeter.entity;

import com.baomidou.mybatisplus.annotation.*;
import com.baomidou.mybatisplus.extension.activerecord.Model;
import com.fasterxml.jackson.annotation.JsonFormat;
import io.swagger.annotations.ApiModel;
import io.swagger.annotations.ApiModelProperty;
import lombok.Data;
import lombok.EqualsAndHashCode;
import org.springframework.format.annotation.DateTimeFormat;

import java.util.Date;


/**
 * 水量变更历史表
 *
 * @author wangjieliu
 * @date Mon Dec 20 00:00:00 CST 2021
 */
@Data
@EqualsAndHashCode(callSuper = true)
@TableName(value = "TF_YWPN_READUPDATE_W", resultMap = "readupdateMap")
@KeySequence("TF_YWPN_READUPDATE_W")
@ApiModel
public class Readupdate extends Model<Readupdate> {
    private static final long serialVersionUID = 1L;

    /**
     * 用户编号
     */
    @ApiModelProperty(value = "用户编号")
    private String yhbh;
    /**
     * 抄表月份
     */
    @ApiModelProperty(value = "抄表月份或财务月份")
    private String month;
    /**
     * 最新上次读数
     */
    @ApiModelProperty(value = "最新上次读数")
    private Long newScds;
    /**
     * 最新本次读数
     */
    @ApiModelProperty(value = "最新本次读数")
    private Long newBcds;
    /**
     * 最新抄表水量
     */
    @ApiModelProperty(value = "最新抄表水量")
    private Long newCbsl;
    /**
     * 旧的上次读数
     */
    @ApiModelProperty(value = "旧的上次读数")
    private Long oldScds;
    /**
     * 旧的本次读数
     */
    @ApiModelProperty(value = "旧的本次读数")
    private Long oldBcds;
    /**
     * 旧的抄表水量
     */
    @ApiModelProperty(value = "旧的抄表水量")
    private Long oldCbsl;
    /**
     * 创建时间
     */
    @ApiModelProperty(value = "创建时间")
    @JsonFormat(pattern = "yyyy-MM-dd HH:mm:ss", timezone = "GMT+8")
    @DateTimeFormat(pattern = "yyyy-MM-dd HH:mm:ss")
    @TableField(value = "CREATE_DATE", fill = FieldFill.INSERT)
    private Date createDate;
    /**
     * 创建人
     */
    @ApiModelProperty(value = "创建人")
    @TableField(value = "CREATE_USER", fill = FieldFill.INSERT)
    private Long createUser;
    @ApiModelProperty(hidden = true)
    private String createUserName;
    /**
     * $column.comments
     */
    @TableId(value = "ID", type = IdType.INPUT)
    @ApiModelProperty(value = "$column.comments")
    private Long id;
    /**
     * 用户姓名
     */
    @ApiModelProperty(value = "用户姓名")
    private String yhxm;
    /**
     * 用户地址
     */
    @ApiModelProperty(value = "用户地址")
    private String yhdz;
    /**
     * 联系电话
     */
    @ApiModelProperty(value = "联系电话")
    private String lxdh;

    /**
     * 来源类型0或null:APP,1:营销系统
     */
    @ApiModelProperty(value = "来源类型0或null:APP,1:营销系统")
    private String sourceType;

    /**
     * 变更原因
     */
    @ApiModelProperty(value = "变更原因")
    private String bgyy;

    /**
     * 变更原因
     */
    @JsonFormat(pattern = "yyyy-MM-dd HH:mm:ss", timezone = "GMT+8")
    @DateTimeFormat(pattern = "yyyy-MM-dd HH:mm:ss")
    @ApiModelProperty(value = "变更原因")
    private Date bgrq;

    @ApiModelProperty(value = "修改备注")
    private String updateBz;

    @ApiModelProperty(value = "是否卡表；0：机械表；1：卡表")
    private String isGeneral;

    @ApiModelProperty(value = "抄表的唯一标识")
    private String soleSign;

    @ApiModelProperty(value = "旧总购量；主要用于卡表抄表修改")
    private Long oldZgl;

    @ApiModelProperty(value = "旧差值，总购量与本次读数的差值；主要用于卡表抄表修改")
    private Long oldDiffValue;

    @ApiModelProperty(value = "新总购量；主要用于卡表抄表修改")
    private Long newZgl;

    @ApiModelProperty(value = "新差值，总购量与本次读数的差值；主要用于卡表抄表修改")
    private Long newDiffValue;
}
