记得上下班打卡 | 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
a83bbd26
Commit
a83bbd26
authored
Mar 02, 2022
by
胡佳晨
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
修改 如果 orderSkuVo的退款金额大于等于支付金额 则 减少购买个数
取消订单 减少购买个数 用券仅支持整单退款
parent
889371d0
Changes
3
Hide whitespace changes
Inline
Side-by-side
Showing
3 changed files
with
13 additions
and
5 deletions
+13
-5
GoblinOrderAppServiceImpl.java
...ervice/goblin/service/impl/GoblinOrderAppServiceImpl.java
+11
-5
GoblinOrderServiceImpl.java
...t/service/goblin/service/impl/GoblinOrderServiceImpl.java
+1
-0
GoblinStoreOrderServiceImpl.java
...blin/service/impl/manage/GoblinStoreOrderServiceImpl.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/GoblinOrderAppServiceImpl.java
View file @
a83bbd26
...
@@ -227,6 +227,12 @@ public class GoblinOrderAppServiceImpl implements IGoblinOrderAppService {
...
@@ -227,6 +227,12 @@ public class GoblinOrderAppServiceImpl implements IGoblinOrderAppService {
}
}
}
}
//判断券
if
((!(
orderVo
.
getUcouponId
()
==
null
||
orderVo
.
getUcouponId
().
equals
(
""
))
||
!(
orderVo
.
getStoreCouponId
()
==
null
||
orderVo
.
getStoreCouponId
().
equals
(
""
)))
&&
param
.
getOrderSkuId
()
!=
null
)
{
return
ResponseDto
.
failure
(
"用券仅支持整单退款"
);
}
//退款订单生成
//退款订单生成
GoblinBackOrder
backOrder
=
GoblinBackOrder
.
getNew
();
GoblinBackOrder
backOrder
=
GoblinBackOrder
.
getNew
();
backOrder
.
setBackOrderId
(
IDGenerator
.
nextTimeId2
());
backOrder
.
setBackOrderId
(
IDGenerator
.
nextTimeId2
());
...
@@ -248,7 +254,7 @@ public class GoblinOrderAppServiceImpl implements IGoblinOrderAppService {
...
@@ -248,7 +254,7 @@ public class GoblinOrderAppServiceImpl implements IGoblinOrderAppService {
backOrder
.
setDescribes
(
param
.
getDescribes
());
backOrder
.
setDescribes
(
param
.
getDescribes
());
backOrder
.
setSkuIdNums
(
Joiner
.
on
(
","
).
join
(
orderVo
.
getOrderSkuVoIds
()));
backOrder
.
setSkuIdNums
(
Joiner
.
on
(
","
).
join
(
orderVo
.
getOrderSkuVoIds
()));
}
else
if
(
orderVo
.
getStatus
()
==
GoblinStatusConst
.
Status
.
ORDER_STATUS_4
.
getValue
())
{
//已完成
}
else
if
(
orderVo
.
getStatus
()
==
GoblinStatusConst
.
Status
.
ORDER_STATUS_4
.
getValue
())
{
//已完成
if
(
param
.
getOrderSkuId
()!=
null
)
{
if
(
param
.
getOrderSkuId
()
!=
null
)
{
GoblinOrderSkuVo
orderSkuVo
=
redisUtils
.
getGoblinOrderSkuVo
(
param
.
getOrderSkuId
());
GoblinOrderSkuVo
orderSkuVo
=
redisUtils
.
getGoblinOrderSkuVo
(
param
.
getOrderSkuId
());
if
(
orderVo
.
getPriceRefund
().
add
(
orderSkuVo
.
getSkuPriceActual
()).
add
(
orderVo
.
getPriceExpress
()).
compareTo
(
orderVo
.
getPriceActual
())
>=
0
)
{
if
(
orderVo
.
getPriceRefund
().
add
(
orderSkuVo
.
getSkuPriceActual
()).
add
(
orderVo
.
getPriceExpress
()).
compareTo
(
orderVo
.
getPriceActual
())
>=
0
)
{
backOrder
.
setRealBackPrice
(
orderSkuVo
.
getSkuPriceActual
().
add
(
orderVo
.
getPriceExpress
()));
backOrder
.
setRealBackPrice
(
orderSkuVo
.
getSkuPriceActual
().
add
(
orderVo
.
getPriceExpress
()));
...
@@ -257,7 +263,7 @@ public class GoblinOrderAppServiceImpl implements IGoblinOrderAppService {
...
@@ -257,7 +263,7 @@ public class GoblinOrderAppServiceImpl implements IGoblinOrderAppService {
backOrder
.
setRealBackPrice
(
orderSkuVo
.
getSkuPriceActual
());
backOrder
.
setRealBackPrice
(
orderSkuVo
.
getSkuPriceActual
());
backOrder
.
setBackPriceExpress
(
BigDecimal
.
ZERO
);
backOrder
.
setBackPriceExpress
(
BigDecimal
.
ZERO
);
}
}
}
else
{
}
else
{
backOrder
.
setRealBackPrice
(
orderVo
.
getPriceActual
());
backOrder
.
setRealBackPrice
(
orderVo
.
getPriceActual
());
backOrder
.
setBackPriceExpress
(
orderVo
.
getPriceExpress
());
backOrder
.
setBackPriceExpress
(
orderVo
.
getPriceExpress
());
}
}
...
@@ -304,8 +310,8 @@ public class GoblinOrderAppServiceImpl implements IGoblinOrderAppService {
...
@@ -304,8 +310,8 @@ public class GoblinOrderAppServiceImpl implements IGoblinOrderAppService {
orderSkuVo
.
getOrderSkuId
(),
now
,
now
orderSkuVo
.
getOrderSkuId
(),
now
,
now
});
});
}
}
}
else
if
(
orderVo
.
getStatus
()
==
GoblinStatusConst
.
Status
.
ORDER_STATUS_4
.
getValue
()
&&
param
.
getOrderSkuId
()
!=
null
)
{
}
else
if
(
orderVo
.
getStatus
()
==
GoblinStatusConst
.
Status
.
ORDER_STATUS_4
.
getValue
())
{
if
(
param
.
getOrderSkuId
()!=
null
)
{
if
(
param
.
getOrderSkuId
()
!=
null
)
{
GoblinOrderSkuVo
orderSkuVo
=
redisUtils
.
getGoblinOrderSkuVo
(
param
.
getOrderSkuId
());
GoblinOrderSkuVo
orderSkuVo
=
redisUtils
.
getGoblinOrderSkuVo
(
param
.
getOrderSkuId
());
//订单款式状态修改
//订单款式状态修改
orderSkuVo
.
setStatus
(
GoblinStatusConst
.
Status
.
ORDER_STATUS_61
.
getValue
());
orderSkuVo
.
setStatus
(
GoblinStatusConst
.
Status
.
ORDER_STATUS_61
.
getValue
());
...
@@ -329,7 +335,7 @@ public class GoblinOrderAppServiceImpl implements IGoblinOrderAppService {
...
@@ -329,7 +335,7 @@ public class GoblinOrderAppServiceImpl implements IGoblinOrderAppService {
orderSkuVo
.
getStatus
(),
now
,
orderSkuVo
.
getStatus
(),
now
,
orderSkuVo
.
getOrderSkuId
(),
now
,
now
orderSkuVo
.
getOrderSkuId
(),
now
,
now
});
});
}
else
{
}
else
{
for
(
String
orderSkuId
:
orderVo
.
getOrderSkuVoIds
())
{
for
(
String
orderSkuId
:
orderVo
.
getOrderSkuVoIds
())
{
//订单款式状态修改
//订单款式状态修改
GoblinOrderSkuVo
orderSkuVo
=
redisUtils
.
getGoblinOrderSkuVo
(
orderSkuId
);
GoblinOrderSkuVo
orderSkuVo
=
redisUtils
.
getGoblinOrderSkuVo
(
orderSkuId
);
...
...
liquidnet-bus-service/liquidnet-service-goblin/liquidnet-service-goblin-impl/src/main/java/com/liquidnet/service/goblin/service/impl/GoblinOrderServiceImpl.java
View file @
a83bbd26
...
@@ -881,6 +881,7 @@ public class GoblinOrderServiceImpl implements IGoblinOrderService {
...
@@ -881,6 +881,7 @@ public class GoblinOrderServiceImpl implements IGoblinOrderService {
String
pre
=
GoblinStatusConst
.
MarketPreStatus
.
getPre
(
orderSkuVo
.
getSkuId
());
String
pre
=
GoblinStatusConst
.
MarketPreStatus
.
getPre
(
orderSkuVo
.
getSkuId
());
String
skuId
=
orderSkuVo
.
getSkuId
();
String
skuId
=
orderSkuVo
.
getSkuId
();
redisUtils
.
incrSkuStock
(
pre
,
skuId
,
orderSkuVo
.
getNum
());
redisUtils
.
incrSkuStock
(
pre
,
skuId
,
orderSkuVo
.
getNum
());
redisUtils
.
decrSkuCountByUid
(
orderVo
.
getUserId
(),
skuId
,
orderSkuVo
.
getNum
());
}
}
redisUtils
.
setGoblinOrderSku
(
backOrderSkuVo
.
getOrderSkuId
(),
orderSkuVo
);
redisUtils
.
setGoblinOrderSku
(
backOrderSkuVo
.
getOrderSkuId
(),
orderSkuVo
);
mongoUtils
.
updateGoblinOrderSkuVo
(
backOrderSkuVo
.
getOrderSkuId
(),
orderSkuVo
);
mongoUtils
.
updateGoblinOrderSkuVo
(
backOrderSkuVo
.
getOrderSkuId
(),
orderSkuVo
);
...
...
liquidnet-bus-service/liquidnet-service-goblin/liquidnet-service-goblin-impl/src/main/java/com/liquidnet/service/goblin/service/impl/manage/GoblinStoreOrderServiceImpl.java
View file @
a83bbd26
...
@@ -182,6 +182,7 @@ public class GoblinStoreOrderServiceImpl implements IGoblinStoreOrderService {
...
@@ -182,6 +182,7 @@ public class GoblinStoreOrderServiceImpl implements IGoblinStoreOrderService {
orderSkuVo
.
setStatus
(
GoblinStatusConst
.
Status
.
ORDER_STATUS_5
.
getValue
());
orderSkuVo
.
setStatus
(
GoblinStatusConst
.
Status
.
ORDER_STATUS_5
.
getValue
());
//redis
//redis
redisUtils
.
setGoblinOrderSku
(
orderSkuId
,
orderSkuVo
);
redisUtils
.
setGoblinOrderSku
(
orderSkuId
,
orderSkuVo
);
redisUtils
.
decrSkuCountByUid
(
orderVo
.
getUserId
(),
orderSkuVo
.
getSkuId
(),
orderSkuVo
.
getNum
());
//mongo
//mongo
mongoUtils
.
updateGoblinOrderSkuVo
(
orderSkuId
,
orderSkuVo
);
mongoUtils
.
updateGoblinOrderSkuVo
(
orderSkuId
,
orderSkuVo
);
//mysql
//mysql
...
...
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