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
b465bb38
Commit
b465bb38
authored
Nov 23, 2020
by
徐康
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
商品券重复加车校验和恢复代码
parent
ae2ca9e3
Hide whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
9 additions
and
0 deletions
+9
-0
order-application-service/src/main/java/cn/freemud/service/impl/CheckMCCafeOrder.java
+9
-0
No files found.
order-application-service/src/main/java/cn/freemud/service/impl/CheckMCCafeOrder.java
View file @
b465bb38
...
@@ -557,12 +557,21 @@ public class CheckMCCafeOrder {
...
@@ -557,12 +557,21 @@ public class CheckMCCafeOrder {
throw
new
ServiceException
(
ResponseResult
.
SHOPPING_CART_GETINFO_INVAILD
);
throw
new
ServiceException
(
ResponseResult
.
SHOPPING_CART_GETINFO_INVAILD
);
}
}
List
<
MCCafeCouponVo
>
mcCafeCouponVos
=
new
ArrayList
<>();
List
<
MCCafeCouponVo
>
mcCafeCouponVos
=
new
ArrayList
<>();
Map
<
String
,
String
>
mcCafeUsedCoupon
=
new
HashMap
<>();
if
(
CollectionUtils
.
isNotEmpty
(
shoppingCartGoodsDto
.
getActivityDiscountsDtos
()))
{
if
(
CollectionUtils
.
isNotEmpty
(
shoppingCartGoodsDto
.
getActivityDiscountsDtos
()))
{
shoppingCartGoodsDto
.
getActivityDiscountsDtos
().
forEach
(
o
->
{
shoppingCartGoodsDto
.
getActivityDiscountsDtos
().
forEach
(
o
->
{
if
(
ActivityTypeEnum
.
TYPE_3
.
getCode
().
equals
(
o
.
getActivityType
())
||
ActivityTypeEnum
.
TYPE_32
.
getCode
().
equals
(
o
.
getActivityType
())
if
(
ActivityTypeEnum
.
TYPE_3
.
getCode
().
equals
(
o
.
getActivityType
())
||
ActivityTypeEnum
.
TYPE_32
.
getCode
().
equals
(
o
.
getActivityType
())
||
ActivityTypeEnum
.
TYPE_34
.
getCode
().
equals
(
o
.
getActivityType
())
||
ActivityTypeEnum
.
TYPE_35
.
getCode
().
equals
(
o
.
getActivityType
()))
{
||
ActivityTypeEnum
.
TYPE_34
.
getCode
().
equals
(
o
.
getActivityType
())
||
ActivityTypeEnum
.
TYPE_35
.
getCode
().
equals
(
o
.
getActivityType
()))
{
mcCafeCouponVos
.
add
(
new
MCCafeCouponVo
(
o
.
getActivityCode
()));
mcCafeCouponVos
.
add
(
new
MCCafeCouponVo
(
o
.
getActivityCode
()));
}
}
if
(
ActivityTypeEnum
.
TYPE_32
.
getCode
().
equals
(
o
.
getActivityType
())
&&
null
!=
o
.
getExtendType
()
&&
(
0
==
o
.
getExtendType
()
||
3
==
o
.
getExtendType
()
||
4
==
o
.
getExtendType
()
||
5
==
o
.
getExtendType
()))
{
if
(
StringUtils
.
isNotBlank
(
mcCafeUsedCoupon
.
get
(
o
.
getActivityCode
())))
{
throw
new
ServiceException
(
ResponseResult
.
COUPON_SHOP_NOTSUPPORT
,
o
.
getActivityName
()
+
"不可以重复使用"
);
}
else
{
mcCafeUsedCoupon
.
put
(
o
.
getActivityCode
(),
o
.
getActivityName
());
}
}
});
});
}
}
if
(
CollectionUtils
.
isNotEmpty
(
mcCafeCouponVos
))
{
if
(
CollectionUtils
.
isNotEmpty
(
mcCafeCouponVos
))
{
...
...
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