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
c0087f84
Commit
c0087f84
authored
Jun 18, 2021
by
周晓航
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
打日志
Signed-off-by: 周晓航 <xiaohang.zhou@freemud.com>
parent
ceb6f9b8
Hide whitespace changes
Inline
Side-by-side
Showing
2 changed files
with
9 additions
and
7 deletions
+9
-7
shopping-cart-application-service/src/main/java/cn/freemud/service/impl/CouponPromotionService.java
+4
-2
shopping-cart-application-service/src/main/java/cn/freemud/service/impl/ShoppingCartNewServiceImpl.java
+5
-5
No files found.
shopping-cart-application-service/src/main/java/cn/freemud/service/impl/CouponPromotionService.java
View file @
c0087f84
...
...
@@ -90,8 +90,10 @@ public class CouponPromotionService implements IPromotionService {
// 当couponCode不为空时,需计算优惠价格
long
couponDiscount
=
0
;
if
(
couponPromotionVO
!=
null
&&
StringUtils
.
isNotEmpty
(
couponPromotionVO
.
getCouponCode
())
&&
calculationDiscountResult
!=
null
)
{
if
(
couponPromotionVO
!=
null
&&
(
StringUtils
.
isNotEmpty
(
couponPromotionVO
.
getCouponCode
())
||
CollectionUtils
.
isNotEmpty
(
couponPromotionVO
.
getCouponCodes
()))
&&
calculationDiscountResult
!=
null
)
{
List
<
ActivityCalculationDiscountResponseDto
.
CalculationDiscountResult
.
CouponResults
>
couponResultsList
=
calculationDiscountResult
.
getCouponDiscounts
();
if
(
CollectionUtils
.
isNotEmpty
(
couponResultsList
))
{
for
(
ActivityCalculationDiscountResponseDto
.
CalculationDiscountResult
.
CouponResults
couponResults
:
couponResultsList
)
{
...
...
shopping-cart-application-service/src/main/java/cn/freemud/service/impl/ShoppingCartNewServiceImpl.java
View file @
c0087f84
...
...
@@ -1783,7 +1783,6 @@ public class ShoppingCartNewServiceImpl implements ShoppingCartNewService {
/**
* 满额减配送费
*/
if
(
BusinessTypeEnum
.
SAAS_DELIVERY
.
getCode
().
equals
(
menuType
))
{
DecimalFormat
df
=
new
DecimalFormat
(
"###.##"
);
List
<
ActivityTypeEnum
>
activityTypeEnums
=
new
LinkedList
<>();
...
...
@@ -1833,21 +1832,22 @@ public class ShoppingCartNewServiceImpl implements ShoppingCartNewService {
}
shoppingCartGoodsResponseVo
.
setDeliveryAmount
(
deliveryAmount
);
// shoppingCartGoodsResponseVo.setDiscountDeliveryAmount(deliveryAmount); 原有逻辑
shoppingCartGoodsResponseVo
.
setDiscountDeliveryAmount
(
deliveryAmount
);
// 增加配送券之后的逻辑
shoppingCartGoodsResponseVo
.
setDiscountDeliveryAmount
(
calculationDiscountResult
==
null
?
deliveryAmount:
calculationDiscountResult
.
getDistributionFee
());
//
shoppingCartGoodsResponseVo.setDiscountDeliveryAmount(calculationDiscountResult==null?deliveryAmount:calculationDiscountResult.getDistributionFee());
shoppingCartGoodsResponseVo
.
setIsDiscountDelivery
(
false
);
}
else
{
String
desc
=
DELIVERY_DISCOUNT_DESC3
;
shoppingCartGoodsResponseVo
.
setDeliveryDiscountDesc
(
String
.
format
(
desc
,
df
.
format
(
deliveryAmount
.
doubleValue
()
/
100
)));
shoppingCartGoodsResponseVo
.
setDeliveryAmount
(
deliveryAmount
);
// shoppingCartGoodsResponseVo.setDiscountDeliveryAmount(deliveryAmount); 原有逻辑
shoppingCartGoodsResponseVo
.
setDiscountDeliveryAmount
(
deliveryAmount
);
// 增加配送券之后的逻辑
shoppingCartGoodsResponseVo
.
setDiscountDeliveryAmount
(
calculationDiscountResult
==
null
?
deliveryAmount:
calculationDiscountResult
.
getDistributionFee
());
//
shoppingCartGoodsResponseVo.setDiscountDeliveryAmount(calculationDiscountResult==null?deliveryAmount:calculationDiscountResult.getDistributionFee());
shoppingCartGoodsResponseVo
.
setIsDiscountDelivery
(
false
);
}
}
LogUtil
.
info
(
"fisherman 满额减配送算价格"
,
discount
,
shoppingCartGoodsResponseVo
);
}
/**
...
...
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