This commit is contained in:
ran.shang
2025-06-11 09:42:13 +08:00
commit 7e38b8d971
1935 changed files with 132836 additions and 0 deletions

View File

@@ -0,0 +1,47 @@
package com.newyetai.recruit.user.enums;
import com.baomidou.mybatisplus.annotation.EnumValue;
import com.newyetai.mybatis.handle.BaseEnum;
/**
* 入职周期枚举
*/
public enum InductionCycleEnum implements BaseEnum<Integer> {
ANY_TIME(1, "随时入职"),
TWO_WEEKS(2, "2周内入职"),
ONE_MONTH(3, "一个月内入职");
@EnumValue
private final Integer type;
private final String desc;
InductionCycleEnum(Integer type, String desc) {
this.type = type;
this.desc = desc;
}
public Integer getType() {
return type;
}
public String getDesc() {
return desc;
}
@Override
public Integer getValue() {
return type;
}
public static Integer findTypeByDesc(String desc) {
for (InductionCycleEnum type : InductionCycleEnum.values()) {
if (type.getDesc().equals(desc)) {
return type.getType();
}
}
return null; // 如果没有找到,返回null
}
}