修改客户继承bug

1 parent 0c626b24
...@@ -420,15 +420,17 @@ public class WeCustomerServiceImpl extends ServiceImpl<WeCustomerMapper, WeCusto ...@@ -420,15 +420,17 @@ public class WeCustomerServiceImpl extends ServiceImpl<WeCustomerMapper, WeCusto
); );
if(jobExtendsCustomer.getErrcode().equals(WeConstans.WE_SUCCESS_CODE)){ if(jobExtendsCustomer.getErrcode().equals(WeConstans.WE_SUCCESS_CODE)){
iWeAllocateCustomerService.save( iWeAllocateCustomerService.batchAddOrUpdate(
WeAllocateCustomer.builder() ListUtil.toList(
.allocateTime(new Date()) WeAllocateCustomer.builder()
.extentType(new Integer(1)) .allocateTime(new Date())
.externalUserid(weOnTheJobCustomerVo.getExternalUserid()) .extentType(new Integer(1))
.handoverUserid(weOnTheJobCustomerVo.getHandoverUserId()) .externalUserid(weOnTheJobCustomerVo.getExternalUserid())
.takeoverUserid(weOnTheJobCustomerVo.getTakeoverUserId()) .handoverUserid(weOnTheJobCustomerVo.getHandoverUserId())
.failReason("在职继承") .takeoverUserid(weOnTheJobCustomerVo.getTakeoverUserId())
.build() .failReason("在职继承")
.build()
)
); );
} }
......
...@@ -19,11 +19,11 @@ PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN" ...@@ -19,11 +19,11 @@ PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN"
(#{item.takeoverUserid},#{item.externalUserid},#{item.allocateTime},#{item.handoverUserid},#{item.status},#{item.takeoverTime},#{item.failReason}) (#{item.takeoverUserid},#{item.externalUserid},#{item.allocateTime},#{item.handoverUserid},#{item.status},#{item.takeoverTime},#{item.failReason})
</foreach> </foreach>
ON DUPLICATE KEY UPDATE ON DUPLICATE KEY UPDATE
takeover_userid=IF(TRIM(VALUES(takeover_userid)) != '',VALUES(takeover_userid),we_allocate_customer.takeover_userid), takeover_userid=IFNULL(VALUES(takeover_userid),we_allocate_customer.takeover_userid),
allocate_time=IF(VALUES(allocate_time), VALUES(allocate_time), we_allocate_customer.allocate_time), allocate_time=IFNULL(VALUES(allocate_time) , we_allocate_customer.allocate_time),
takeover_time=IF(VALUES(takeover_time), VALUES(takeover_time), we_allocate_customer.takeover_time), takeover_time=IFNULL(VALUES(takeover_time), we_allocate_customer.takeover_time),
status=IF(VALUES(status), VALUES(status),we_allocate_customer.status), status=IFNULL(VALUES(status),we_allocate_customer.status),
fail_reason=IF(TRIM(VALUES(fail_reason)) !='',VALUES(fail_reason),we_allocate_customer.fail_reason); fail_reason=IFNULL(VALUES(fail_reason),we_allocate_customer.fail_reason);
</insert> </insert>
......
Markdown is supported
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!