mirror of
https://codeup.aliyun.com/67762337eccfc218f6110e0e/per-boe/java-servers.git
synced 2025-12-24 02:02:59 +08:00
feat: 课程列表SQL版
完善了所有查询条件,并完善导出接口
This commit is contained in:
@@ -0,0 +1,31 @@
|
||||
package com.xboe.enums;
|
||||
|
||||
import lombok.Getter;
|
||||
|
||||
import java.util.Arrays;
|
||||
|
||||
/**
|
||||
* 课程创建来源
|
||||
* boe_course.create_from
|
||||
*/
|
||||
@Getter
|
||||
public enum CourseCreateFromEnum {
|
||||
|
||||
ADMIN("admin", "管理端"),
|
||||
|
||||
TEACHER("teacher", "教师端")
|
||||
;
|
||||
|
||||
private final String code;
|
||||
|
||||
private final String label;
|
||||
|
||||
CourseCreateFromEnum(String code, String label) {
|
||||
this.code = code;
|
||||
this.label = label;
|
||||
}
|
||||
|
||||
public static CourseCreateFromEnum getByCode(String code) {
|
||||
return Arrays.stream(values()).filter(item -> item.code.equals(code)).findFirst().orElse(ADMIN);
|
||||
}
|
||||
}
|
||||
Reference in New Issue
Block a user