Skip to content
GitLab
Menu
Projects
Groups
Snippets
Help
Help
Support
Community forum
Keyboard shortcuts
?
Submit feedback
Contribute to GitLab
Sign in / Register
Toggle navigation
Menu
Open sidebar
wwwanlingxiao
mall
Commits
c8cf97f6
Commit
c8cf97f6
authored
Jul 07, 2023
by
macro
Browse files
下单库存问题修复
parent
0a6717f3
Changes
1
Hide whitespace changes
Inline
Side-by-side
mall-portal/src/main/java/com/macro/mall/portal/service/impl/OmsPortalOrderServiceImpl.java
View file @
c8cf97f6
...
...
@@ -716,7 +716,10 @@ public class OmsPortalOrderServiceImpl implements OmsPortalOrderService {
*/
private
boolean
hasStock
(
List
<
CartPromotionItem
>
cartPromotionItemList
)
{
for
(
CartPromotionItem
cartPromotionItem
:
cartPromotionItemList
)
{
if
(
cartPromotionItem
.
getRealStock
()==
null
||
cartPromotionItem
.
getRealStock
()
<=
0
)
{
if
(
cartPromotionItem
.
getRealStock
()==
null
//判断真实库存是否为空
||
cartPromotionItem
.
getRealStock
()
<=
0
//判断真实库存是否小于0
||
cartPromotionItem
.
getRealStock
()
<
cartPromotionItem
.
getQuantity
())
//判断真实库存是否小于下单的数量
{
return
false
;
}
}
...
...
Write
Preview
Supports
Markdown
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