|
@@ -726,27 +726,22 @@ public class BmsEventOrderService {
|
|
|
* @param status
|
|
|
* @return
|
|
|
*/
|
|
|
- public boolean updateOrderContactStatus4Callback(Long orderId,String contactPhone, Integer status,String failureReason) {
|
|
|
+ public boolean updateOrderContactStatus4Callback(String callId, Long orderId,String phone, Integer status,String failureReason) {
|
|
|
|
|
|
UpdateWrapper<CareEventOrderContactStatus> updateWrapper = new UpdateWrapper<>();
|
|
|
- updateWrapper.lambda().eq(CareEventOrderContactStatus::getOrderId, orderId).eq(CareEventOrderContactStatus::getContactPhone,contactPhone)
|
|
|
+ updateWrapper.lambda().eq(CareEventOrderContactStatus::getOrderId, orderId).eq(CareEventOrderContactStatus::getContactPhone,phone)
|
|
|
.set(CareEventOrderContactStatus::getStatus, status);
|
|
|
|
|
|
- QueryWrapper<CareEventOrderContactStatus> queryWrapper = new QueryWrapper<>();
|
|
|
- queryWrapper.lambda().eq(CareEventOrderContactStatus::getOrderId,orderId).eq(CareEventOrderContactStatus::getContactPhone,contactPhone);
|
|
|
- CareEventOrderContactStatus contact = this.careEventOrderContactStatusService.getOne(queryWrapper);
|
|
|
-
|
|
|
- if(contact != null) {
|
|
|
- UpdateWrapper<CareEventOrderHandleHis> updateWrapper2 = new UpdateWrapper<>();
|
|
|
- updateWrapper2.lambda().eq(CareEventOrderHandleHis::getOrderId, orderId)
|
|
|
- .eq(CareEventOrderHandleHis::getLogType,LogTypeEnum.VOTICE.getValue())
|
|
|
- .eq(CareEventOrderHandleHis::getLogObjectId,contact.getContactId())
|
|
|
- .eq(CareEventOrderHandleHis::getLogResult,"语音通知")
|
|
|
- .set(CareEventOrderHandleHis::getVoiceCallStatus, status)
|
|
|
- .set(CareEventOrderHandleHis::getVoiceFailureReason, failureReason);
|
|
|
- this.careEventOrderHandleHisService.update(updateWrapper2);
|
|
|
- }
|
|
|
+ UpdateWrapper<CareEventOrderHandleHis> updateWrapper2 = new UpdateWrapper<>();
|
|
|
+ updateWrapper2.lambda().eq(CareEventOrderHandleHis::getVoiceCallId,callId)
|
|
|
+ .set(CareEventOrderHandleHis::getVoiceCallStatus, status)
|
|
|
+ .set(CareEventOrderHandleHis::getVoiceFailureReason, failureReason);
|
|
|
+ this.careEventOrderHandleHisService.update(updateWrapper2);
|
|
|
|
|
|
+ UpdateWrapper<CareEventOrderChamb> updateWrapper3 = new UpdateWrapper<>();
|
|
|
+ updateWrapper3.lambda().eq(CareEventOrderChamb::getOrderId,orderId).eq(CareEventOrderChamb::getPhone,phone)
|
|
|
+ .set(CareEventOrderChamb::getVoiceCallStatus, status);
|
|
|
+ this.careEventOrderChambService.update(updateWrapper3);
|
|
|
|
|
|
return this.careEventOrderContactStatusService.update(updateWrapper);
|
|
|
}
|