|
@@ -134,18 +134,20 @@ public class CorpCustomerAcquistionLinkController {
|
|
|
* 针对获客链接添加额外客服
|
|
* 针对获客链接添加额外客服
|
|
|
*/
|
|
*/
|
|
|
@PostMapping("/add/extra/service")
|
|
@PostMapping("/add/extra/service")
|
|
|
- public Result<String> addExtraService(@RequestBody @Validated CorpCustomerAcquisitionLinkExtraCustomer extraCustomer) {
|
|
|
|
|
|
|
+ public Result<String> addExtraService(@RequestBody @Validated CorpCustomerAcquisitionLinkExtraCustomer extraCustomer) throws Exception {
|
|
|
corpCustomerAcquisitionLinkExtraCustomerMapper.insert(extraCustomer);
|
|
corpCustomerAcquisitionLinkExtraCustomerMapper.insert(extraCustomer);
|
|
|
- return GatewayResponse.SUCCESS.newBuilder().toResult();
|
|
|
|
|
|
|
+ corpCustomerAcquisitionLinkService.handleCorpLinkSchedulerJob();
|
|
|
|
|
+ return GatewayResponse.SUCCESS.newBuilder().toResult();
|
|
|
}
|
|
}
|
|
|
|
|
|
|
|
/**
|
|
/**
|
|
|
* 修改获客链接添加额外客服
|
|
* 修改获客链接添加额外客服
|
|
|
*/
|
|
*/
|
|
|
@PutMapping("/update/extra/service")
|
|
@PutMapping("/update/extra/service")
|
|
|
- public Result<String> updateExtraService(@RequestBody @Validated CorpCustomerAcquisitionLinkExtraCustomer extraCustomer) {
|
|
|
|
|
|
|
+ public Result<String> updateExtraService(@RequestBody @Validated CorpCustomerAcquisitionLinkExtraCustomer extraCustomer) throws Exception {
|
|
|
corpCustomerAcquisitionLinkExtraCustomerMapper.updateById(extraCustomer);
|
|
corpCustomerAcquisitionLinkExtraCustomerMapper.updateById(extraCustomer);
|
|
|
- return GatewayResponse.SUCCESS.newBuilder().toResult();
|
|
|
|
|
|
|
+ corpCustomerAcquisitionLinkService.handleCorpLinkSchedulerJob();
|
|
|
|
|
+ return GatewayResponse.SUCCESS.newBuilder().toResult();
|
|
|
}
|
|
}
|
|
|
|
|
|
|
|
/**
|
|
/**
|
|
@@ -156,9 +158,13 @@ public class CorpCustomerAcquistionLinkController {
|
|
|
Optional.ofNullable(corpCustomerAcquisitionLinkExtraCustomerMapper.selectById(id))
|
|
Optional.ofNullable(corpCustomerAcquisitionLinkExtraCustomerMapper.selectById(id))
|
|
|
.ifPresent(e -> {
|
|
.ifPresent(e -> {
|
|
|
if (e.getDeleted()) {
|
|
if (e.getDeleted()) {
|
|
|
- e.setDeleted(false);
|
|
|
|
|
- corpCustomerAcquisitionLinkExtraCustomerMapper.updateById(e);
|
|
|
|
|
- }
|
|
|
|
|
|
|
+ try {
|
|
|
|
|
+ e.setDeleted(false);
|
|
|
|
|
+ corpCustomerAcquisitionLinkExtraCustomerMapper.updateById(e);
|
|
|
|
|
+ corpCustomerAcquisitionLinkService.handleCorpLinkSchedulerJob();
|
|
|
|
|
+ } catch (Exception ex) {
|
|
|
|
|
+ }
|
|
|
|
|
+ }
|
|
|
});
|
|
});
|
|
|
return GatewayResponse.SUCCESS.newBuilder().toResult();
|
|
return GatewayResponse.SUCCESS.newBuilder().toResult();
|
|
|
}
|
|
}
|