记得上下班打卡 | git大法好,push需谨慎
Skip to content
Projects
Groups
Snippets
Help
Loading...
Help
Submit feedback
Contribute to GitLab
Sign in
Toggle navigation
L
liquidnet-bus-v1
Project
Project
Details
Activity
Releases
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
Members
Collapse sidebar
Close sidebar
Activity
Graph
Charts
Create a new issue
Jobs
Commits
Issue Boards
Open sidebar
董敬伟
liquidnet-bus-v1
Commits
6c2f3ed8
Commit
6c2f3ed8
authored
Mar 04, 2022
by
胡佳晨
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
修改 订单用券逻辑
1.跨店铺不可用平台券 2.店铺券+平台券不可一起使用
parent
df34e665
Changes
2
Hide whitespace changes
Inline
Side-by-side
Showing
2 changed files
with
20 additions
and
5 deletions
+20
-5
GoblinOrderServiceImpl.java
...t/service/goblin/service/impl/GoblinOrderServiceImpl.java
+19
-5
GoblinStoreBackOrderServiceImpl.java
.../service/impl/manage/GoblinStoreBackOrderServiceImpl.java
+1
-0
No files found.
liquidnet-bus-service/liquidnet-service-goblin/liquidnet-service-goblin-impl/src/main/java/com/liquidnet/service/goblin/service/impl/GoblinOrderServiceImpl.java
View file @
6c2f3ed8
...
@@ -194,7 +194,11 @@ public class GoblinOrderServiceImpl implements IGoblinOrderService {
...
@@ -194,7 +194,11 @@ public class GoblinOrderServiceImpl implements IGoblinOrderService {
return
ResponseDto
.
failure
(
ErrorMapping
.
get
(
"20018"
));
//乱七八糟异常
return
ResponseDto
.
failure
(
ErrorMapping
.
get
(
"20018"
));
//乱七八糟异常
}
else
if
(
e
.
getMessage
().
equals
(
"无权购买"
))
{
}
else
if
(
e
.
getMessage
().
equals
(
"无权购买"
))
{
return
ResponseDto
.
failure
(
e
.
getMessage
());
return
ResponseDto
.
failure
(
e
.
getMessage
());
}
else
if
(
e
.
getMessage
().
equals
(
"平台券不可用"
))
{
}
else
if
(
e
.
getMessage
().
equals
(
"平台券店铺券不可一起使用"
))
{
return
ResponseDto
.
failure
(
e
.
getMessage
());
}
else
if
(
e
.
getMessage
().
equals
(
"平台券店铺券不可一起使用"
))
{
return
ResponseDto
.
failure
(
e
.
getMessage
());
}
else
if
(
e
.
getMessage
().
equals
(
"跨店铺购物平台券不可用"
))
{
return
ResponseDto
.
failure
(
e
.
getMessage
());
return
ResponseDto
.
failure
(
e
.
getMessage
());
}
else
if
(
e
.
getMessage
().
equals
(
"店铺券不可用"
))
{
}
else
if
(
e
.
getMessage
().
equals
(
"店铺券不可用"
))
{
return
ResponseDto
.
failure
(
e
.
getMessage
());
return
ResponseDto
.
failure
(
e
.
getMessage
());
...
@@ -284,6 +288,16 @@ public class GoblinOrderServiceImpl implements IGoblinOrderService {
...
@@ -284,6 +288,16 @@ public class GoblinOrderServiceImpl implements IGoblinOrderService {
orderSku
.
setSpuPic
(
spuVo
.
getCoverPic
());
orderSku
.
setSpuPic
(
spuVo
.
getCoverPic
());
goblinOrderSkuList
.
add
(
orderSku
);
goblinOrderSkuList
.
add
(
orderSku
);
}
}
if
((
platVoucherCode
!=
null
&&
!
platVoucherCode
.
equals
(
""
))
&&
(
storeVoucherCode
!=
null
&&
!
storeVoucherCode
.
equals
(
""
)))
{
throw
new
Exception
(
"平台券店铺券不可一起使用"
);
}
if
(
param
.
getGoblinOrderStoreParamList
().
size
()>
1
&&
(
platVoucherCode
!=
null
&&
!
platVoucherCode
.
equals
(
""
))){
throw
new
Exception
(
"跨店铺购物平台券不可用"
);
}
//优惠券
//优惠券
BigDecimal
voucherPrice
=
BigDecimal
.
ZERO
;
BigDecimal
voucherPrice
=
BigDecimal
.
ZERO
;
if
(
platVoucherCode
!=
null
&&
!
platVoucherCode
.
equals
(
""
))
{
if
(
platVoucherCode
!=
null
&&
!
platVoucherCode
.
equals
(
""
))
{
...
@@ -358,7 +372,7 @@ public class GoblinOrderServiceImpl implements IGoblinOrderService {
...
@@ -358,7 +372,7 @@ public class GoblinOrderServiceImpl implements IGoblinOrderService {
storeOrder
.
setPriceRefund
(
BigDecimal
.
ZERO
);
storeOrder
.
setPriceRefund
(
BigDecimal
.
ZERO
);
storeOrder
.
setPriceCoupon
(
voucherPrice
);
storeOrder
.
setPriceCoupon
(
voucherPrice
);
storeOrder
.
setStorePriceCoupon
(
storeVoucherPrice
);
storeOrder
.
setStorePriceCoupon
(
storeVoucherPrice
);
storeOrder
.
setPriceVoucher
(
voucherPrice
.
add
(
storeVoucherPrice
)
.
add
(
voucherMarket
)
);
storeOrder
.
setPriceVoucher
(
voucherPrice
.
add
(
storeVoucherPrice
));
storeOrder
.
setStatus
(
0
);
storeOrder
.
setStatus
(
0
);
storeOrder
.
setUcouponId
(
platVoucherCode
);
storeOrder
.
setUcouponId
(
platVoucherCode
);
storeOrder
.
setStoreCouponId
(
storeVoucherCode
);
storeOrder
.
setStoreCouponId
(
storeVoucherCode
);
...
@@ -747,7 +761,7 @@ public class GoblinOrderServiceImpl implements IGoblinOrderService {
...
@@ -747,7 +761,7 @@ public class GoblinOrderServiceImpl implements IGoblinOrderService {
redisUtils
.
setGoblinOrder
(
orderId
,
orderVo
);
redisUtils
.
setGoblinOrder
(
orderId
,
orderVo
);
redisUtils
.
setOffCode
(
orderVo
.
getWriteOffCode
(),
orderVo
.
getMasterOrderCode
());
redisUtils
.
setOffCode
(
orderVo
.
getWriteOffCode
(),
orderVo
.
getMasterOrderCode
());
//删除未支付订单
//删除未支付订单
redisUtils
.
removeGoblinOrder
(
orderVo
.
getRandomKey
()
+
""
,
orderId
);
redisUtils
.
removeGoblinOrder
(
orderVo
.
getRandomKey
()
+
""
,
orderId
);
//mongo
//mongo
mongoUtils
.
updateGoblinStoreOrderVo
(
orderId
,
orderVo
);
mongoUtils
.
updateGoblinStoreOrderVo
(
orderId
,
orderVo
);
//mysql
//mysql
...
@@ -929,9 +943,9 @@ public class GoblinOrderServiceImpl implements IGoblinOrderService {
...
@@ -929,9 +943,9 @@ public class GoblinOrderServiceImpl implements IGoblinOrderService {
SqlMapping
.
gets
(
sqls
,
sqlsOrder
,
sqlsOrderSku
,
sqlsBackOrder
));
SqlMapping
.
gets
(
sqls
,
sqlsOrder
,
sqlsOrderSku
,
sqlsBackOrder
));
}
else
if
(
0
==
status
)
{
}
else
if
(
0
==
status
)
{
}
return
"success"
;
}
}
return
"success"
;
}
@Override
@Override
public
ResponseDto
<
List
<
GoblinMailVo
>>
getMail
(
String
orderId
,
String
mailId
)
{
public
ResponseDto
<
List
<
GoblinMailVo
>>
getMail
(
String
orderId
,
String
mailId
)
{
...
...
liquidnet-bus-service/liquidnet-service-goblin/liquidnet-service-goblin-impl/src/main/java/com/liquidnet/service/goblin/service/impl/manage/GoblinStoreBackOrderServiceImpl.java
View file @
6c2f3ed8
...
@@ -95,6 +95,7 @@ public class GoblinStoreBackOrderServiceImpl implements IGoblinStoreBackOrderSer
...
@@ -95,6 +95,7 @@ public class GoblinStoreBackOrderServiceImpl implements IGoblinStoreBackOrderSer
List
<
GoblinOrderSkuVo
>
orderSkuVoList
=
ObjectUtil
.
getGoblinOrderSkuVoArrayList
();
List
<
GoblinOrderSkuVo
>
orderSkuVoList
=
ObjectUtil
.
getGoblinOrderSkuVoArrayList
();
for
(
String
orderSkuVoId
:
orderVo
.
getOrderSkuVoIds
())
{
for
(
String
orderSkuVoId
:
orderVo
.
getOrderSkuVoIds
())
{
GoblinOrderSkuVo
orderSkuVo
=
redisUtils
.
getGoblinOrderSkuVo
(
orderSkuVoId
);
GoblinOrderSkuVo
orderSkuVo
=
redisUtils
.
getGoblinOrderSkuVo
(
orderSkuVoId
);
orderSkuVo
.
setStatus
(
vo
.
getStatus
());
orderSkuVoList
.
add
(
orderSkuVo
);
orderSkuVoList
.
add
(
orderSkuVo
);
}
}
vo
.
setOrderSkuVoList
(
orderSkuVoList
);
vo
.
setOrderSkuVoList
(
orderSkuVoList
);
...
...
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