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
87caad29
Commit
87caad29
authored
Mar 30, 2021
by
孙昱
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
sunyu::update::fix bug about createOrder
parent
e240af67
Hide whitespace changes
Inline
Side-by-side
Showing
2 changed files
with
2 additions
and
5 deletions
+2
-5
shopping-cart-application-service/src/main/java/cn/freemud/enums/ResponseResult.java
+0
-1
shopping-cart-application-service/src/main/java/cn/freemud/service/impl/mcoffee/ShoppingCartMCoffeeServiceImpl.java
+2
-4
No files found.
shopping-cart-application-service/src/main/java/cn/freemud/enums/ResponseResult.java
View file @
87caad29
...
@@ -102,7 +102,6 @@ public enum ResponseResult {
...
@@ -102,7 +102,6 @@ public enum ResponseResult {
SHOPPING_CART_BUY_ONE_SEND_GOODS_ERR
(
"44033"
,
"寄件活动商品错误"
),
SHOPPING_CART_BUY_ONE_SEND_GOODS_ERR
(
"44033"
,
"寄件活动商品错误"
),
SHOPPING_CART_COUPON_MIX_NOT_EXIST
(
"44034"
,
"券商品不存在"
),
SHOPPING_CART_COUPON_MIX_NOT_EXIST
(
"44034"
,
"券商品不存在"
),
SHOPPING_CART_QTY_LIMIT_ERR
(
"44035"
,
"该商品单次购买数量限制为10,请知晓"
),
SHOPPING_CART_QTY_LIMIT_ERR
(
"44035"
,
"该商品单次购买数量限制为10,请知晓"
),
SHOPPING_CART_SEED_COUPON_VALID
(
"44037"
,
"券商品数量不可大于券数量"
),
SHOPPING_CART_MATERIA_QTY_LIMIT_ERR
(
"44038"
,
"商品加料超过最大限制"
),
SHOPPING_CART_MATERIA_QTY_LIMIT_ERR
(
"44038"
,
"商品加料超过最大限制"
),
/**
/**
...
...
shopping-cart-application-service/src/main/java/cn/freemud/service/impl/mcoffee/ShoppingCartMCoffeeServiceImpl.java
View file @
87caad29
...
@@ -879,6 +879,8 @@ public class ShoppingCartMCoffeeServiceImpl {
...
@@ -879,6 +879,8 @@ public class ShoppingCartMCoffeeServiceImpl {
// 获取购物车商品
// 获取购物车商品
List
<
CartGoods
>
cartGoodsList
=
assortmentSdkService
.
getShoppingCart
(
partnerId
,
storeId
,
userId
,
null
,
tableNumber
,
shoppingCartBaseService
);
List
<
CartGoods
>
cartGoodsList
=
assortmentSdkService
.
getShoppingCart
(
partnerId
,
storeId
,
userId
,
null
,
tableNumber
,
shoppingCartBaseService
);
log
.
info
(
"cartGoodsList: {}"
,
JSONObject
.
toJSONString
(
cartGoodsList
));
log
.
info
(
"cartGoodsList: {}"
,
JSONObject
.
toJSONString
(
cartGoodsList
));
//过滤月享卡2.0虚拟商品
cartGoodsList
=
cartGoodsList
.
stream
().
filter
(
goods
->
!
StringUtils
.
equals
(
"9999"
,
goods
.
getSkuId
())).
collect
(
Collectors
.
toList
());
if
(
cartGoodsList
==
null
||
CollectionUtils
.
isEmpty
(
cartGoodsList
))
{
if
(
cartGoodsList
==
null
||
CollectionUtils
.
isEmpty
(
cartGoodsList
))
{
throw
new
ServiceException
(
ResponseResult
.
SHOPPING_CART_GETINFO_INVAILD
);
throw
new
ServiceException
(
ResponseResult
.
SHOPPING_CART_GETINFO_INVAILD
);
}
}
...
@@ -2279,10 +2281,6 @@ public class ShoppingCartMCoffeeServiceImpl {
...
@@ -2279,10 +2281,6 @@ public class ShoppingCartMCoffeeServiceImpl {
if
(
StringUtils
.
isEmpty
(
addShoppingCartGoodsRequestVo
.
getCouponCode
())){
if
(
StringUtils
.
isEmpty
(
addShoppingCartGoodsRequestVo
.
getCouponCode
())){
throw
new
ServiceException
(
ResponseResult
.
SHOPPING_CART_ADD_ERROR
);
throw
new
ServiceException
(
ResponseResult
.
SHOPPING_CART_ADD_ERROR
);
}
}
//加购种子券商品,购物车中必须已有月卡不可为空
if
(
CollectionUtils
.
isEmpty
(
oldCartGoodsList
))
{
throw
new
ServiceException
(
ResponseResult
.
SHOPPING_CART_SEED_COUPON_VALID
);
}
for
(
CartGoods
cartGoods
:
oldCartGoodsList
)
{
for
(
CartGoods
cartGoods
:
oldCartGoodsList
)
{
//1.种子券商品券信息与月卡信息一致
//1.种子券商品券信息与月卡信息一致
if
(
null
!=
cartGoods
.
getMonthCardInfo
()
&&
!
addShoppingCartGoodsRequestVo
.
getCouponCode
().
equals
(
cartGoods
.
getMonthCardInfo
().
getCardCode
()))
{
if
(
null
!=
cartGoods
.
getMonthCardInfo
()
&&
!
addShoppingCartGoodsRequestVo
.
getCouponCode
().
equals
(
cartGoods
.
getMonthCardInfo
().
getCardCode
()))
{
...
...
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