package com.engine.organization.entity.scheme.vo;

import com.cloudstore.eccom.pc.table.WeaTableType;
import com.engine.organization.annotation.*;
import lombok.AllArgsConstructor;
import lombok.Builder;
import lombok.Data;
import lombok.NoArgsConstructor;


@Data
@Builder
@NoArgsConstructor
@AllArgsConstructor
@OrganizationTable(pageId = "3a0b752e-d028-11ec-91fc-00ffcbed7508",
        fields = "t.id," +
                "t.level_no," +
                "t.level_name," +
                "t.description," +
                "s.scheme_name," +
                "t.scheme_id," +
                "t.forbidden_tag," +
                "t.is_used," +
                "t.creator," +
                "t.delete_type," +
                "t.create_time," +
                "t.update_time",
        fromSql = "FROM jcl_org_level t inner join jcl_org_scheme s on t.scheme_id = s.id ",
        orderby = "level_no",
        sortway = "asc",
        primarykey = "id",
        operates = {
                @OrganizationTableOperate(text = "编辑"),
                @OrganizationTableOperate(index = "1", text = "删除")
        }, tableType = WeaTableType.CHECKBOX,
        operatePopedom = @OperatePopedom(transmethod = "com.engine.organization.util.ConfigTrans.formatSourceOperates", otherpara = "column:is_used"),
        checkboxPopedom = @CheckboxPopedom(showmethod = "com.engine.organization.util.ConfigTrans.getCheckBoxPopedom", popedompara = "column:is_used")
)
public class LevelTableVO {
    /**
     * 主键
     */
    @OrganizationTableColumn(column = "id", display = false)
    private Long id;
    /**
     * 是否被引用
     */
    @OrganizationTableColumn(column = "isUsed", display = false)
    private Integer isUsed;

    /**
     * 编号
     */
    @OrganizationTableColumn(text = "编号", width = "20%", column = "level_no", orderkey = "level_no")
    private String levelNo;
    /**
     * 名称
     */
    @OrganizationTableColumn(text = "名称", width = "20%", column = "level_name")
    private String levelName;

    /**
     * 等级方案
     */
    @OrganizationTableColumn(text = "等级方案", width = "20%", column = "scheme_name")
    private String schemeName;

    /**
     * 描述说明
     */
    @OrganizationTableColumn(text = "描述说明", width = "30%", column = "description")
    private String description;


    /**
     * 禁用标记
     */
    @OrganizationTableColumn(text = "是否启用", width = "10%", column = "forbidden_tag")
    private Integer forbiddenTag;
}
