Skip to content
Projects
Groups
Snippets
Help
This project
Loading...
Sign in / Register
Toggle navigation
O
order-group
Overview
Overview
Details
Activity
Cycle Analytics
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Charts
Issues
0
Issues
0
List
Board
Labels
Milestones
Merge Requests
0
Merge Requests
0
CI / CD
CI / CD
Pipelines
Jobs
Schedules
Charts
Wiki
Wiki
Snippets
Snippets
Members
Collapse sidebar
Close sidebar
Activity
Graph
Charts
Create a new issue
Jobs
Commits
Issue Boards
Open sidebar
order-group-application
order-group
Commits
40cc98bf
Commit
40cc98bf
authored
Nov 18, 2021
by
周晓航
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
修复 枚举判断问题
Signed-off-by: 周晓航 <xiaohang.zhou@freemud.com>
parent
72cae5aa
Hide whitespace changes
Inline
Side-by-side
Showing
2 changed files
with
20 additions
and
10 deletions
+20
-10
assortment-ordercenter-sdk/src/main/java/com/freemud/sdk/api/assortment/order/enums/OrderSourceType.java
+7
-1
ordercenter-sdk/src/main/java/com/freemud/application/sdk/api/ordercenter/enums/OrderClientType.java
+13
-9
No files found.
assortment-ordercenter-sdk/src/main/java/com/freemud/sdk/api/assortment/order/enums/OrderSourceType.java
View file @
40cc98bf
...
@@ -14,6 +14,10 @@ package com.freemud.sdk.api.assortment.order.enums;
...
@@ -14,6 +14,10 @@ package com.freemud.sdk.api.assortment.order.enums;
import
org.apache.commons.lang.StringUtils
;
import
org.apache.commons.lang.StringUtils
;
/**
* com.freemud.application.sdk.api.ordercenter.enums.OrderClientType
* 两个枚举类 需要同步加, 不然在订单业务代码中 会报错
*/
public
enum
OrderSourceType
{
public
enum
OrderSourceType
{
WE_CHAT
(
"we_chat"
,
"自营微信小程序"
,
1
),
WE_CHAT
(
"we_chat"
,
"自营微信小程序"
,
1
),
SAAS
(
"saas"
,
"saas 点餐"
,
2
),
SAAS
(
"saas"
,
"saas 点餐"
,
2
),
...
@@ -46,6 +50,7 @@ public enum OrderSourceType {
...
@@ -46,6 +50,7 @@ public enum OrderSourceType {
ASSISTANT
(
"assistant"
,
"非码小助手"
,
29
),
ASSISTANT
(
"assistant"
,
"非码小助手"
,
29
),
SHERPAS
(
"sherpas"
,
"食派士"
,
30
),
SHERPAS
(
"sherpas"
,
"食派士"
,
30
),
CASHIER
(
"cashier"
,
"收银单"
,
36
),
CASHIER
(
"cashier"
,
"收银单"
,
36
),
WE_CHAT_LIVE_SELL
(
"we_chat_live_sell"
,
"微信视频卖券"
,
37
),
parkingmanual
(
"parkingmanual"
,
"农工商停车手工录单"
,
98
),
parkingmanual
(
"parkingmanual"
,
"农工商停车手工录单"
,
98
),
PARKING
(
"parking"
,
"农工商停车"
,
99
),
PARKING
(
"parking"
,
"农工商停车"
,
99
),
SDG
(
"sdg"
,
"闪电购"
,
1000
);
SDG
(
"sdg"
,
"闪电购"
,
1000
);
...
@@ -64,7 +69,8 @@ public enum OrderSourceType {
...
@@ -64,7 +69,8 @@ public enum OrderSourceType {
if
(
e
.
getCode
().
equals
(
code
))
if
(
e
.
getCode
().
equals
(
code
))
return
e
;
return
e
;
}
}
return
null
;
// 没查询到 默认设置 saas
return
OrderSourceType
.
SAAS
;
}
}
/**
/**
...
...
ordercenter-sdk/src/main/java/com/freemud/application/sdk/api/ordercenter/enums/OrderClientType.java
View file @
40cc98bf
...
@@ -11,6 +11,10 @@ package com.freemud.application.sdk.api.ordercenter.enums;
...
@@ -11,6 +11,10 @@ package com.freemud.application.sdk.api.ordercenter.enums;
* @date: 2019/4/2 13:44
* @date: 2019/4/2 13:44
* @Copyright: 2019 www.freemud.cn Inc. All rights reserved.
* @Copyright: 2019 www.freemud.cn Inc. All rights reserved.
* 注意:本内容仅限于上海非码科技内部传阅,禁止外泄以及用于其他的商业目
* 注意:本内容仅限于上海非码科技内部传阅,禁止外泄以及用于其他的商业目
* <p>
* <p>
* * com.freemud.application.sdk.api.ordercenter.enums.OrderClientType
* * 两个枚举类 需要同步加, 不然在订单业务代码中 会报错
*/
*/
public
enum
OrderClientType
{
public
enum
OrderClientType
{
...
@@ -18,7 +22,7 @@ public enum OrderClientType {
...
@@ -18,7 +22,7 @@ public enum OrderClientType {
SAAS
(
2
,
"i点餐"
),
SAAS
(
2
,
"i点餐"
),
ALIPAY
(
3
,
"自营支付宝小程序"
),
ALIPAY
(
3
,
"自营支付宝小程序"
),
HTML5
(
4
,
"自营H5"
),
HTML5
(
4
,
"自营H5"
),
ANDROID
(
5
,
"自营安卓APP"
),
ANDROID
(
5
,
"自营安卓APP"
),
IOS
(
6
,
"自营苹果APP"
),
IOS
(
6
,
"自营苹果APP"
),
PC_WEB
(
7
,
"自营PC-WEB"
),
PC_WEB
(
7
,
"自营PC-WEB"
),
ELEME
(
8
,
"饿了么"
),
ELEME
(
8
,
"饿了么"
),
...
@@ -27,9 +31,9 @@ public enum OrderClientType {
...
@@ -27,9 +31,9 @@ public enum OrderClientType {
MEITUAN
(
11
,
"美团外卖"
),
MEITUAN
(
11
,
"美团外卖"
),
APP
(
12
,
"自营APP"
),
APP
(
12
,
"自营APP"
),
I_MEMBER
(
13
,
"i应用会员"
),
I_MEMBER
(
13
,
"i应用会员"
),
I_CARGO
(
14
,
"i应用订货"
),
I_CARGO
(
14
,
"i应用订货"
),
POS
(
15
,
"POS"
),
POS
(
15
,
"POS"
),
WAI_MEAL
(
19
,
"i围餐"
),
WAI_MEAL
(
19
,
"i围餐"
),
JUBAOPEN
(
20
,
"美团服务商"
),
JUBAOPEN
(
20
,
"美团服务商"
),
DIANPING
(
21
,
"美团点评"
),
DIANPING
(
21
,
"美团点评"
),
KOUBEI
(
22
,
"口碑"
),
KOUBEI
(
22
,
"口碑"
),
...
@@ -39,8 +43,8 @@ public enum OrderClientType {
...
@@ -39,8 +43,8 @@ public enum OrderClientType {
TIKTOKPAY
(
27
,
"抖音小程序"
),
TIKTOKPAY
(
27
,
"抖音小程序"
),
BEAUTIFUL
(
28
,
"美业"
),
BEAUTIFUL
(
28
,
"美业"
),
ASSISTANT
(
29
,
"非码小助手"
),
ASSISTANT
(
29
,
"非码小助手"
),
SHERPAS
(
30
,
"食派士"
),
SHERPAS
(
30
,
"食派士"
),
PARKING
(
99
,
"农工商停车"
),
PARKING
(
99
,
"农工商停车"
),
CASHIER
(
36
,
"收银买单"
),
CASHIER
(
36
,
"收银买单"
),
WE_CHAT_LIVE_SELL
(
37
,
"微信视频卖券"
),
WE_CHAT_LIVE_SELL
(
37
,
"微信视频卖券"
),
;
;
...
@@ -70,9 +74,9 @@ public enum OrderClientType {
...
@@ -70,9 +74,9 @@ public enum OrderClientType {
this
.
name
=
name
;
this
.
name
=
name
;
}
}
public
static
OrderClientType
getOrderClientType
(
Integer
index
){
public
static
OrderClientType
getOrderClientType
(
Integer
index
)
{
for
(
OrderClientType
orderType
:
values
()){
for
(
OrderClientType
orderType
:
values
())
{
if
(
index
.
equals
(
orderType
.
getIndex
())){
if
(
index
.
equals
(
orderType
.
getIndex
()))
{
return
orderType
;
return
orderType
;
}
}
}
}
...
...
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment