From e334e86fd8cb010b8e540b1b7f80c97aa903cde3 Mon Sep 17 00:00:00 2001 From: chengxl Date: Thu, 7 Aug 2025 13:45:48 +0800 Subject: [PATCH] =?UTF-8?q?=E6=96=87=E7=AB=A0=E5=86=85=E5=AE=B9=E7=9B=B8?= =?UTF-8?q?=E5=85=B3=E8=B0=83=E6=95=B4?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- application/wechat/controller/Article.php | 8 +++----- 1 file changed, 3 insertions(+), 5 deletions(-) diff --git a/application/wechat/controller/Article.php b/application/wechat/controller/Article.php index 8b36736..76f9c6a 100644 --- a/application/wechat/controller/Article.php +++ b/application/wechat/controller/Article.php @@ -35,11 +35,9 @@ class Article extends Controller $aWhere = ['article_id' => $iArticleId,'state' => 0]; $aArticle = Db::name('article')->field('article_id,title,abstract,journal_id,journal_stage_id,abbr,npp,doi,icon as article_icon,related,type')->where($aWhere)->find(); if(empty($aArticle)){ - return json_encode(array('status' => 3,'msg' => 'Article not found' )); + return json_encode(array('status' => 3,'msg' => 'Article not found'.Db::getLastSql() )); } - //文章内容 - $aMain = $this->_main($iArticleId); //查询文章所属期刊信息 $aJournal = $this->_journal($aArticle['journal_id']); @@ -51,7 +49,7 @@ class Article extends Controller $aAuthor = $this->_author($iArticleId); - return json_encode(array('status' => 1,'msg' => 'Successfully obtained AI generated article content','data' => ['article' => $aArticle,'journal' => $aJournal,'journal_stage' => $aJournalStage,'author' => $aAuthor,'main' => $aMain])); + return json_encode(array('status' => 1,'msg' => 'Successfully obtained AI generated article content','data' => ['article' => $aArticle,'journal' => $aJournal,'journal_stage' => $aJournalStage,'author' => $aAuthor])); } @@ -64,7 +62,7 @@ class Article extends Controller $aWhere['article_id'] = $iArticleId; $aWhere['content'] =['<>','']; $aWhere['state'] = 0; - $aMain = Db::name('article_main')->where($aWhere)->column('content'); + $aMain = Db::name('article_main')->where($aWhere)->column('article_main_id,content'); return $aMain; }