| package com.zt.modules.sys.model; | 
|   | 
| import com.baomidou.mybatisplus.annotation.TableField; | 
| import com.baomidou.mybatisplus.annotation.TableName; | 
| import com.zt.common.entity.CompanyEntity; | 
| import com.zt.common.entity.TreeNode; | 
| import com.zt.common.validator.group.DefaultGroup; | 
| import io.swagger.annotations.ApiModelProperty; | 
| import lombok.Data; | 
| import lombok.EqualsAndHashCode; | 
|   | 
| import javax.validation.constraints.NotNull; | 
| import java.util.ArrayList; | 
| import java.util.List; | 
|   | 
| /** | 
|  * SYS_JOB | 
|  * | 
|  * @author zt generator | 
|  * @since 1.0.0 2020-06-04 | 
|  */ | 
| @Data | 
| @EqualsAndHashCode(callSuper=false) | 
| @TableName("SYS_JOB") | 
| public class SysJob extends CompanyEntity implements TreeNode<SysJob> { | 
|     private static final long serialVersionUID = 1L; | 
|   | 
|     @ApiModelProperty(value = "上级Id") | 
|     @NotNull(message="上级ID,不能为空", groups = DefaultGroup.class) | 
|     private Long pid; | 
|   | 
|     @ApiModelProperty(value = "职位名称") | 
|     @NotNull(message="职位名称不能为空", groups = DefaultGroup.class) | 
|     private String name; | 
|   | 
|     @ApiModelProperty(value = "职位编码") | 
|     @NotNull(message="职位编码不能为空", groups = DefaultGroup.class) | 
|     private String code; | 
|   | 
|     @ApiModelProperty(value = "备注") | 
|     private String remark; | 
|   | 
|     @ApiModelProperty(value = "排序") | 
|     private Integer sort; | 
|   | 
|     @ApiModelProperty(value = "子岗位") | 
|     @TableField(exist = false) | 
|     private List<SysJob> children = new ArrayList<>(); | 
| } |