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
fe7c746e
Commit
fe7c746e
authored
Jun 27, 2024
by
lanbaoming
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
2024-06-27-2提交
parent
909ce935
Changes
10
Expand all
Show whitespace changes
Inline
Side-by-side
Showing
10 changed files
with
120 additions
and
61 deletions
+120
-61
BpmOrderRetiredWarehouseResultListener.java
...rder/listener/BpmOrderRetiredWarehouseResultListener.java
+4
-2
BpmOrderWarehousingModificationResultListener.java
...stener/BpmOrderWarehousingModificationResultListener.java
+2
-1
CustomerAnalysisImpl.java
...ao/module/delivery/service/Impl/CustomerAnalysisImpl.java
+0
-1
OrderLocationServiceImpl.java
...le/order/service/order/impl/OrderLocationServiceImpl.java
+11
-11
OrderServiceImpl.java
...dao/module/order/service/order/impl/OrderServiceImpl.java
+6
-3
OrderCargoControlPickServiceImpl.java
...derCargoControlPick/OrderCargoControlPickServiceImpl.java
+19
-9
OrderWarehouseInServiceImpl.java
...service/orderWarehouseIn/OrderWarehouseInServiceImpl.java
+62
-25
OrderCargoControlPickController.java
...rderCargoControlPick/OrderCargoControlPickController.java
+4
-2
ProdCostCalculation.java
...r/yudao/module/product/component/ProdCostCalculation.java
+1
-1
SmsCodeServiceImpl.java
...r/yudao/module/system/service/sms/SmsCodeServiceImpl.java
+11
-6
No files found.
yudao-module-bpm/yudao-module-bpm-base/src/main/java/cn/iocoder/yudao/module/bpm/service/order/listener/BpmOrderRetiredWarehouseResultListener.java
View file @
fe7c746e
...
...
@@ -24,8 +24,10 @@ public class BpmOrderRetiredWarehouseResultListener extends BpmProcessInstanceRe
@Override
protected
void
onEvent
(
BpmProcessInstanceResultEvent
event
)
{
log
.
info
(
"---------------------入仓退仓回调-----------------------{},{}"
,
event
.
getBusinessKey
(),
event
.
getResult
());
orderWarehouseInService
.
rollbackApplyCallback
(
event
.
getBusinessKey
(),
event
.
getResult
());
log
.
info
(
"---------------------入仓退仓回调-----------------------{},{}"
,
event
.
getBusinessKey
(),
event
.
getResult
());
orderWarehouseInService
.
rollbackApplyCallback
(
event
.
getBusinessKey
(),
event
.
getResult
());
}
}
yudao-module-bpm/yudao-module-bpm-base/src/main/java/cn/iocoder/yudao/module/bpm/service/order/listener/BpmOrderWarehousingModificationResultListener.java
View file @
fe7c746e
...
...
@@ -30,7 +30,8 @@ public class BpmOrderWarehousingModificationResultListener extends BpmProcessIns
//lanbm 2024-05-31 处理异常
log
.
info
(
"-------------------入仓修改回调-------------------------{},{}"
,
event
.
getBusinessKey
(),
event
.
getResult
());
orderWarehouseInService
.
updateApplyCallback
(
event
.
getBusinessKey
(),
event
.
getResult
());
orderWarehouseInService
.
updateApplyCallback
(
event
.
getBusinessKey
(),
event
.
getResult
());
}
}
yudao-module-delivery/yudao-module-delivery-rest/src/main/java/cn/iocoder/yudao/module/delivery/service/Impl/CustomerAnalysisImpl.java
View file @
fe7c746e
...
...
@@ -169,7 +169,6 @@ public class CustomerAnalysisImpl implements CustomerAnalysisService {
if
(
Req
.
getOrderfield
().
equals
(
"sumvolumeV1"
)==
true
)
{
Req
.
setOrderfield
(
"sumvolume1"
);
}
if
(
Req
.
getOrdertype
()
!=
null
&&
Req
.
getOrdertype
().
equals
(
"descending"
)==
true
)
{
Req
.
setOrdertype
(
"desc"
);
...
...
yudao-module-order/yudao-module-order-core/src/main/java/cn/iocoder/yudao/module/order/service/order/impl/OrderLocationServiceImpl.java
View file @
fe7c746e
...
...
@@ -147,17 +147,17 @@ public class OrderLocationServiceImpl extends AbstractService<OrderLocationMappe
}
@Override
public
void
deleteIfPresent
(
Long
orderId
,
Long
orderItemId
,
Long
warehouseInId
)
{
orderLocationMapper
.
delete
(
new
LambdaQueryWrapperX
<
OrderLocationDO
>().
eqIfPresent
(
OrderLocationDO:
:
getOrderId
,
orderId
)
public
void
deleteIfPresent
(
Long
orderId
,
Long
orderItemId
,
Long
warehouseInId
)
{
orderLocationMapper
.
delete
(
new
LambdaQueryWrapperX
<
OrderLocationDO
>().
eqIfPresent
(
OrderLocationDO:
:
getOrderId
,
orderId
)
.
eqIfPresent
(
OrderLocationDO:
:
getOrderItemId
,
orderItemId
)
.
eqIfPresent
(
OrderLocationDO:
:
getWarehouseInId
,
warehouseInId
));
}
// private void validateOrderLocationExists(Long id) {
// if (orderLocationMapper.selectById(id) == null) {
// throw exception(ORDER_LOCATION_NOT_EXISTS);
// }
// }
@Override
public
OrderLocationDO
getOrderLocation
(
Long
id
)
{
...
...
@@ -237,13 +237,13 @@ public class OrderLocationServiceImpl extends AbstractService<OrderLocationMappe
@Override
public
void
tallyUpdate
(
Long
orderId
,
List
<
OrderLocationCreateReqVO
>
orderLocationCreateReqVOList
)
{
if
(
CollectionUtil
.
isNotEmpty
(
orderLocationCreateReqVOList
))
{
if
(
CollectionUtil
.
isNotEmpty
(
orderLocationCreateReqVOList
))
{
//不修改储位时参数只传orderId
orderLocationCreateReqVOList
=
orderLocationCreateReqVOList
.
stream
()
.
filter
(
t
->
t
.
getWareId
()
!=
null
)
.
collect
(
Collectors
.
toList
());
//下面的逻辑会先清空储位,因此当理货未修改储位时不需要执行下面的逻辑(因为确认到仓时也会执行这个方法和理货逻辑不一样)
if
(
CollectionUtil
.
isEmpty
(
orderLocationCreateReqVOList
))
return
;
if
(
CollectionUtil
.
isEmpty
(
orderLocationCreateReqVOList
))
return
;
}
// 储位信息 删除老储位
...
...
yudao-module-order/yudao-module-order-core/src/main/java/cn/iocoder/yudao/module/order/service/order/impl/OrderServiceImpl.java
View file @
fe7c746e
...
...
@@ -5439,7 +5439,8 @@ public class OrderServiceImpl extends AbstractService<OrderMapper, OrderDO> impl
*/
@Override
public
void
approvalOrder
(
String
approveId
,
Integer
result
)
{
OrderApprovalDO
orderApprovalDO
=
orderApprovalMapper
.
selectById
(
approveId
);
OrderApprovalDO
orderApprovalDO
=
orderApprovalMapper
.
selectById
(
approveId
);
if
(
Objects
.
isNull
(
orderApprovalDO
))
{
throw
exception
(
ORDER_APPROVAL_INFO_NOT_FIND
);
}
...
...
@@ -5476,8 +5477,10 @@ public class OrderServiceImpl extends AbstractService<OrderMapper, OrderDO> impl
}
//批量特价申请
else
if
(
Objects
.
equals
(
orderApprovalDO
.
getType
(),
OrderApprovalTypeEnum
.
DISCOUNT_APPLY_BATCH
.
getValue
())
||
Objects
.
equals
(
orderApprovalDO
.
getType
(),
OrderApprovalTypeEnum
.
ADMIN_DISCOUNT_BATCH
.
getValue
()))
{
else
if
(
Objects
.
equals
(
orderApprovalDO
.
getType
(),
OrderApprovalTypeEnum
.
DISCOUNT_APPLY_BATCH
.
getValue
())
||
Objects
.
equals
(
orderApprovalDO
.
getType
(),
OrderApprovalTypeEnum
.
ADMIN_DISCOUNT_BATCH
.
getValue
()))
{
OrderSpecialBatchApplyVO
specialBatchApplyVO
=
JSONObject
.
parseObject
(
orderApprovalDO
.
getDetails
(),
OrderSpecialBatchApplyVO
.
class
);
specialBatchApplyVO
.
setApplyStatus
(
result
);
...
...
yudao-module-order/yudao-module-order-core/src/main/java/cn/iocoder/yudao/module/order/service/orderCargoControlPick/OrderCargoControlPickServiceImpl.java
View file @
fe7c746e
...
...
@@ -116,7 +116,8 @@ public class OrderCargoControlPickServiceImpl extends AbstractService<OrderCargo
private
ParamValidatorApi
paramValidatorApi
;
@Override
public
Long
createOrderCargoControlPick
(
OrderCargoControlPickCreateReqVO
createReqVO
)
{
public
Long
createOrderCargoControlPick
(
OrderCargoControlPickCreateReqVO
createReqVO
)
{
if
(
Objects
.
isNull
(
createReqVO
.
getPickNum
())
||
createReqVO
.
getPickNum
()
<=
0
)
{
throw
exception
(
ORDER_CARGO_CONTROL_PICK_NUM_NOT_EQ_ZERO
);
}
...
...
@@ -131,7 +132,8 @@ public class OrderCargoControlPickServiceImpl extends AbstractService<OrderCargo
throw
exception
(
CONSIGNEE_PHONE_IS_NOT_CHINA
);
}
// if (StringUtils.isNotBlank(createReqVO.getConsigneeCountryCode()) && StringUtils.isNotBlank(createReqVO.getConsigneePhone())) {
String
mobileCode
=
createReqVO
.
getConsigneeCountryCode
()
+
StrUtil
.
COLON
+
createReqVO
.
getConsigneePhone
();
String
mobileCode
=
createReqVO
.
getConsigneeCountryCode
()
+
StrUtil
.
COLON
+
createReqVO
.
getConsigneePhone
();
paramValidatorApi
.
validatorMobile
(
mobileCode
);
// String phone = PhoneUtil.formatPhone(mobileCode);
// if (StringUtils.isNotBlank(phone)) {
...
...
@@ -154,7 +156,8 @@ public class OrderCargoControlPickServiceImpl extends AbstractService<OrderCargo
int
pickQuantity
=
0
;
BigDecimal
pickVolume
=
BigDecimal
.
ZERO
;
BigDecimal
pickWeight
=
BigDecimal
.
ZERO
;
List
<
OrderCargoControlPickDO
>
pickDOList
=
orderCargoControlPickMapper
.
selectList
(
new
LambdaQueryWrapper
<
OrderCargoControlPickDO
>()
List
<
OrderCargoControlPickDO
>
pickDOList
=
orderCargoControlPickMapper
.
selectList
(
new
LambdaQueryWrapper
<
OrderCargoControlPickDO
>()
.
eq
(
OrderCargoControlPickDO:
:
getOrderId
,
createReqVO
.
getOrderId
())
.
in
(
OrderCargoControlPickDO:
:
getStatus
,
Arrays
.
asList
(
1
,
2
,
3
,
4
,
5
,
6
))
.
eq
(
OrderCargoControlPickDO:
:
getDeleted
,
Boolean
.
FALSE
));
...
...
@@ -176,7 +179,8 @@ public class OrderCargoControlPickServiceImpl extends AbstractService<OrderCargo
}
OrderCargoControlDO
orderCargoControlDO
=
orderCargoControlService
.
getOne
(
new
LambdaQueryWrapper
<
OrderCargoControlDO
>()
OrderCargoControlDO
orderCargoControlDO
=
orderCargoControlService
.
getOne
(
new
LambdaQueryWrapper
<
OrderCargoControlDO
>()
.
eq
(
OrderCargoControlDO:
:
getOrderId
,
createReqVO
.
getOrderId
())
.
eq
(
OrderCargoControlDO:
:
getIsActual
,
Boolean
.
TRUE
)
.
orderByDesc
(
OrderCargoControlDO:
:
getId
)
...
...
@@ -190,7 +194,8 @@ public class OrderCargoControlPickServiceImpl extends AbstractService<OrderCargo
Integer
userType
=
loginUser
!=
null
?
loginUser
.
getUserType
()
:
null
;
String
creator
=
String
.
valueOf
(
userId
);
Date
now
=
new
Date
();
if
(
StringUtils
.
isBlank
(
createReqVO
.
getCode
())
&&
StringUtils
.
isBlank
(
createReqVO
.
getControlPassword
()))
{
if
(
StringUtils
.
isBlank
(
createReqVO
.
getCode
())
&&
StringUtils
.
isBlank
(
createReqVO
.
getControlPassword
()))
{
throw
exception
(
ORDER_CARGO_CONTROL_PICK_MUST_CODE_OR_PASSWORD
);
}
boolean
isPasswordError
=
false
;
// 是否密码错误
...
...
@@ -210,8 +215,11 @@ public class OrderCargoControlPickServiceImpl extends AbstractService<OrderCargo
// throw exception(USER_PASSWORD_FAILED);
}
}
if
(
StringUtils
.
isNotBlank
(
createReqVO
.
getCode
())
&&
(
StringUtils
.
isBlank
(
createReqVO
.
getControlPassword
())
||
isPasswordError
||
isPasswordNull
))
{
// 验证放货短信验证码
if
(
StringUtils
.
isNotBlank
(
createReqVO
.
getCode
())
&&
(
StringUtils
.
isBlank
(
createReqVO
.
getControlPassword
())
||
isPasswordError
||
isPasswordNull
))
{
//验证放货短信验证码
SmsCodeUseReqDTO
smsCodeSendReqDTO
=
new
SmsCodeUseReqDTO
();
smsCodeSendReqDTO
.
setCode
(
createReqVO
.
getCode
());
smsCodeSendReqDTO
.
setMobile
(
orderCargoControlDO
.
getPhone
());
...
...
@@ -221,7 +229,8 @@ public class OrderCargoControlPickServiceImpl extends AbstractService<OrderCargo
isPasswordPick
=
false
;
}
if
(
StringUtils
.
isBlank
(
createReqVO
.
getCode
())
&&
(
isPasswordError
||
isPasswordNull
))
{
if
(
StringUtils
.
isBlank
(
createReqVO
.
getCode
())
&&
(
isPasswordError
||
isPasswordNull
))
{
// 当控货人手机号没有注册web用户,或者用户没有设置控货密码时不能进行控货密码放货
if
(
isPasswordNull
)
{
throw
exception
(
CONTROLLER_USER_NOT_SET_CONTROL_PASSWORD
);
...
...
@@ -235,7 +244,8 @@ public class OrderCargoControlPickServiceImpl extends AbstractService<OrderCargo
this
.
smsInternal
(
orderDO
,
createReqVO
,
orderCargoControlDO
,
now
);
// 插入
OrderCargoControlPickDO
orderCargoControlPick
=
OrderCargoControlPickConvert
.
INSTANCE
.
convert
(
createReqVO
);
OrderCargoControlPickDO
orderCargoControlPick
=
OrderCargoControlPickConvert
.
INSTANCE
.
convert
(
createReqVO
);
orderCargoControlPick
.
setControlNum
(
orderDO
.
getSumNum
()
-
pickNum
);
...
...
yudao-module-order/yudao-module-order-core/src/main/java/cn/iocoder/yudao/module/order/service/orderWarehouseIn/OrderWarehouseInServiceImpl.java
View file @
fe7c746e
This diff is collapsed.
Click to expand it.
yudao-module-order/yudao-module-order-rest/src/main/java/cn/iocoder/yudao/module/order/controller/admin/orderCargoControlPick/OrderCargoControlPickController.java
View file @
fe7c746e
...
...
@@ -44,8 +44,10 @@ public class OrderCargoControlPickController {
@PostMapping
(
"/create"
)
@ApiOperation
(
"创建订单控货人放货记录"
)
@Idempotent
(
timeout
=
5
)
public
CommonResult
<
Long
>
createOrderCargoControlPick
(
@Valid
@RequestBody
OrderCargoControlPickCreateReqVO
createReqVO
)
{
return
success
(
orderCargoControlPickService
.
createOrderCargoControlPick
(
createReqVO
));
public
CommonResult
<
Long
>
createOrderCargoControlPick
(
@Valid
@RequestBody
OrderCargoControlPickCreateReqVO
createReqVO
)
{
return
success
(
orderCargoControlPickService
.
createOrderCargoControlPick
(
createReqVO
));
}
...
...
yudao-module-product/yudao-module-product-core/src/main/java/cn/iocoder/yudao/module/product/component/ProdCostCalculation.java
View file @
fe7c746e
...
...
@@ -479,7 +479,7 @@ public class ProdCostCalculation {
feeDto
.
setAmount
(
costDto
.
getTotalWorth
());
feeDto
.
setCurrencyId
(
rmbCurrency
);
feeDtoList
.
add
(
feeDto
);
//
TODO 是否计算总重量与体积
//TODO 是否计算总重量与体积
costDto
.
setFeeDtoList
(
feeDtoList
);
dto
.
setCostDto
(
costDto
);
if
(
CollectionUtil
.
isNotEmpty
(
couponAvailableGroupDtoList
))
{
...
...
yudao-module-system/yudao-module-system-impl/src/main/java/cn/iocoder/yudao/module/system/service/sms/SmsCodeServiceImpl.java
View file @
fe7c746e
...
...
@@ -53,13 +53,13 @@ public class SmsCodeServiceImpl implements SmsCodeService {
// 创建验证码
String
code
=
createSmsCode
(
reqDTO
.
getMobile
(),
reqDTO
.
getScene
(),
reqDTO
.
getCreateIp
());
// 发送验证码
smsSendService
.
sendSingleSms
(
reqDTO
.
getAreaCode
()
+
reqDTO
.
getMobile
(),
null
,
null
,
smsSendService
.
sendSingleSms
(
reqDTO
.
getAreaCode
()
+
reqDTO
.
getMobile
(),
null
,
null
,
sceneEnum
.
getTemplateCode
(),
MapUtil
.
of
(
"code"
,
code
));
}
private
String
createSmsCode
(
String
mobile
,
Integer
scene
,
String
ip
)
{
// 校验是否可以发送验证码,不用筛选场景
SmsCodeDO
lastSmsCode
=
smsCodeMapper
.
selectLastByMobile
(
mobile
,
null
,
null
);
SmsCodeDO
lastSmsCode
=
smsCodeMapper
.
selectLastByMobile
(
mobile
,
null
,
null
);
if
(
lastSmsCode
!=
null
)
{
if
(
lastSmsCode
.
getTodayIndex
()
>=
smsCodeProperties
.
getSendMaximumQuantityPerDay
())
{
// 超过当天发送的上限。
throw
ServiceExceptionUtil
.
exception
(
SMS_CODE_EXCEED_SEND_MAXIMUM_QUANTITY_PER_DAY
);
...
...
@@ -83,11 +83,16 @@ public class SmsCodeServiceImpl implements SmsCodeService {
@Override
public
void
useSmsCode
(
SmsCodeUseReqDTO
reqDTO
)
{
if
(
Objects
.
nonNull
(
businessProperties
)
&&
businessProperties
.
isDebug
()){
if
(
Objects
.
equals
(
reqDTO
.
getCode
(),
"9999"
))
{
return
;
}
if
(
Objects
.
nonNull
(
businessProperties
)
&&
businessProperties
.
isDebug
())
{
// TODO debug业务模式下不需要生成发送验证码,固定使用9999
if
(
Objects
.
equals
(
reqDTO
.
getCode
(),
"9999"
)){
if
(
Objects
.
equals
(
reqDTO
.
getCode
(),
"9999"
))
{
return
;
}
else
{
}
else
{
throw
ServiceExceptionUtil
.
exception
(
SMS_CODE_NOT_FOUND
);
}
}
...
...
@@ -105,7 +110,7 @@ public class SmsCodeServiceImpl implements SmsCodeService {
public
SmsCodeDO
checkSmsCode0
(
String
mobile
,
String
code
,
Integer
scene
)
{
// 校验验证码
SmsCodeDO
lastSmsCode
=
smsCodeMapper
.
selectLastByMobile
(
mobile
,
code
,
scene
);
SmsCodeDO
lastSmsCode
=
smsCodeMapper
.
selectLastByMobile
(
mobile
,
code
,
scene
);
// 若验证码不存在,抛出异常
if
(
lastSmsCode
==
null
)
{
throw
ServiceExceptionUtil
.
exception
(
SMS_CODE_NOT_FOUND
);
...
...
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