package com.chinaweal.aiccs.aiccs.revoke.entity;

import com.baomidou.mybatisplus.annotation.TableField;
import com.baomidou.mybatisplus.annotation.TableId;
import com.baomidou.mybatisplus.annotation.TableName;
import com.baomidou.mybatisplus.extension.activerecord.Model;
import com.chinaweal.aiccs.common.util.DateUtils;
import com.fasterxml.jackson.annotation.JsonFormat;
import io.swagger.annotations.ApiModel;
import io.swagger.annotations.ApiModelProperty;
import lombok.Data;
import lombok.EqualsAndHashCode;
import lombok.experimental.Accessors;

import java.io.Serializable;
import java.time.LocalDate;
import java.time.LocalDateTime;

/**
 * <p>
 * 个体吊销信息表
 * </p>
 *
 * @author system
 * @since 2026-03-27
 */
@Data
@EqualsAndHashCode(callSuper = false)
@Accessors(chain = true)
@TableName("E_GT_REVOKE")
@ApiModel(value = "EGtRevoke", description = "个体吊销信息表")
public class EGtRevoke extends Model<EGtRevoke> {

    private static final long serialVersionUID = 1L;

    /**
     * 主体身份代码
     */
    @TableId(value = "PRIPID")
    @ApiModelProperty(value = "主体身份代码")
    private String pripid;

    /**
     * 吊销原因
     */
    @TableField("REVREA")
    @ApiModelProperty(value = "吊销原因")
    private String revrea;

    /**
     * 吊销日期
     */
    @TableField("REVDATE")
    @JsonFormat(pattern = DateUtils.DATE_DEFAULT_FORMAT, timezone = "GMT+8")
    @ApiModelProperty(value = "吊销日期")
    private LocalDate revdate;

    /**
     * 数据汇总单位
     */
    @TableField("S_EXT_FROMNODE")
    @ApiModelProperty(value = "数据汇总单位")
    private String sExtFromnode;

    /**
     * 数据汇总时间
     */
    @TableField("S_EXT_DATATIME")
    @JsonFormat(pattern = DateUtils.DATETIME_DEFAULT_FORMAT, timezone = "GMT+8")
    @ApiModelProperty(value = "数据汇总时间")
    private LocalDateTime sExtDatatime;

    @Override
    protected Serializable pkVal() {
        return this.pripid;
    }
}
