From d2fb33d88849286575ecedd708d97d98a0572cac Mon Sep 17 00:00:00 2001 From: "puxiao.liao" Date: Thu, 2 Apr 2020 12:50:16 +0800 Subject: [PATCH] =?UTF-8?q?bug1536=E3=80=901536=20PDA=E7=BB=84=E4=BB=B6?= =?UTF-8?q?=E4=BF=AE=E6=94=B9=E5=A2=9E=E5=8A=A0=E5=BD=95=E5=85=A5=E8=BD=A6?= =?UTF-8?q?=E7=89=8C=E4=BF=A1=E6=81=AF=E5=8A=9F=E8=83=BD=E3=80=91?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- .../i3plus/pojo/base/enumutil/WmsEnumUtil.java | 79 ++++++++++++++++++---- 1 file changed, 66 insertions(+), 13 deletions(-) diff --git a/modules/i3plus-pojo-base/src/main/java/cn/estsh/i3plus/pojo/base/enumutil/WmsEnumUtil.java b/modules/i3plus-pojo-base/src/main/java/cn/estsh/i3plus/pojo/base/enumutil/WmsEnumUtil.java index 64f03c6..dcc9407 100644 --- a/modules/i3plus-pojo-base/src/main/java/cn/estsh/i3plus/pojo/base/enumutil/WmsEnumUtil.java +++ b/modules/i3plus-pojo-base/src/main/java/cn/estsh/i3plus/pojo/base/enumutil/WmsEnumUtil.java @@ -5502,9 +5502,9 @@ public class WmsEnumUtil { WAVE_MERGE_RULE(10, "WAVE_MERGE_RULE", "合并规则"), WAVE_MERGE_RANGE(20, "WAVE_MERGE_RANGE", "合并范围"); - int value; - String code; - String description; + private int value; + private String code; + private String description; WAVE_MERGE_TYPE(int value, String code, String description) { this.value = value; @@ -5689,6 +5689,16 @@ public class WmsEnumUtil { } return tmp; } + + public static String valueOfDescription(int val) { + String tmp = null; + for (int i = 0; i < values().length; i++) { + if (values()[i].value == val) { + tmp = values()[i].description; + } + } + return tmp; + } } /** @@ -5728,16 +5738,7 @@ public class WmsEnumUtil { return null; } - public static String valueOf(int val) { - String tmp = null; - for (int i = 0; i < values().length; i++) { - if (values()[i].value == val) { - tmp = values()[i].description; - } - } - return tmp; - } - public static String valueOfDescription(int val) { + public static String valueOfDescription ( int val){ String tmp = null; for (int i = 0; i < values().length; i++) { if (values()[i].value == val) { @@ -5787,4 +5788,56 @@ public class WmsEnumUtil { return tmp; } } + + + /** + * 业务场景Supplier + */ + @JsonFormat(shape = JsonFormat.Shape.OBJECT) + public enum BUSI_SCENE_TYPE { + YFAS_DELIVERY(10, "YFAS_DELIVERY", "YFAS送货"), + TURN_ZAITU_LOCATE(20, "TURN_ZAITU_LOCATE", "转储到在途库位"), + ORGANIZE_TRUN(30, "ORGANIZE_TRUN", "工厂内转储"), + SUPPLIER_SELF(40, "SUPPLIER_SELF", "供应商自提"), + CUSTOMER_SELF(50, "CUSTOMER_SELF", "客户自提"); + private int value; + private String code; + private String description; + + BUSI_SCENE_TYPE(int value, String code, String description) { + this.value = value; + this.code = code; + this.description = description; + } + + public int getValue() { + return value; + } + + public String getCode() { + return code; + } + + public String getDescription() { + return description; + } + + public static BUSI_SCENE_TYPE codeOf(String code) { + for (int i = 0; i < values().length; i++) { + if (values()[i].code.equals(code)) { + return values()[i]; + } + } + return null; + } + public static String valueOfDescription(int val) { + String tmp = null; + for (int i = 0; i < values().length; i++) { + if (values()[i].value == val) { + tmp = values()[i].description; + } + } + return tmp; + } + } } \ No newline at end of file