package com.zcloud.modules.oa.entity;

import com.baomidou.mybatisplus.annotation.*;
import io.swagger.annotations.ApiModelProperty;
import lombok.Data;

import java.io.Serializable;

/**
 * (OaPost)表实体类
 *
 * @author fangjiakai
 * @since 2023-10-17 14:56:50
 */
@Data
@TableName("oa_post")
public class OaPostEntity implements Serializable,Comparable<OaPostEntity> {
    private static final long serialVersionUID = -21809569073205865L;
        //主键
    @TableId
    @ApiModelProperty(value = "主键")
    private String postId;
        //部门ID
    @ApiModelProperty(value = "部门ID")
    private String departmentId;
    //部门NAME
    @TableField(exist=false)
    @ApiModelProperty(value = "部门名称")
    private String departmentName;
    //所属企业
    @ApiModelProperty(value = "所属企业")
    private String corpinfoId;
        //名称
    @ApiModelProperty(value = "名称")
    private String name;
        //创建人
    @ApiModelProperty(value = "创建人")
    private String createor;
        //创建时间
    @ApiModelProperty(value = "创建时间")
    @TableField(fill = FieldFill.INSERT)
    private String createTime;
        //修改人
    @ApiModelProperty(value = "修改人")
    private String operator;
        //修改时间
    @ApiModelProperty(value = "修改时间")
    @TableField(fill = FieldFill.INSERT_UPDATE)
    private String operatTime;
        //排序
    @ApiModelProperty(value = "排序")
    private Integer orderBy;
        //是否删除
    @TableLogic
    @ApiModelProperty(value = "是否删除")
    @TableField(fill = FieldFill.INSERT)
    private Integer isDelete;

    @Override
    public int compareTo(OaPostEntity o) {
        return this.getOrderBy()-o.getOrderBy();
    }
}

