mirror of
https://gitee.com/youlaitech/youlai-mall.git
synced 2024-12-23 05:00:25 +08:00
refactor(QueryModeEnum.java): 移除RESTful接口的查询模式字段
This commit is contained in:
parent
70d9d97d8e
commit
0ded90dadf
@ -1,31 +0,0 @@
|
||||
package com.youlai.common.enums;
|
||||
|
||||
import lombok.Getter;
|
||||
import lombok.Setter;
|
||||
|
||||
public enum QueryModeEnum {
|
||||
|
||||
PAGE("page" ), // 分页查询
|
||||
LIST("list"), //列表查询
|
||||
TREE("tree"),//树形列表
|
||||
CASCADER("cascader"), // 级联列表 对应级联选择器的下拉格式数据
|
||||
;
|
||||
|
||||
@Getter
|
||||
@Setter
|
||||
private String code;
|
||||
|
||||
QueryModeEnum(String code) {
|
||||
this.code=code;
|
||||
}
|
||||
|
||||
public static QueryModeEnum getByCode(String code){
|
||||
for (QueryModeEnum value : values()) {
|
||||
if (value.getCode().equals(code)) {
|
||||
return value;
|
||||
}
|
||||
}
|
||||
return PAGE; // 默认分页查询
|
||||
}
|
||||
|
||||
}
|
Loading…
Reference in New Issue
Block a user