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
afdc425d
Commit
afdc425d
authored
Jul 31, 2024
by
332784038@qq.com
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
合包装箱业务对非预装订单被合包装箱进行拦截
parent
031263d8
Changes
4
Hide whitespace changes
Inline
Side-by-side
Showing
4 changed files
with
15 additions
and
7 deletions
+15
-7
OrderBusinessServiceImpl.java
...le/order/service/order/impl/OrderBusinessServiceImpl.java
+1
-1
BoxPkgOrderServiceImpl.java
.../shipment/service/boxPkgOrder/BoxPkgOrderServiceImpl.java
+12
-4
messages_en.properties
yudao-server/src/main/resources/i18n/messages_en.properties
+1
-1
messages_zh.properties
yudao-server/src/main/resources/i18n/messages_zh.properties
+1
-1
No files found.
yudao-module-order/yudao-module-order-core/src/main/java/cn/iocoder/yudao/module/order/service/order/impl/OrderBusinessServiceImpl.java
View file @
afdc425d
...
...
@@ -2898,7 +2898,7 @@ public class OrderBusinessServiceImpl extends AbstractService<OrderMapper, Order
orderItemDO
,
null
,
OrderExceptionEnum
.
ORDER_NO_QUOTE_EXCEPTION
,
String
.
format
(
"订单【%s】中的商品【%s】未报价
6
"
,
String
.
format
(
"订单【%s】中的商品【%s】未报价"
,
orderDO
.
getOrderNo
(),
orderItemDO
.
getProdTitleZh
()),
String
.
format
(
"The goods 【%s】 in the order 【%s】 are not quoted"
,
...
...
yudao-module-shipment/yudao-module-shipment-core/src/main/java/cn/iocoder/yudao/module/shipment/service/boxPkgOrder/BoxPkgOrderServiceImpl.java
View file @
afdc425d
...
...
@@ -45,8 +45,7 @@ import java.util.stream.Collectors;
import
java.util.stream.Stream
;
import
static
cn
.
iocoder
.
yudao
.
framework
.
common
.
exception
.
util
.
ServiceExceptionUtil
.
exception
;
import
static
cn
.
iocoder
.
yudao
.
module
.
order
.
enums
.
ErrorCodeConstants
.
ORDER_IS_PRE_INSTALLED
;
import
static
cn
.
iocoder
.
yudao
.
module
.
order
.
enums
.
ErrorCodeConstants
.
ORDER_NOT_EXISTS
;
import
static
cn
.
iocoder
.
yudao
.
module
.
order
.
enums
.
ErrorCodeConstants
.*;
import
static
cn
.
iocoder
.
yudao
.
module
.
shipment
.
enums
.
ErrorCodeConstants
.*;
/**
...
...
@@ -226,7 +225,15 @@ public class BoxPkgOrderServiceImpl extends AbstractService<BoxPkgOrderMapper, B
private
void
create
(
BoxPkgOrderCreateReqVO
createReqVO
)
{
checkMergePkgStatus
(
createReqVO
.
getPkgId
());
BoxDO
boxDO
=
checkMergePkgStatus
(
createReqVO
.
getPkgId
());
// 这里添加合包装箱时,需要检查订单是否为该出货单下的预装订单
long
count
=
boxPreloadGoodsMapper
.
selectCount
(
new
LambdaQueryWrapper
<
BoxPreloadGoodsDO
>()
.
eq
(
BoxPreloadGoodsDO:
:
getOrderId
,
createReqVO
.
getOrderId
())
.
eq
(
BoxPreloadGoodsDO:
:
getShipmentId
,
boxDO
.
getId
()));
if
(
count
==
0
){
// 订单未预装,不能合包
throw
exception
(
ORDER_IS_NOT_PRE_INSTALLED
);
}
List
<
OrderItemDO
>
orderItemDOS
=
orderItemService
.
selectList
(
OrderItemDO:
:
getOrderId
,
createReqVO
.
getOrderId
());
orderItemDOS
.
stream
().
forEach
(
item
->
{
// 插入
...
...
@@ -359,11 +366,12 @@ public class BoxPkgOrderServiceImpl extends AbstractService<BoxPkgOrderMapper, B
return
map
;
}
private
void
checkMergePkgStatus
(
Long
pkgId
)
{
private
BoxDO
checkMergePkgStatus
(
Long
pkgId
)
{
BoxMergePkgDO
boxMergePkgDO
=
boxMergePkgService
.
selectOne
(
BoxMergePkgDO:
:
getId
,
pkgId
);
BoxDO
box
=
boxService
.
getBox
(
boxMergePkgDO
.
getShipmentId
());
if
(
box
.
getAirShipmentStatus
()
!=
AirShipmentStatusEnum
.
UNSHIPMENT
.
getStatus
())
{
throw
exception
(
MERGE_PKG_IS_FINISH
);
}
return
box
;
}
}
yudao-server/src/main/resources/i18n/messages_en.properties
View file @
afdc425d
...
...
@@ -998,4 +998,4 @@ order.already.in.merge.pkg=The order has been placed under the packaging box
customer.is.new.or.old.no.change
=
customer current business type is {}, it's no change
order.is.pre.installed
=
Order pre installed
customer.delay.approval.times.more.then.one
=
delay approval times more then one
order.is.not.pre.installed
=
Order not pre installed, unable to package together
yudao-server/src/main/resources/i18n/messages_zh.properties
View file @
afdc425d
...
...
@@ -1001,4 +1001,4 @@ case.num.in.merge.pkg=\u6B64\u7BB1\u5DF2\u88AB\u5408\u5305\uFF0C\u8BF7\u626B\u63
order.already.in.merge.pkg
=
\u
8BA2
\u5355\u
5DF2
\u5728\u5408\u5305\u
7BB1
\u
4E0B
customer.is.new.or.old.no.change
=
\u
5BA2
\u6237\u
5F53
\u
524D
\u
4E1A
\u
7EE9
\u
7C7B
\u
578B
\u
662F{}
\u
5BA2
\u6237\u
FF0C
\u
4E0D
\u9700\u8981\u
66F4
\u
65B0
order.is.pre.installed
=
\u
8BA2
\u5355\u
5DF2
\u9884\u
88C5
order.is.not.pre.installed
=
\u
8
BA2
\u5355\u
672A
\u
88C5
\u
7BB1
\u
FF0C
\u
4E0D
\u
80FD
\u5408\u5305
order.is.not.pre.installed
=
\u
8
ba2
\u5355\u
672a
\u9884\u
88c5
\u
ff0c
\u
4e0d
\u
80fd
\u5408\u5305
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