From fe4581b8b2524ee96054e23e8ff873f66e68e20f Mon Sep 17 00:00:00 2001 From: liyukun <1099438829@qq.com> Date: Wed, 9 Feb 2022 00:04:13 +0800 Subject: [PATCH] =?UTF-8?q?=E4=BF=AE=E6=AD=A3=E4=B8=BB=E9=A2=98=E5=88=97?= =?UTF-8?q?=E8=A1=A8=E9=94=99=E8=AF=AF?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- app/common/taglib/Ape.php | 2 +- app/index/common.php | 4 ++-- public/template/default/pc/category/list_default.html | 3 +-- 3 files changed, 4 insertions(+), 5 deletions(-) diff --git a/app/common/taglib/Ape.php b/app/common/taglib/Ape.php index 08288ac..6afad3d 100644 --- a/app/common/taglib/Ape.php +++ b/app/common/taglib/Ape.php @@ -142,7 +142,7 @@ class Ape extends TagLib $display = isset($tag['display']) ? $tag['display'] : 1; $display = $display == 1 ? 1 : 0; $parse = 'render();'; $parse .= ' ?>'; $parse .= '{volist name="__LIST__" id="' . $void . '" key="i"}'; diff --git a/app/index/common.php b/app/index/common.php index 378d310..e892011 100644 --- a/app/index/common.php +++ b/app/index/common.php @@ -345,8 +345,8 @@ function tpl_get_list($orderBy, $pageSize, $cid, $type, $table = 'article', $whe case 'find': //获取栏目下文章以及所有子孙分类文章 $dc = get_document_category($cid); - $child = $dc['child']; - if ($child) { + if (!empty($dc['child'])) { + $child = $dc['child']; $documentListModel = $documentListModel->where('a.category_id', 'in', "$cid,$child"); } else { $documentListModel = $documentListModel->where('a.category_id', $cid); diff --git a/public/template/default/pc/category/list_default.html b/public/template/default/pc/category/list_default.html index 9a09fb4..a9f1838 100644 --- a/public/template/default/pc/category/list_default.html +++ b/public/template/default/pc/category/list_default.html @@ -20,7 +20,7 @@
{$apeField['title']}