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
e0042f37
Commit
e0042f37
authored
May 10, 2024
by
liuzeheng
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
截取单号
parent
2784ddb9
Changes
1
Hide whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
18 additions
and
4 deletions
+18
-4
BoxPkgOrderServiceImpl.java
.../shipment/service/boxPkgOrder/BoxPkgOrderServiceImpl.java
+18
-4
No files found.
yudao-module-shipment/yudao-module-shipment-core/src/main/java/cn/iocoder/yudao/module/shipment/service/boxPkgOrder/BoxPkgOrderServiceImpl.java
View file @
e0042f37
...
...
@@ -105,7 +105,7 @@ public class BoxPkgOrderServiceImpl extends AbstractService<BoxPkgOrderMapper, B
String
orderNumber
=
orderNumCode
.
substring
(
0
,
position
);
if
(
orderNumCode
.
contains
(
"A"
)
&&
orderNumCode
.
startsWith
(
"A"
)){
this
.
scanCodeByOrderNo
(
orderNum
ber
,
vo
,
createReqVO
);
this
.
scanCodeByOrderNo
(
orderNum
Code
,
vo
,
createReqVO
);
}
BoxMergePkgDO
boxMergePkgDO
=
boxMergePkgService
.
selectOne
(
new
LambdaQueryWrapper
<
BoxMergePkgDO
>()
...
...
@@ -229,7 +229,9 @@ public class BoxPkgOrderServiceImpl extends AbstractService<BoxPkgOrderMapper, B
return
"success"
;
}
private
String
scanCodeByOrderNo
(
String
orderNumber
,
BoxPkgOrderCreateReqVO
vo
,
BoxPkgOrderScanCodeVO
createReqVO
){
private
String
scanCodeByOrderNo
(
String
orderNumCode
,
BoxPkgOrderCreateReqVO
vo
,
BoxPkgOrderScanCodeVO
createReqVO
){
int
position
=
orderNumCode
.
lastIndexOf
(
"-"
);
String
orderNumber
=
orderNumCode
.
substring
(
0
,
position
);
Long
orderId
=
orderService
.
getOrderIdByOrderNo
(
orderNumber
);
if
(
Objects
.
isNull
(
orderId
)){
throw
exception
(
ORDER_NOT_IN_BOX
);
...
...
@@ -256,8 +258,8 @@ public class BoxPkgOrderServiceImpl extends AbstractService<BoxPkgOrderMapper, B
//找到这个订单所有需要装柜的编号
List
<
String
>
tagList
=
boxOrderCheckInfoService
.
getOrderTagList
(
order
);
List
<
BoxOrderCheckInfoDO
>
boxOrderCheckInfoDOS
=
new
ArrayList
<>();
for
(
int
i
=
0
;
i
<
tagList
.
size
();
i
++)
{
String
tag
=
tagList
.
get
(
i
)
;
if
(
tagList
.
contains
(
orderNumCode
)
)
{
String
tag
=
orderNumCode
;
BoxOrderCheckInfoDO
boxOrderCheckInfoDO
=
new
BoxOrderCheckInfoDO
();
boxOrderCheckInfoDO
.
setOrderId
(
orderId
);
boxOrderCheckInfoDO
.
setPkgId
(
boxMergePkgDO
.
getId
());
...
...
@@ -267,6 +269,18 @@ public class BoxPkgOrderServiceImpl extends AbstractService<BoxPkgOrderMapper, B
boxOrderCheckInfoDO
.
setDeleted
(
false
);
boxOrderCheckInfoDOS
.
add
(
boxOrderCheckInfoDO
);
}
// for (int i = 0; i < tagList.size(); i++) {
// String tag = tagList.get(i);
// BoxOrderCheckInfoDO boxOrderCheckInfoDO = new BoxOrderCheckInfoDO();
// boxOrderCheckInfoDO.setOrderId(orderId);
// boxOrderCheckInfoDO.setPkgId(boxMergePkgDO.getId());
// boxOrderCheckInfoDO.setOrderNumCode(tag);
// boxOrderCheckInfoDO.setShipmentId(createReqVO.getShipmentId());
// boxOrderCheckInfoDO.setType(1);
// boxOrderCheckInfoDO.setDeleted(false);
// boxOrderCheckInfoDOS.add(boxOrderCheckInfoDO);
// }
boxOrderCheckInfoService
.
saveBatch
(
boxOrderCheckInfoDOS
);
}
return
"success"
;
...
...
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