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
fd4f6d55
Commit
fd4f6d55
authored
Aug 08, 2024
by
332784038@qq.com
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
拆单与撤销拆单对订单费用申请记录与应收单的增删业务bug修复
parent
34c00336
Changes
4
Hide whitespace changes
Inline
Side-by-side
Showing
4 changed files
with
31 additions
and
9 deletions
+31
-9
OrderServiceImpl.java
...dao/module/order/service/order/impl/OrderServiceImpl.java
+9
-3
ReceivableMapper.java
.../module/wealth/dal/mysql/receivable/ReceivableMapper.java
+7
-4
ReceivableService.java
...o/module/wealth/service/receivable/ReceivableService.java
+10
-2
ReceivableServiceImpl.java
...dule/wealth/service/receivable/ReceivableServiceImpl.java
+5
-0
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 @
fd4f6d55
...
...
@@ -5682,8 +5682,6 @@ public class OrderServiceImpl extends AbstractService<OrderMapper, OrderDO> impl
this
.
update
(
new
LambdaUpdateWrapper
<
OrderDO
>().
set
(
OrderDO:
:
getSplitTime
,
null
).
eq
(
OrderDO:
:
getOrderId
,
parentOrderId
));
// 查询相关子订单信息,并且删除子订单相关的记录,避免重新撤销拆单后再次拆单的数据重复
List
<
OrderDO
>
orderDOList
=
orderMapper
.
selectList
(
new
LambdaQueryWrapper
<
OrderDO
>().
eq
(
OrderDO:
:
getParentOrderId
,
parentOrderId
));
if
(
CollectionUtil
.
isNotEmpty
(
orderBackInfoDtoList
))
{
List
<
Long
>
orderIds
=
new
ArrayList
<>();
for
(
OrderBackInfoDto
splitOrder
:
orderBackInfoDtoList
)
{
...
...
@@ -5719,7 +5717,15 @@ public class OrderServiceImpl extends AbstractService<OrderMapper, OrderDO> impl
// 物理删除订单 ,在所有业务执行完成后进行删除
orderMapper
.
remove
(
orderIds
);
}
// 恢复母订单可能的费用申请记录应收单
List
<
OrderFeeApplicationDO
>
feeApplicationDOList
=
feeApplicationService
.
getFeeApplicationListByOrderId
(
parentOrderId
);
if
(
CollectionUtil
.
isNotEmpty
(
feeApplicationDOList
))
{
for
(
OrderFeeApplicationDO
f
:
feeApplicationDOList
)
{
if
(
Objects
.
nonNull
(
f
.
getReceivableId
())
&&
f
.
getReceivableId
()
>
0
)
{
receivableService
.
revokeDeleteReceivableById
(
Long
.
valueOf
(
f
.
getReceivableId
()));
}
}
}
// 删除订单
// this.remove(new LambdaQueryWrapper<OrderDO>().eq(OrderDO::getParentOrderId, parentOrderId));
}
...
...
yudao-module-wealth/yudao-module-wealth-core/src/main/java/cn/iocoder/yudao/module/wealth/dal/mysql/receivable/ReceivableMapper.java
View file @
fd4f6d55
...
...
@@ -9,10 +9,8 @@ import cn.iocoder.yudao.module.wealth.vo.receivable.ReceivableBackVO;
import
cn.iocoder.yudao.module.wealth.vo.receivable.ReceivableOrderPayedFeeTypeVO
;
import
cn.iocoder.yudao.module.wealth.vo.receivable.ReceivableQueryVO
;
import
com.baomidou.mybatisplus.core.metadata.IPage
;
import
org.apache.ibatis.annotations.
Mapper
;
import
org.apache.ibatis.annotations.
*
;
import
org.apache.ibatis.annotations.Param
;
import
org.apache.ibatis.annotations.ResultType
;
import
org.apache.ibatis.annotations.Select
;
import
java.util.List
;
...
...
@@ -397,5 +395,10 @@ public interface ReceivableMapper extends AbstractMapper<ReceivableDO> {
"AND rb.order_id = #{orderId} "
,
"</script>"
})
List
<
ReceivableDO
>
allByOrderId
(
Long
orderId
);
List
<
ReceivableDO
>
allByOrderId
(
@Param
(
"orderId"
)
Long
orderId
);
@Update
({
"update ecw_receivable set `deleted` = 0 ,update_time = now() where `id` = #{receivableId}"
})
void
revokeDeleteReceivableById
(
@Param
(
"receivableId"
)
Long
receivableId
);
}
yudao-module-wealth/yudao-module-wealth-core/src/main/java/cn/iocoder/yudao/module/wealth/service/receivable/ReceivableService.java
View file @
fd4f6d55
...
...
@@ -73,7 +73,7 @@ public interface ReceivableService extends IService<ReceivableDO> {
/**
* 删除应收款--内部接口,不会判断应收能不能进行删除,判断前置
*
* @param orderId 编号
* @param orderId
编号
* @param feeSourceList 费用来源 1 订单计算 2 费用申请 3 特性费用
*/
void
deleteReceivableByOrderIdAndFeeSource
(
Long
orderId
,
Collection
<
Integer
>
feeSourceList
);
...
...
@@ -81,7 +81,7 @@ public interface ReceivableService extends IService<ReceivableDO> {
/**
* 删除应收款--内部接口,不会判断应收能不能进行删除,判断前置
*
* @param orderId 订单ID
* @param orderId
订单ID
* @param feeSource 费用来源:1 订单计算 2 费用申请 3 特需费用
*/
void
deleteReceivableByOrderIdAndFeeSource
(
Long
orderId
,
Integer
feeSource
);
...
...
@@ -100,6 +100,7 @@ public interface ReceivableService extends IService<ReceivableDO> {
* @param orderItemId 编号
*/
ReceivableDO
getReceivableByOrderItemId
(
Long
orderItemId
,
Integer
feeType
);
/**
* 获得应收款
*
...
...
@@ -242,4 +243,11 @@ public interface ReceivableService extends IService<ReceivableDO> {
List
<
ReceivableDO
>
allByOrderId
(
Long
orderId
);
List
<
ReceivableDO
>
getOrderPayList
(
Collection
<
Long
>
orderIdList
);
/**
* 根据应收id撤销删除的应收单
*
* @param receivableId 应收id
*/
void
revokeDeleteReceivableById
(
Long
receivableId
);
}
yudao-module-wealth/yudao-module-wealth-core/src/main/java/cn/iocoder/yudao/module/wealth/service/receivable/ReceivableServiceImpl.java
View file @
fd4f6d55
...
...
@@ -372,4 +372,9 @@ public class ReceivableServiceImpl extends AbstractService<ReceivableMapper, Rec
.
in
(
ReceivableDO:
:
getOrderId
,
orderIdList
)
);
}
@Override
public
void
revokeDeleteReceivableById
(
Long
receivableId
)
{
receivableMapper
.
revokeDeleteReceivableById
(
receivableId
);
}
}
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