From 5d03b0cc49ca6ec340dd15c0809c663c44a41e6a Mon Sep 17 00:00:00 2001 From: wjt Date: Tue, 30 May 2023 18:40:45 +0800 Subject: [PATCH] =?UTF-8?q?=E4=BF=AE=E6=94=B9=E6=97=B6=E9=97=B4?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- .../modules/telemarkting/dao/AllCallInfoRepository.java | 5 +++-- .../telemarkting/service/impl/TelephoneCallServiceImpl.java | 2 +- 2 files changed, 4 insertions(+), 3 deletions(-) diff --git a/ad-platform-manage/ad-platform-management/src/main/java/com/baiye/modules/telemarkting/dao/AllCallInfoRepository.java b/ad-platform-manage/ad-platform-management/src/main/java/com/baiye/modules/telemarkting/dao/AllCallInfoRepository.java index 2e010156..7a552b2a 100644 --- a/ad-platform-manage/ad-platform-management/src/main/java/com/baiye/modules/telemarkting/dao/AllCallInfoRepository.java +++ b/ad-platform-manage/ad-platform-management/src/main/java/com/baiye/modules/telemarkting/dao/AllCallInfoRepository.java @@ -46,10 +46,11 @@ public interface AllCallInfoRepository extends JpaRepository, * @param status * @param duration * @param id + * @param createTime */ @Modifying - @Query(value = "update AllCallInfo d set d.status =?1 , d.duration = ?2 where d.id =?3") - void updateByDurationAndStatus(Integer status, Integer duration, Long id); + @Query(value = "update AllCallInfo d set d.status =?1 , d.duration = ?2 ,d.createTime=?4 where d.id =?3") + void updateByDurationAndStatus(Integer status, Integer duration, Long id, String createTime); /** diff --git a/ad-platform-manage/ad-platform-management/src/main/java/com/baiye/modules/telemarkting/service/impl/TelephoneCallServiceImpl.java b/ad-platform-manage/ad-platform-management/src/main/java/com/baiye/modules/telemarkting/service/impl/TelephoneCallServiceImpl.java index e2f2e218..2b600670 100644 --- a/ad-platform-manage/ad-platform-management/src/main/java/com/baiye/modules/telemarkting/service/impl/TelephoneCallServiceImpl.java +++ b/ad-platform-manage/ad-platform-management/src/main/java/com/baiye/modules/telemarkting/service/impl/TelephoneCallServiceImpl.java @@ -310,7 +310,7 @@ public class TelephoneCallServiceImpl implements TelephoneCallService { if (StrUtil.isNotBlank(rollCallBackDTO.getCallee_answer_time())) { //表示接通,更新线索状态 callClueRepository.updateByStatus(DefaultNumberConstants.TWO_NUMBER, allCallInfo.getClueId()); - allCallInfoRepository.updateByDurationAndStatus(DefaultNumberConstants.TWO_NUMBER, Integer.valueOf(rollCallBackDTO.getDuration()), allCallInfo.getId()); + allCallInfoRepository.updateByDurationAndStatus(DefaultNumberConstants.TWO_NUMBER, Integer.valueOf(rollCallBackDTO.getDuration()), allCallInfo.getId(), DateUtil.now()); //更新资源通话状态 CompletableFuture.runAsync(() -> updateSourceCallStatus(allCallInfo.getClueId(), DefaultNumberConstants.TWO_NUMBER, allCallInfo.getClueType(), traceId)); //实时扣除话费