package com.engine.organization.entity.hrmresource.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;

/**
 * @author:dxfeng
 * @createTime: 2022/06/21
 * @version: 1.0
 */
@Data
@Builder
@NoArgsConstructor
@AllArgsConstructor
@OrganizationTable(pageId = "c0583f20-f10c-11ec-9947-00e04c680716",
        fields = "t.id," +
                "t.last_name," +
                "t.department_id," +
                "t.company_id," +
                "t.mobile," +
                "t.telephone," +
                "t.manager_id, " +
                "t.show_order ",
        fromSql = "FROM jcl_org_hrmresource t ",
        orderby = " show_order ",
        sortway = " asc",
        primarykey = "id",
        operates = {
                @OrganizationTableOperate(index = "0", text = "发消息"),
                @OrganizationTableOperate(index = "1", text = "发送邮件"),
                @OrganizationTableOperate(index = "1", text = "发送短信"),
                @OrganizationTableOperate(index = "1", text = "新建日程"),
                @OrganizationTableOperate(index = "1", text = "系统信息"),
        },
        tableType = WeaTableType.CHECKBOX
)
public class HrmResourceVO {
    /**
     * 主键
     */
    @OrganizationTableColumn(column = "id", display = false)
    private Long id;

    /**
     * 姓名
     */
    @OrganizationTableColumn(text = "姓名", width = "25%", column = "last_name")
    private String lastName;
    /**
     * 部门
     */
    @OrganizationTableColumn(text = "部门", width = "25%", column = "department_id", transmethod = "com.engine.organization.transmethod.HrmResourceTransMethod.getDepartmentName")
    private String departmentName;

    /**
     * 分部
     */
    @OrganizationTableColumn(text = "分部", width = "25%", column = "company_id", transmethod = "com.engine.organization.transmethod.HrmResourceTransMethod.getCompanyName")
    private String companyName;

    /**
     * 移动电话
     */
    @OrganizationTableColumn(text = "移动电话", width = "25%", column = "mobile")
    private String mobile;
    /**
     * 办公室电话
     */
    @OrganizationTableColumn(text = "办公室电话", width = "25%", column = "telephone")
    private String telephone;
    /**
     * 直接上级
     */
    @OrganizationTableColumn(text = "直接上级", width = "25%", column = "manager_id", transmethod = "com.engine.organization.transmethod.HrmResourceTransMethod.getManagerName")
    private String managerName;

    @OrganizationTableColumn(text = "显示顺序", width = "25%", column = "show_order", orderkey = "show_order")
    private Integer showOrder;
}
