Commit c302ee64 by 崔彦峰

refactor(enum): 迁移商品上架相关枚举类到新模块

- 将 ShelfModelEnum 从 rpc-smartcarlife 模块迁移到 rpc-dj-goods-listing 模块
- 将 ShelfStyleEnum 从 rpc-smartcarlife 模块迁移到 rpc-dj-goods-listing 模块
- 更新包路径为 cn.com.glsx.dj.goods.listing.enums
- 移除原 smartcarlife 模块中的重复枚举定义
- 保持枚举结构和功能完全一致
1 parent d0f3c5d9
package cn.com.glsx.dj.goods.listing.enums;
/**
* 上架模式
*/
public enum ShelfModelEnum {
/**
* 特殊商品上架
*/
SPECIAL_SHELF((byte)1,"特殊商品上架"),
/**
* 常规商品上架
*/
ORDINARY_SHELF((byte)2,"常规商品上架")
;
private byte value;
private String displayName;
ShelfModelEnum(Byte value, String displayName) {
this.value = value;
this.displayName = displayName;
}
public byte getValue() {
return value;
}
public String getDisplayName() {
return displayName;
}
public static ShelfModelEnum getByValue(Byte value){
if (value != null) {
for (ShelfModelEnum temp : ShelfModelEnum.values()) {
if (temp.getValue() == value.byteValue()) {
return temp;
}
}
}
return null;
}
}
\ No newline at end of file \ No newline at end of file
package cn.com.glsx.dj.goods.listing.enums;
/**
* 类型(上架方式)
*/
public enum ShelfStyleEnum {
/**
* 新增
*/
ADD((byte)1,"新增"),
/**
* 修改
*/
UPDATE((byte)2,"修改")
;
private byte value;
private String displayName;
ShelfStyleEnum(Byte value, String displayName) {
this.value = value;
this.displayName = displayName;
}
public byte getValue() {
return value;
}
public String getDisplayName() {
return displayName;
}
public static ShelfStyleEnum getByValue(Byte value){
if (value != null) {
for (ShelfStyleEnum temp : ShelfStyleEnum.values()) {
if (temp.getValue() == value.byteValue()) {
return temp;
}
}
}
return null;
}
}
\ No newline at end of file \ No newline at end of file
Markdown is supported
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!