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
1788bf94
Commit
1788bf94
authored
Jun 18, 2021
by
徐康
Browse files
Options
Browse Files
Download
Plain Diff
Merge remote-tracking branch 'origin/qa' into qa
parents
817e2d75
12b919de
Hide whitespace changes
Inline
Side-by-side
Showing
2 changed files
with
9 additions
and
5 deletions
+9
-5
shopping-cart-application-service/src/main/java/cn/freemud/adapter/ActivityAdapter.java
+5
-2
shopping-cart-application-service/src/main/java/cn/freemud/service/impl/ShoppingCartNewServiceImpl.java
+4
-3
No files found.
shopping-cart-application-service/src/main/java/cn/freemud/adapter/ActivityAdapter.java
View file @
1788bf94
...
...
@@ -457,14 +457,17 @@ public class ActivityAdapter {
couponAvailableCartInfo
.
setOriginalTotalAmount
(
discountResult
.
getOriginalTotalAmount
()
-
totalMealDiscountAmount
);
couponAvailableCartInfo
.
setRealAmount
(
discountResult
.
getTotalAmount
());
couponAvailableCartInfo
.
setDiscountAmount
(
discountResult
.
getTotalDiscountAmount
()
-
totalMealDiscountAmount
);
couponAvailableCartInfo
.
setDeliveryAmount
(
discountResult
.
getDeliveryAmount
());
couponAvailableCartInfo
.
setDistributionFee
(
discountResult
.
getDistributionFee
());
}
else
{
couponAvailableCartInfo
.
setProductList
(
new
ArrayList
<>());
couponAvailableCartInfo
.
setOriginalTotalAmount
(
0L
);
couponAvailableCartInfo
.
setRealAmount
(
0L
);
couponAvailableCartInfo
.
setDiscountAmount
(
0L
);
couponAvailableCartInfo
.
setDeliveryAmount
(
0L
);
couponAvailableCartInfo
.
setDistributionFee
(
0L
);
}
couponAvailableCartInfo
.
setDeliveryAmount
(
discountResult
.
getDeliveryAmount
());
couponAvailableCartInfo
.
setDistributionFee
(
discountResult
.
getDistributionFee
());
return
couponAvailableCartInfo
;
}
private
Pair
<
Long
,
Long
>
getSmallMaterialAmountSharing
(
List
<
CalculationSharingDiscountResponseDto
.
CalculationDiscountResult
.
Goods
.
SmallMaterial
>
smallMaterial
){
...
...
shopping-cart-application-service/src/main/java/cn/freemud/service/impl/ShoppingCartNewServiceImpl.java
View file @
1788bf94
...
...
@@ -755,7 +755,7 @@ public class ShoppingCartNewServiceImpl implements ShoppingCartNewService {
});
}
// 获取优惠信息
// 获取优惠信息
调用促销
ActivityCalculationDiscountResponseDto
.
CalculationDiscountResult
calculationDiscountResult
=
getCalculationDiscountResult
(
menuType
,
partnerId
,
storeId
,
userId
,
appId
,
userLoginInfoDto
.
getWxAppid
(),
orderType
,
assortmentCustomerInfoVo
.
isMemberPaid
(),
cartGoodsList
,
coupons
,
null
,
shoppingCartInfoRequestVo
.
getReceiveId
(),
deliveryAmount
);
...
...
@@ -3055,6 +3055,7 @@ public class ShoppingCartNewServiceImpl implements ShoppingCartNewService {
CouponAvailableCartInfo
couponAvailableCartInfo
;
List
<
String
>
orgCodes
=
commonService
.
getOrgIdsForCoupon
(
partnerId
,
storeId
);
Long
deliveryAmount
=
calculateDeliveryAmount
(
requestVo
.
getReceiveId
(),
partnerId
,
storeId
,
assortmentCustomerInfoVo
.
getWxAppId
(),
new
ShoppingCartGoodsResponseVo
(),
requestVo
.
getOrderType
());
// 获取购物车商品
List
<
CartGoods
>
cartGoodsList
=
assortmentSdkService
.
getShoppingCartForCoupon
(
partnerId
,
requestVo
.
getStoreId
(),
userId
,
""
,
shoppingCartBaseService
);
if
(
grayPush
(
partnerId
,
storeId
,
"2"
))
{
...
...
@@ -3068,13 +3069,13 @@ public class ShoppingCartNewServiceImpl implements ShoppingCartNewService {
,
cartGoodsList
,
new
ArrayList
<>()
//券
,
null
//加价购商品
,
0L
,
deliveryAmount
,
null
);
couponAvailableCartInfo
=
activityAdapter
.
convert2CouponAvailableCartInfoSharing
(
partnerId
,
storeId
,
discountResult
,
orgCodes
);
}
else
{
// 获取优惠信息
ActivityCalculationDiscountResponseDto
.
CalculationDiscountResult
calculationDiscountResult
=
getCalculationDiscountResult
(
menuType
,
partnerId
,
storeId
,
userId
,
appId
,
assortmentCustomerInfoVo
.
getWxAppId
(),
orderType
,
assortmentCustomerInfoVo
.
isMemberPaid
(),
cartGoodsList
,
new
ArrayList
<>(),
null
,
null
,
0L
);
ActivityCalculationDiscountResponseDto
.
CalculationDiscountResult
calculationDiscountResult
=
getCalculationDiscountResult
(
menuType
,
partnerId
,
storeId
,
userId
,
appId
,
assortmentCustomerInfoVo
.
getWxAppId
(),
orderType
,
assortmentCustomerInfoVo
.
isMemberPaid
(),
cartGoodsList
,
new
ArrayList
<>(),
null
,
null
,
deliveryAmount
);
couponAvailableCartInfo
=
activityAdapter
.
convert2CouponAvailableCartInfo
(
partnerId
,
storeId
,
calculationDiscountResult
,
orgCodes
);
}
return
ResponseUtil
.
success
(
couponAvailableCartInfo
);
...
...
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