Skip to content
Projects
Groups
Snippets
Help
Loading...
Help
Support
Submit feedback
Contribute to GitLab
Sign in / Register
Toggle navigation
J
jiedao-api-boot-master
Project
Project
Details
Activity
Releases
Cycle Analytics
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Charts
Issues
0
Issues
0
List
Boards
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
lanbaoming
jiedao-api-boot-master
Commits
72a429ff
Commit
72a429ff
authored
May 02, 2024
by
liuzeheng
Browse files
Options
Browse Files
Download
Plain Diff
Merge branch 'dev'
parents
4e2eb335
cc595960
Changes
1
Hide whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
45 additions
and
5 deletions
+45
-5
ProductPriceServiceImpl.java
...product/service/product/impl/ProductPriceServiceImpl.java
+45
-5
No files found.
yudao-module-product/yudao-module-product-core/src/main/java/cn/iocoder/yudao/module/product/service/product/impl/ProductPriceServiceImpl.java
View file @
72a429ff
...
@@ -3329,8 +3329,11 @@ public class ProductPriceServiceImpl extends AbstractService<ProductPriceMapper,
...
@@ -3329,8 +3329,11 @@ public class ProductPriceServiceImpl extends AbstractService<ProductPriceMapper,
ProductPriceStepDO
clear
=
new
ProductPriceStepDO
();
ProductPriceStepDO
clear
=
new
ProductPriceStepDO
();
if
(
createReqVO
.
getPriceType
()==
1
){
if
(
createReqVO
.
getPriceType
()==
1
){
if
(
CollectionUtil
.
isNotEmpty
(
respVO
.
getFullPricePackagingList
())){
if
(
CollectionUtil
.
isNotEmpty
(
respVO
.
getFullPricePackagingList
())){
List
<
ProductPriceStepPackagingDO
>
specialDO
List
=
new
ArrayList
<>();
List
<
ProductPriceStepPackagingDO
>
packaging
List
=
new
ArrayList
<>();
respVO
.
getFullPricePackagingList
().
forEach
(
pack
->{
respVO
.
getFullPricePackagingList
().
forEach
(
pack
->{
createReqVO
.
setFreightPriceStepList
(
respVO
.
getFreightPriceStepList
());
ProductPriceStepDO
packagingDO
=
new
ProductPriceStepDO
()
;
ProductPriceStepDO
packagingDO
=
new
ProductPriceStepDO
()
;
BeanUtils
.
copyProperties
(
pack
,
packagingDO
);
BeanUtils
.
copyProperties
(
pack
,
packagingDO
);
packagingDO
.
setId
(
null
);
packagingDO
.
setId
(
null
);
...
@@ -3340,12 +3343,28 @@ public class ProductPriceServiceImpl extends AbstractService<ProductPriceMapper,
...
@@ -3340,12 +3343,28 @@ public class ProductPriceServiceImpl extends AbstractService<ProductPriceMapper,
// packagingDO.setTransportPrice(pack.getPackagingPrice());
// packagingDO.setTransportPrice(pack.getPackagingPrice());
// packagingDO.setTransportPriceUnit(pack.getPackagingPriceUnit());
// packagingDO.setTransportPriceUnit(pack.getPackagingPriceUnit());
// packagingDO.setTransportVolumeUnit(pack.getPackagingVolumeUnit());
// packagingDO.setTransportVolumeUnit(pack.getPackagingVolumeUnit());
packagingDO
.
setAllPrice
(
pack
.
getPackagingPrice
());
packagingDO
.
setAllPrice
(
respVO
.
getAllPrice
());
packagingDO
.
setAllPriceUnit
(
pack
.
getPackagingPriceUnit
())
;
packagingDO
.
setAllPriceUnit
(
respVO
.
getAllPriceUnit
())
;
packagingDO
.
setAllVolumeUnit
(
pack
.
getPackagingVolumeUnit
());
packagingDO
.
setAllVolumeUnit
(
respVO
.
getAllVolumeUnit
());
if
(
CollectionUtil
.
isNotEmpty
(
respVO
.
getSpecialList
())){
List
<
ProductPriceStepSpecialDO
>
specialList
=
new
ArrayList
<>();
respVO
.
getSpecialList
().
forEach
(
sp
->{
ProductPriceStepSpecialDO
specialDO
=
new
ProductPriceStepSpecialDO
();
BeanUtils
.
copyProperties
(
sp
,
specialDO
);
specialDO
.
setId
(
null
);
specialList
.
add
(
specialDO
);
});
packagingDO
.
setSpecialList
(
specialList
);
}
ProductPriceStepPackagingDO
stepPackagingDO
=
new
ProductPriceStepPackagingDO
()
;
BeanUtils
.
copyProperties
(
pack
,
stepPackagingDO
);
packagingList
.
add
(
stepPackagingDO
);
packagingDO
.
setPackagingList
(
packagingList
);
fullPriceStepList
.
add
(
packagingDO
)
;
fullPriceStepList
.
add
(
packagingDO
)
;
});
});
createReqVO
.
setFullPriceStepList
(
fullPriceStepList
);
createReqVO
.
setFullPriceStepList
(
fullPriceStepList
);
}
}
}
else
{
}
else
{
if
(
CollectionUtil
.
isEmpty
(
respVO
.
getFreightPriceStepList
())
){
if
(
CollectionUtil
.
isEmpty
(
respVO
.
getFreightPriceStepList
())
){
...
@@ -3698,6 +3717,28 @@ public class ProductPriceServiceImpl extends AbstractService<ProductPriceMapper,
...
@@ -3698,6 +3717,28 @@ public class ProductPriceServiceImpl extends AbstractService<ProductPriceMapper,
initBasePrice
(
dbItem
,
transportType
);
initBasePrice
(
dbItem
,
transportType
);
insertList1
.
add
(
dbItem
);
insertList1
.
add
(
dbItem
);
}
}
// if(stepItem.getPriceType()==1){
//
// ProductPricePackagingDO pricePackagingDO = new ProductPricePackagingDO() ;
// BeanUtils.copyProperties(stepItem,pricePackagingDO);
// pricePackagingDO.setId(null);
// pricePackagingDO.setProductPriceId(productPriceId) ;
// productPricePackagingDOS.add(pricePackagingDO);
//
// }else {
// if(CollectionUtil.isNotEmpty(stepItem.getPackagingList())){
// stepItem.getPackagingList().forEach(pg->{
// ProductPricePackagingDO pricePackagingDO = new ProductPricePackagingDO() ;
// BeanUtils.copyProperties(pg,pricePackagingDO);
// pricePackagingDO.setId(null);
// pricePackagingDO.setProductPriceId(productPriceId) ;
// pricePackagingDO.setPriceType(stepItem.getPriceType()) ;
// productPricePackagingDOS.add(pricePackagingDO);
//
// });
// }
// }
if
(
CollectionUtil
.
isNotEmpty
(
stepItem
.
getPackagingList
())){
if
(
CollectionUtil
.
isNotEmpty
(
stepItem
.
getPackagingList
())){
stepItem
.
getPackagingList
().
forEach
(
pg
->{
stepItem
.
getPackagingList
().
forEach
(
pg
->{
ProductPricePackagingDO
pricePackagingDO
=
new
ProductPricePackagingDO
()
;
ProductPricePackagingDO
pricePackagingDO
=
new
ProductPricePackagingDO
()
;
...
@@ -3709,7 +3750,6 @@ public class ProductPriceServiceImpl extends AbstractService<ProductPriceMapper,
...
@@ -3709,7 +3750,6 @@ public class ProductPriceServiceImpl extends AbstractService<ProductPriceMapper,
});
});
}
}
}
}
}
}
}
}
...
...
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