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
8d659955
Commit
8d659955
authored
Dec 03, 2024
by
zhengyi
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
订单有收货人时,收货人必须是国外号码
parent
0781adb6
Changes
4
Hide whitespace changes
Inline
Side-by-side
Showing
4 changed files
with
31 additions
and
29 deletions
+31
-29
OrderServiceImpl.java
...dao/module/order/service/order/impl/OrderServiceImpl.java
+21
-15
OfferServiceImpl.java
...udao/module/sale/service/offer/impl/OfferServiceImpl.java
+8
-12
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/OrderServiceImpl.java
View file @
8d659955
...
...
@@ -216,8 +216,7 @@ public class OrderServiceImpl extends AbstractService<OrderMapper, OrderDO> impl
dto
->
"create_order_phone_limit"
.
equals
(
dto
.
getLabel
())).
findFirst
().
orElse
(
null
);
if
(
createReqVO
.
getHasConsignee
()
&&
Objects
.
nonNull
(
createReqVO
.
getIsCargoControl
())
&&
createReqVO
.
getIsCargoControl
()
&&
if
(
createReqVO
.
getHasConsignee
()
&&
Objects
.
nonNull
(
dictDataRespDTO
)
&&
StringUtils
.
equals
(
dictDataRespDTO
.
getValue
(),
"11"
)
&&
StringUtils
.
isNotBlank
(
createReqVO
.
getCountryCode
())
...
...
@@ -656,8 +655,9 @@ public class OrderServiceImpl extends AbstractService<OrderMapper, OrderDO> impl
if
(
StringUtils
.
isBlank
(
orderConsigneeDO
.
getName
()))
{
throw
exception
(
ORDER_CONSIGNEE_NAME_NOT_COMPLETE
);
}
if
(
createReqVO
.
getHasConsignee
()
&&
Objects
.
nonNull
(
createReqVO
.
getIsCargoControl
())
&&
createReqVO
.
getIsCargoControl
()
&&
StringUtils
.
isNotBlank
(
orderConsigneeDO
.
getCountryCode
())
&&
Objects
.
nonNull
(
dictDataRespDTO
)
&&
StringUtils
.
equals
(
dictDataRespDTO
.
getValue
(),
"11"
)
&&
StringUtils
.
equals
(
"86"
,
orderConsigneeDO
.
getCountryCode
()))
{
if
(
createReqVO
.
getHasConsignee
()
&&
StringUtils
.
isNotBlank
(
orderConsigneeDO
.
getCountryCode
())
&&
Objects
.
nonNull
(
dictDataRespDTO
)
&&
StringUtils
.
equals
(
dictDataRespDTO
.
getValue
(),
"11"
)
&&
StringUtils
.
equals
(
"86"
,
orderConsigneeDO
.
getCountryCode
()))
{
throw
exception
(
CONSIGNEE_PHONE_IS_EXTERNAL
);
}
try
{
...
...
@@ -940,8 +940,9 @@ public class OrderServiceImpl extends AbstractService<OrderMapper, OrderDO> impl
throw
exception
(
ORDER_CONSIGNEE_PHONE_INCORRECT_FORMAT
);
}
}
if
(
createReqVO
.
getHasConsignee
()
&&
Objects
.
nonNull
(
createReqVO
.
getIsCargoControl
())
&&
createReqVO
.
getIsCargoControl
()
&&
StringUtils
.
isNotBlank
(
orderConsigneeDO
.
getCountryCode
())
&&
Objects
.
nonNull
(
dictDataRespDTO
)
&&
StringUtils
.
equals
(
dictDataRespDTO
.
getValue
(),
"11"
)
&&
StringUtils
.
equals
(
"86"
,
orderConsigneeDO
.
getCountryCode
()))
{
if
(
createReqVO
.
getHasConsignee
()
&&
StringUtils
.
isNotBlank
(
orderConsigneeDO
.
getCountryCode
())
&&
Objects
.
nonNull
(
dictDataRespDTO
)
&&
StringUtils
.
equals
(
dictDataRespDTO
.
getValue
(),
"11"
)
&&
StringUtils
.
equals
(
"86"
,
orderConsigneeDO
.
getCountryCode
()))
{
throw
exception
(
CONSIGNEE_PHONE_IS_EXTERNAL
);
}
if
(
StringUtils
.
isNotBlank
(
createReqVO
.
getConsigneeName
()))
{
...
...
@@ -1516,9 +1517,11 @@ public class OrderServiceImpl extends AbstractService<OrderMapper, OrderDO> impl
List
<
DictDataRespDTO
>
dictList
=
dictDataApi
.
getDictDatas
(
"part_function_switch"
);
// 智慧预装功能开关
DictDataRespDTO
dictDataRespDTO
=
dictList
.
stream
().
filter
(
dto
->
"create_order_phone_limit"
.
equals
(
dto
.
getLabel
())).
findFirst
().
orElse
(
null
);
if
(
updateReqVO
.
getHasConsignee
()
&&
Objects
.
nonNull
(
updateReqVO
.
getIsCargoControl
())
&&
updateReqVO
.
getIsCargoControl
()
&&
Objects
.
nonNull
(
dictDataRespDTO
)
&&
StringUtils
.
equals
(
dictDataRespDTO
.
getValue
(),
"11"
)
&&
StringUtils
.
isNotBlank
(
updateReqVO
.
getCountryCode
())
&&
StringUtils
.
equals
(
"86"
,
updateReqVO
.
getCountryCode
()))
{
if
(
updateReqVO
.
getHasConsignee
()
&&
Objects
.
nonNull
(
dictDataRespDTO
)
&&
StringUtils
.
equals
(
dictDataRespDTO
.
getValue
(),
"11"
)
&&
StringUtils
.
isNotBlank
(
updateReqVO
.
getCountryCode
())
&&
StringUtils
.
equals
(
"86"
,
updateReqVO
.
getCountryCode
()))
{
throw
exception
(
CONSIGNEE_PHONE_IS_EXTERNAL
);
}
OrderDO
updateObj
=
OrderConvert
.
INSTANCE
.
convert
(
updateReqVO
);
...
...
@@ -2729,8 +2732,9 @@ public class OrderServiceImpl extends AbstractService<OrderMapper, OrderDO> impl
if
(!
Objects
.
equals
(
orderConsigneeBackVO
.
getCustomerContactsId
(),
consigneeContactsDO
.
getId
()))
{
// 收货人电话
if
(!
StringUtils
.
equals
(
orderConsigneeBackVO
.
getPhone
(),
consigneeContactsDO
.
getPhoneNew
())
||
!
StringUtils
.
equals
(
orderConsigneeBackVO
.
getCountryCode
(),
consigneeContactsDO
.
getAreaCode
()))
{
if
(
updateReqVO
.
getHasConsignee
()
&&
Objects
.
nonNull
(
updateReqVO
.
getIsCargoControl
())
&&
updateReqVO
.
getIsCargoControl
()
&&
StringUtils
.
isNotBlank
(
consigneeContactsDO
.
getAreaCode
())
&&
Objects
.
nonNull
(
dictDataRespDTO
)
&&
StringUtils
.
equals
(
dictDataRespDTO
.
getValue
(),
"11"
)
&&
StringUtils
.
equals
(
"86"
,
consigneeContactsDO
.
getAreaCode
()))
{
if
(
updateReqVO
.
getHasConsignee
()
&&
StringUtils
.
isNotBlank
(
consigneeContactsDO
.
getAreaCode
())
&&
Objects
.
nonNull
(
dictDataRespDTO
)
&&
StringUtils
.
equals
(
dictDataRespDTO
.
getValue
(),
"11"
)
&&
StringUtils
.
equals
(
"86"
,
consigneeContactsDO
.
getAreaCode
()))
{
throw
exception
(
CONSIGNEE_PHONE_IS_EXTERNAL
);
}
infoVO
=
new
ApplyInfoVO
();
...
...
@@ -3311,8 +3315,9 @@ public class OrderServiceImpl extends AbstractService<OrderMapper, OrderDO> impl
if
(
StringUtils
.
isBlank
(
orderConsigneeDO
.
getName
()))
{
throw
exception
(
ORDER_CONSIGNEE_NAME_NOT_COMPLETE
);
}
if
(
updateReqVO
.
getHasConsignee
()
&&
Objects
.
nonNull
(
updateReqVO
.
getIsCargoControl
())
&&
updateReqVO
.
getIsCargoControl
()
&&
StringUtils
.
isNotBlank
(
orderConsigneeDO
.
getCountryCode
())
&&
Objects
.
nonNull
(
dictDataRespDTO
)
&&
StringUtils
.
equals
(
"11"
,
dictDataRespDTO
.
getValue
())
&&
StringUtils
.
equals
(
"86"
,
orderConsigneeDO
.
getCountryCode
()))
{
if
(
updateReqVO
.
getHasConsignee
()
&&
StringUtils
.
isNotBlank
(
orderConsigneeDO
.
getCountryCode
())
&&
Objects
.
nonNull
(
dictDataRespDTO
)
&&
StringUtils
.
equals
(
"11"
,
dictDataRespDTO
.
getValue
())
&&
StringUtils
.
equals
(
"86"
,
orderConsigneeDO
.
getCountryCode
()))
{
throw
exception
(
CONSIGNEE_PHONE_IS_EXTERNAL
);
}
try
{
...
...
@@ -3562,8 +3567,9 @@ public class OrderServiceImpl extends AbstractService<OrderMapper, OrderDO> impl
orderConsigneeDO
.
setEmail
(
updateReqVO
.
getConsigneeEmail
());
orderConsigneeDO
.
setPhone
(
updateReqVO
.
getConsigneePhone
());
}
if
(
updateReqVO
.
getHasConsignee
()
&&
Objects
.
nonNull
(
updateReqVO
.
getIsCargoControl
())
&&
updateReqVO
.
getIsCargoControl
()
&&
StringUtils
.
isNotBlank
(
orderConsigneeDO
.
getCountryCode
())
&&
Objects
.
nonNull
(
dictDataRespDTO
)
&&
StringUtils
.
equals
(
"11"
,
dictDataRespDTO
.
getValue
())
&&
StringUtils
.
equals
(
"86"
,
orderConsigneeDO
.
getCountryCode
()))
{
if
(
updateReqVO
.
getHasConsignee
()
&&
StringUtils
.
isNotBlank
(
orderConsigneeDO
.
getCountryCode
())
&&
Objects
.
nonNull
(
dictDataRespDTO
)
&&
StringUtils
.
equals
(
"11"
,
dictDataRespDTO
.
getValue
())
&&
StringUtils
.
equals
(
"86"
,
orderConsigneeDO
.
getCountryCode
()))
{
throw
exception
(
CONSIGNEE_PHONE_IS_EXTERNAL
);
}
orderConsigneeDO
.
setHarvestMethod
(
updateReqVO
.
getHarvestMethod
());
// 收货方式
...
...
yudao-module-sale/yudao-module-sale-core/src/main/java/cn/iocoder/yudao/module/sale/service/offer/impl/OfferServiceImpl.java
View file @
8d659955
...
...
@@ -188,16 +188,14 @@ public class OfferServiceImpl extends AbstractService<OfferMapper, OfferDO> impl
}
}
if
(
Objects
.
nonNull
(
createReqVO
.
getConsigneeId
())
&&
createReqVO
.
getConsigneeId
()
>
0
)
{
if
(
Objects
.
nonNull
(
createReqVO
.
getControl
())
&&
createReqVO
.
getControl
())
{
// 获取功能开关
List
<
DictDataRespDTO
>
dictList
=
dictDataApi
.
getDictDatas
(
"part_function_switch"
);
// 智慧预装功能开关
DictDataRespDTO
dictDataRespDTO
=
dictList
.
stream
().
filter
(
dto
->
"create_order_phone_limit"
.
equals
(
dto
.
getLabel
())).
findFirst
().
orElse
(
null
);
CustomerContactsDO
consigneeContactsDO
=
customerContactsService
.
getCustomerContacts
(
createReqVO
.
getConsigneeId
());
if
(
Objects
.
nonNull
(
consigneeContactsDO
))
{
if
(
Objects
.
nonNull
(
dictDataRespDTO
)
&&
StringUtils
.
equals
(
dictDataRespDTO
.
getValue
(),
"11"
)
&&
StringUtils
.
isNotBlank
(
consigneeContactsDO
.
getAreaCode
())
&&
StringUtils
.
equals
(
"86"
,
consigneeContactsDO
.
getAreaCode
()))
{
throw
exception
(
CONSIGNEE_PHONE_IS_EXTERNAL
);
}
// 获取功能开关
List
<
DictDataRespDTO
>
dictList
=
dictDataApi
.
getDictDatas
(
"part_function_switch"
);
// 智慧预装功能开关
DictDataRespDTO
dictDataRespDTO
=
dictList
.
stream
().
filter
(
dto
->
"create_order_phone_limit"
.
equals
(
dto
.
getLabel
())).
findFirst
().
orElse
(
null
);
CustomerContactsDO
consigneeContactsDO
=
customerContactsService
.
getCustomerContacts
(
createReqVO
.
getConsigneeId
());
if
(
Objects
.
nonNull
(
consigneeContactsDO
))
{
if
(
Objects
.
nonNull
(
dictDataRespDTO
)
&&
StringUtils
.
equals
(
dictDataRespDTO
.
getValue
(),
"11"
)
&&
StringUtils
.
isNotBlank
(
consigneeContactsDO
.
getAreaCode
())
&&
StringUtils
.
equals
(
"86"
,
consigneeContactsDO
.
getAreaCode
()))
{
throw
exception
(
CONSIGNEE_PHONE_IS_EXTERNAL
);
}
}
}
...
...
@@ -516,7 +514,6 @@ public class OfferServiceImpl extends AbstractService<OfferMapper, OfferDO> impl
}
}
if
(
Objects
.
nonNull
(
updateReqVO
.
getConsigneeId
())
&&
updateReqVO
.
getConsigneeId
()
>
0
)
{
if
(
Objects
.
nonNull
(
updateReqVO
.
getControl
())
&&
updateReqVO
.
getControl
())
{
// 获取功能开关
List
<
DictDataRespDTO
>
dictList
=
dictDataApi
.
getDictDatas
(
"part_function_switch"
);
// 智慧预装功能开关
...
...
@@ -527,7 +524,6 @@ public class OfferServiceImpl extends AbstractService<OfferMapper, OfferDO> impl
throw
exception
(
CONSIGNEE_PHONE_IS_EXTERNAL
);
}
}
}
}
String
updater
=
String
.
valueOf
(
SecurityFrameworkUtils
.
getLoginUserId
());
// 校验存在
...
...
yudao-server/src/main/resources/i18n/messages_en.properties
View file @
8d659955
...
...
@@ -664,7 +664,7 @@ param.customer.service.not=The customer or account manager is empty
order.warehouse.adjustment.status.not.allowed.warehouse.in
=
Non warehouse adjustment operations are not allowed during order warehouse adjustment
modify.approval.not.add.prod
=
Cannot add a new product after modification approval
modify.approval.not.update.warehouse.in
=
Cannot update or delete warehouse in after modification approval
consignee.phone.is.external
=
For control orders, the recipient's mobile phone number must be from overseas
consignee.phone.is.external
=
The recipient's mobile phone number must be from abroad
already.picked.up
=
The order has picked up
lading.not.make
=
bill of lading have not make yet
file.not.upload
=
The file has not uploaded
...
...
yudao-server/src/main/resources/i18n/messages_zh.properties
View file @
8d659955
...
...
@@ -672,7 +672,7 @@ already.picked.up=\u8BE5\u8BA2\u5355\u5DF2\u63D0\u8D27
lading.not.make
=
\u
63D0
\u5355\u
672A
\u5236\u
4F5C
modify.approval.not.add.prod
=
\u
4FEE
\u6539\u
5BA1
\u6279\u
4E0D
\u
80FD
\u
6DFB
\u
52A0
\u
65B0
\u7684\u5546\u
54C1
modify.approval.not.update.warehouse.in
=
\u5165\u
4ED3
\u
4FEE
\u6539\u
5BA1
\u6279\u
4E2D
\u
4E0D
\u
80FD
\u
4FEE
\u6539\u6216\u5220\u9664\u5165\u
4ED3
\u
7EAA
\u
5F55
consignee.phone.is.external
=
\u
6
3a7
\u
8d27
\u
8ba2
\u5355\u
ff0c
\u6
536\u
8d27
\u
4eba
\u
624b
\u
673a
\u
53f7
\u7801\u
5fc5
\u
987b
\u
662f
\u
56fd
\u5916\u7684
consignee.phone.is.external
=
\u6536\u
8d27
\u
4eba
\u
624b
\u
673a
\u
53f7
\u7801\u
5fc5
\u
987b
\u
662f
\u
56fd
\u5916\u7684
file.not.upload
=
\u
8BE5
\u6587\u
4EF6
\u
672A
\u
4E0A
\u
4F20
your.customer.information.is.incomplete
=
\u
60A8
\u7684\u
5BA2
\u6237\u
4FE1
\u
606F
\u
672A
\u
5B8C
\u5584\u
FF01
\u
8BF7
\u8054\u
7CFB
\u
7BA1
\u7406\u5458\u
FF01
open.sea.customer.cannot.set.air
=
\u
5BA2
\u6237\u3010
{}
\u3011\u5728\u
516C
\u
6D77
\u
4E2D
\u
4E0D
\u
53EF
\u
8BBE
\u
7F6E
\u
662F
\u5426\u
7A7A
\u
8FD0
\u
5BA2
\u6237
...
...
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