Commit c385c3e0 authored by 332784038@qq.com's avatar 332784038@qq.com

更新订单业绩归属客户经理时,同步更新其部门,如果客户经理不存在了,则部门id被重置

parent 7a7a791c
......@@ -200,6 +200,8 @@ public class OrderBusinessServiceImpl extends AbstractService<OrderMapper, Order
AdminUserRespDTO adminUserRespDTO = adminUserApi.getUser(order.getSalesmanId());
if (Objects.nonNull(adminUserRespDTO)) {
order.setDeptId(adminUserRespDTO.getDeptId());
}else {
order.setDeptId(0L);
}
} else if (CollectionUtil.isEmpty(orderExceptionDOList) &&
Objects.nonNull(customerDO)
......@@ -2048,6 +2050,8 @@ public class OrderBusinessServiceImpl extends AbstractService<OrderMapper, Order
AdminUserRespDTO adminUserRespDTO = adminUserApi.getUser(customerDO.getCustomerService());
if (Objects.nonNull(adminUserRespDTO)) {
orderDO.setDeptId(adminUserRespDTO.getDeptId());
}else {
orderDO.setDeptId(0L);
}
} else {
orderDO.setSalesmanId(0L);
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment