package com.qmth.sop.business.entity;

import com.fasterxml.jackson.databind.annotation.JsonSerialize;
import com.fasterxml.jackson.databind.ser.std.ToStringSerializer;
import com.qmth.sop.common.enums.DingObjTypeEnum;
import io.swagger.annotations.ApiModel;
import io.swagger.annotations.ApiModelProperty;

import javax.validation.constraints.NotBlank;
import javax.validation.constraints.NotNull;
import java.io.Serializable;

/**
 * <p>
 * 考勤组对象表
 * </p>
 *
 * @author wangliang
 * @since 2023-08-01
 */
@ApiModel(value = "SysDingObj对象", description = "考勤组对象表")
public class SysDingObj implements Serializable {

    private static final long serialVersionUID = 1L;

    @ApiModelProperty(value = "主键")
    @JsonSerialize(using = ToStringSerializer.class)
    private Long id;

    @ApiModelProperty(value = "考勤组id")
    @JsonSerialize(using = ToStringSerializer.class)
    @NotNull(message = "考勤组id不能为空")
    private Long dingGroupId;

    @ApiModelProperty(value = "角色id")
    @JsonSerialize(using = ToStringSerializer.class)
    @NotNull(message = "角色id不能为空")
    private Long roleId;

    @ApiModelProperty(value = "类型，DING：考勤，APPROVE：审核")
    @NotNull(message = "类型不能为空")
    private DingObjTypeEnum type;

    public Long getId() {
        return id;
    }

    public void setId(Long id) {
        this.id = id;
    }

    public Long getDingGroupId() {
        return dingGroupId;
    }

    public void setDingGroupId(Long dingGroupId) {
        this.dingGroupId = dingGroupId;
    }

    public Long getRoleId() {
        return roleId;
    }

    public void setRoleId(Long roleId) {
        this.roleId = roleId;
    }

    public DingObjTypeEnum getType() {
        return type;
    }

    public void setType(DingObjTypeEnum type) {
        this.type = type;
    }
}
