From bc05301fc82eda268cb91856ee221cfefd1e79d1 Mon Sep 17 00:00:00 2001 From: jianjun Date: Wed, 10 Jun 2020 09:07:36 +0800 Subject: [PATCH] =?UTF-8?q?=E6=B7=BB=E5=8A=A0=E6=97=A5=E5=BF=97?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- .../epmet/controller/ArticleController.java | 20 +++++++++++-------- .../service/impl/ArticleServiceImpl.java | 12 +++++++++-- 2 files changed, 22 insertions(+), 10 deletions(-) diff --git a/epmet-module/gov-voice/gov-voice-server/src/main/java/com/epmet/controller/ArticleController.java b/epmet-module/gov-voice/gov-voice-server/src/main/java/com/epmet/controller/ArticleController.java index 1793b368f4..fc6e316885 100644 --- a/epmet-module/gov-voice/gov-voice-server/src/main/java/com/epmet/controller/ArticleController.java +++ b/epmet-module/gov-voice/gov-voice-server/src/main/java/com/epmet/controller/ArticleController.java @@ -225,14 +225,18 @@ public class ArticleController { @Async public void scanContent(TokenDto tokenDto,String draftId){ - SyncScanResult syncScanResult = articleService.scanContent(tokenDto, draftId); - if (syncScanResult == null) { - log.error("scanContent draftId:{} return result null", draftId); - } - if (syncScanResult.isAllPass()) { - articleService.scanAllPassPublishArticle(tokenDto, draftId); - } else { - articleService.updateAuditStatusFailById(draftId, syncScanResult); + try { + SyncScanResult syncScanResult = articleService.scanContent(tokenDto, draftId); + if (syncScanResult == null) { + log.error("scanContent draftId:{} return result null", draftId); + } + if (syncScanResult.isAllPass()) { + articleService.scanAllPassPublishArticle(tokenDto, draftId); + } else { + articleService.updateAuditStatusFailById(draftId, syncScanResult); + } + } catch (Exception e) { + log.error("scanContent exception draftId:{} return result null", e); } } diff --git a/epmet-module/gov-voice/gov-voice-server/src/main/java/com/epmet/service/impl/ArticleServiceImpl.java b/epmet-module/gov-voice/gov-voice-server/src/main/java/com/epmet/service/impl/ArticleServiceImpl.java index 6e66fe252a..fd6f0c9044 100644 --- a/epmet-module/gov-voice/gov-voice-server/src/main/java/com/epmet/service/impl/ArticleServiceImpl.java +++ b/epmet-module/gov-voice/gov-voice-server/src/main/java/com/epmet/service/impl/ArticleServiceImpl.java @@ -951,10 +951,17 @@ public class ArticleServiceImpl extends BaseServiceImpl