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
e5c1b062
Commit
e5c1b062
authored
Sep 04, 2024
by
332784038@qq.com
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
订单复制部分业务代码提交
parent
5457e14c
Changes
2
Hide whitespace changes
Inline
Side-by-side
Showing
2 changed files
with
33 additions
and
0 deletions
+33
-0
OrderService.java
...ocoder/yudao/module/order/service/order/OrderService.java
+13
-0
OrderServiceImpl.java
...dao/module/order/service/order/impl/OrderServiceImpl.java
+20
-0
No files found.
yudao-module-order/yudao-module-order-core/src/main/java/cn/iocoder/yudao/module/order/service/order/OrderService.java
View file @
e5c1b062
...
...
@@ -30,6 +30,8 @@ import java.util.List;
public
interface
OrderService
extends
IService
<
OrderDO
>
{
void
updateOrderSalesmanId
(
Long
orderId
,
Long
salesman_id
);
/**
* 创建订单
*
...
...
@@ -379,4 +381,15 @@ public interface OrderService extends IService<OrderDO> {
void
updateOrderCustomerAndSalesmanId
(
Long
customerId
,
Long
salesmanId
,
Long
orderId
);
/**
* copy订单
*
* @param copyOrderId 复制的订单id
* @param memberUserDO 会员信息
* @return 编号
*/
Long
copyOrder
(
Long
copyOrderId
,
MemberUserDO
memberUserDO
);
}
yudao-module-order/yudao-module-order-core/src/main/java/cn/iocoder/yudao/module/order/service/order/impl/OrderServiceImpl.java
View file @
e5c1b062
...
...
@@ -6201,4 +6201,24 @@ public class OrderServiceImpl extends AbstractService<OrderMapper, OrderDO> impl
orderMapper
.
updateOrderCustomerAndSalesmanId
(
customerId
,
salesmanId
,
orderId
);
}
@Override
public
Long
copyOrder
(
Long
copyOrderId
,
MemberUserDO
memberUserDO
)
{
OrderDO
orderDO
=
orderMapper
.
selectById
(
copyOrderId
);
// 发货人信息
OrderConsignorDO
orderConsignorDO
=
orderConsignorService
.
getOne
(
new
LambdaQueryWrapper
<
OrderConsignorDO
>().
eq
(
OrderConsignorDO:
:
getOrderId
,
orderDO
.
getOrderId
()).
orderByDesc
(
OrderConsignorDO:
:
getId
).
last
(
"limit 1"
));
// 收货人信息
OrderConsigneeDO
orderConsigneeDO
=
orderConsigneeService
.
getOne
(
new
LambdaQueryWrapper
<
OrderConsigneeDO
>().
eq
(
OrderConsigneeDO:
:
getOrderId
,
orderDO
.
getOrderId
()).
orderByDesc
(
OrderConsigneeDO:
:
getId
).
last
(
"limit 1"
));
// 控货信息
OrderCargoControlDO
orderCargoControlDO
=
orderCargoControlMapper
.
selectOne
(
new
LambdaQueryWrapper
<
OrderCargoControlDO
>().
eq
(
OrderCargoControlDO:
:
getOrderId
,
orderDO
.
getOrderId
()).
orderByDesc
(
OrderCargoControlDO:
:
getId
).
last
(
"limit 1"
));
// 始发地
OrderDepartureDO
orderDepartureDO
=
orderDepartureService
.
getOne
(
new
LambdaQueryWrapper
<
OrderDepartureDO
>().
eq
(
OrderDepartureDO:
:
getOrderId
,
orderDO
.
getOrderId
()).
orderByDesc
(
OrderDepartureDO:
:
getId
).
last
(
"limit 1"
));
// 目的地
OrderObjectiveDO
orderObjectiveDO
=
orderObjectiveService
.
getOne
(
new
LambdaQueryWrapper
<
OrderObjectiveDO
>().
eq
(
OrderObjectiveDO:
:
getOrderId
,
orderDO
.
getOrderId
()).
orderByDesc
(
OrderObjectiveDO:
:
getId
).
last
(
"limit 1"
));
// 商品信息
List
<
OrderItemDO
>
itemDOList
=
orderItemMapper
.
selectList
(
new
LambdaQueryWrapper
<
OrderItemDO
>().
eq
(
OrderItemDO:
:
getOrderId
,
orderDO
.
getOrderId
()).
orderByDesc
(
OrderItemDO:
:
getOrderItemId
));
// TODO 这里是否需要重新判断业绩归属
// TODO 如果是web端复制的,发货人不是当前登陆会员,是否要改为当前登陆的会员管理客户信息
return
0L
;
}
}
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