This commit is contained in:
wangjinlei
2023-08-18 09:45:52 +08:00
parent fa480cf2f9
commit 0be7e54304
3 changed files with 13 additions and 1 deletions

View File

@@ -39,6 +39,7 @@ class Journal extends Controller {
protected $footer_obj = '';
protected $journal_for_author;
protected $journal_for_author_yc_obj = '';
protected $article_main_obj = '';
public function __construct(\think\Request $request = null) {
parent::__construct($request);
@@ -66,6 +67,7 @@ class Journal extends Controller {
$this->footer_obj = Db::name('footer');
$this->journal_for_author = Db::name('journal_for_author');
$this->journal_for_author_yc_obj = Db::name('journal_for_author_yc');
$this->article_main_obj = Db::name("article_main");
}
/**
@@ -633,6 +635,8 @@ class Journal extends Controller {
}
$list[$k]['title'] = $cache_title;
$list[$k]['mains'] = [];//getArticleMains($v['article_id']);
$cm = $this->article_main_obj->where('article_id',$v['article_id'])->where('state',0)->find();
$list[$k]['has_mains'] = $cm?1:0;
}
//获取作者