package com.yh.saas.plugin.news.entity;

import com.baomidou.mybatisplus.annotations.TableId;
import com.baomidou.mybatisplus.annotations.TableName;
import com.baomidou.mybatisplus.enums.IdType;
import com.yh.saas.common.support.entity.BaseModel;
import com.yh.saas.common.support.util.query.SearchField;
import com.yh.saas.common.support.util.query.SearchMode;
import lombok.Data;
import lombok.EqualsAndHashCode;

import java.io.Serializable;

/**
 * <p>
 * 公告分类 - 实体类
 * </p>
 *
 * @Auther ZhangMingYu
 * @since 2019年8月13日13:34:16
 */
@Data
@EqualsAndHashCode(callSuper = true)
@TableName("news_announcement_type_info")
public class AnnoTypeInfo extends BaseModel<AnnoTypeInfo> {

    //主键ID
    @TableId(type = IdType.INPUT)
    private String id;

    //公司ID
    @SearchField(value = "comp_id", mode = SearchMode.EQ)
    private String compId;

    //类型名称
    @SearchField(value = "type_name", mode = SearchMode.EQ)
    private String typeName;

    //顺序
    private Integer serialNumber;


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

    public static class QueryFiles {

        public static final String COMP_ID = "comp_id";

    }

    public static class OrderFiles {

        public static final String SERIAL_NUMBER = "serial_number";

        public static final String TYPE_NAME = "type_name";
    }
}
