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
2305568b
Commit
2305568b
authored
Jan 05, 2021
by
yu.sun
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
sunyu::update::fix bug about productGroupList add Material
parent
37c0fe31
Hide whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
12 additions
and
12 deletions
+12
-12
shopping-cart-application-service/src/main/java/cn/freemud/adapter/ShoppingCartConvertAdapter.java
+12
-12
No files found.
shopping-cart-application-service/src/main/java/cn/freemud/adapter/ShoppingCartConvertAdapter.java
View file @
2305568b
...
@@ -794,18 +794,18 @@ public class ShoppingCartConvertAdapter {
...
@@ -794,18 +794,18 @@ public class ShoppingCartConvertAdapter {
List
<
com
.
freemud
.
sdk
.
api
.
assortment
.
shoppingcart
.
domain
.
CartGoods
.
MaterialGoods
>
productMaterialList
=
new
ArrayList
<>();
List
<
com
.
freemud
.
sdk
.
api
.
assortment
.
shoppingcart
.
domain
.
CartGoods
.
MaterialGoods
>
productMaterialList
=
new
ArrayList
<>();
Long
materialAmount
=
0L
;
Long
materialAmount
=
0L
;
if
(
CollectionUtils
.
isNotEmpty
(
materialList
)){
if
(
CollectionUtils
.
isNotEmpty
(
materialList
)){
for
(
ProductTypeBeanDTO
.
ProductGroupType
.
GroupDetailType
detailType
:
materialList
)
{
for
(
com
.
freemud
.
sdk
.
api
.
assortment
.
shoppingcart
.
domain
.
CartGoods
.
MaterialGoods
productMaterial
:
comboxGoods
.
getProductMaterialList
()
)
{
com
.
freemud
.
sdk
.
api
.
assortment
.
shoppingcart
.
domain
.
CartGoods
.
MaterialGoods
materialGoods
=
new
com
.
freemud
.
sdk
.
api
.
assortment
.
shoppingcart
.
domain
.
CartGoods
.
MaterialGoods
();
for
(
ProductTypeBeanDTO
.
ProductGroupType
.
GroupDetailType
detailType
:
materialList
)
{
materialGoods
.
setCustomerCode
(
StringUtils
.
isNotEmpty
(
detailType
.
getCustomerCode
())
?
detailType
.
getCustomerCode
()
:
""
);
// productMaterial
.setCustomerCode(StringUtils.isNotEmpty(detailType.getCustomerCode()) ? detailType.getCustomerCode() : "");
materialGoods
.
setAmount
(
null
!=
detailType
.
getMarkUpPrice
()
?
detailType
.
getMarkUpPrice
().
longValue
()
:
0
);
productMaterial
.
setAmount
(
null
!=
detailType
.
getMarkUpPrice
()
?
detailType
.
getMarkUpPrice
().
longValue
()
:
0
);
materialGoods
.
setFinalPrice
(
null
!=
detailType
.
getProductFinalPrice
()
?
detailType
.
getProductFinalPrice
().
longValue
()
:
0
);
productMaterial
.
setFinalPrice
(
null
!=
detailType
.
getProductFinalPrice
()
?
detailType
.
getProductFinalPrice
().
longValue
()
:
0
);
materialGoods
.
setSpuName
(
StringUtils
.
isNotEmpty
(
detailType
.
getProductName
())
?
detailType
.
getProductName
()
:
""
);
productMaterial
.
setSpuName
(
StringUtils
.
isNotEmpty
(
detailType
.
getProductName
())
?
detailType
.
getProductName
()
:
""
);
materialGoods
.
setSpuId
(
StringUtils
.
isNotEmpty
(
detailType
.
getProductId
())
?
detailType
.
getProductId
()
:
""
);
productMaterial
.
setSpuId
(
StringUtils
.
isNotEmpty
(
detailType
.
getProductId
())
?
detailType
.
getProductId
()
:
""
);
materialGoods
.
setOriginalPrice
(
null
!=
detailType
.
getProductFinalPrice
()
?
detailType
.
getProductFinalPrice
().
longValue
()
:
0
);
productMaterial
.
setOriginalPrice
(
null
!=
detailType
.
getProductFinalPrice
()
?
detailType
.
getProductFinalPrice
().
longValue
()
:
0
);
materialGoods
.
setOriginalAmount
(
null
!=
detailType
.
getProductFinalPrice
()
?
detailType
.
getProductFinalPrice
().
longValue
()
*
comboxGoods
.
getQty
()
:
0
);
productMaterial
.
setOriginalAmount
(
null
!=
detailType
.
getProductFinalPrice
()
?
detailType
.
getProductFinalPrice
().
longValue
()
*
comboxGoods
.
getQty
()
:
0
);
productMaterialList
.
add
(
productMaterial
);
productMaterialList
.
add
(
materialGoods
);
materialAmount
+=
detailType
.
getProductFinalPrice
().
longValue
()
*
comboxGoods
.
getQty
(
);
materialAmount
+=
detailType
.
getProductFinalPrice
().
longValue
()
*
comboxGoods
.
getQty
();
}
}
}
}
}
comboxGoods
.
setMaterialAmount
(
materialAmount
);
comboxGoods
.
setMaterialAmount
(
materialAmount
);
...
...
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