diff --git a/code/app/home/controller/Novel.php b/code/app/home/controller/Novel.php index 35d2473..a9b7f17 100644 --- a/code/app/home/controller/Novel.php +++ b/code/app/home/controller/Novel.php @@ -82,11 +82,11 @@ class Novel extends BaseController 'strDescription' => $strDescription, 'strPageCode' => 'rank' ]); - if ($boolIsMobile) { - return View::fetch(); - } else { - return View::fetch('pc/getNovelRank'); - } + + + $strView = $boolIsMobile ? '' : 'pc/getNovelRank'; + + return $this->rending($strView); } /** @@ -170,8 +170,8 @@ class Novel extends BaseController // 更新值 ConverterMovel::setVal([ 'intPage' => $intPage, - 'strNovelSex' => $arrSexChinese[$strGender], - 'strNovelCategoryName' => str_replace("小说", "", $strSearchCategory), + 'strNovelSex' => $arrSexChinese[$strGender], + 'strNovelCategoryName' => str_replace("小说", "", $strSearchCategory), 'strNovelStatus' => $strSearchStatus, ]); @@ -199,8 +199,7 @@ class Novel extends BaseController 'strDescription' => $strDescription, ]); - - return View::fetch($strTemplate); + return $this->rending($strTemplate); } /** @@ -262,11 +261,11 @@ class Novel extends BaseController 'strKeywords' => $strKeywords, 'strDescription' => $strDescription, ]); - if ($boolIsMobile) { - return View::fetch(); - } else { - return View::fetch('pc/getNovelChannel'); - } + + + $strView = $boolIsMobile ? '' : 'pc/getNovelChannel'; + + return $this->rending($strView); } /** @@ -414,7 +413,7 @@ class Novel extends BaseController 'strNovelName' => $arrNovel['og_novel_book_name'], 'strNovelAuthor' => $arrNovel['og_novel_author'], 'strNovelCategoryName' => $arrNovel['og_novel_category'], - 'strNovelSex' => $arrNovel['category_sex'] == 'man' ? '男生' : '女生', + 'strNovelSex' => $arrNovel['category_sex'] == 'man' ? '男生' : '女生', 'strNovelStatus' => $arrNovel['og_novel_status'], 'strNovelDescription' => $arrNovel['n_page_description'], ]); @@ -444,13 +443,11 @@ class Novel extends BaseController 'strKeywords' => $strKeywords, 'strDescription' => $strDescription, ]); - - if ($boolIsMobile) { - return View::fetch('getNovelInfo'); - } else { - return View::fetch('pc/getNovelInfo'); - } + + $strView = $boolIsMobile ? 'getNovelInfo' : 'pc/getNovelInfo'; + + return $this->rending($strView); } /** @@ -511,7 +508,7 @@ class Novel extends BaseController 'strNovelName' => $arrNovel['og_novel_book_name'], 'strNovelAuthor' => $arrNovel['og_novel_author'], 'strNovelCategoryName' => $arrNovel['og_novel_category'], - 'strNovelSex' => $arrNovel['category_sex'] == 'man' ? '男生' : '女生', + 'strNovelSex' => $arrNovel['category_sex'] == 'man' ? '男生' : '女生', 'strNovelStatus' => $arrNovel['og_novel_status'], 'strNovelDescription' => $arrNovel['n_page_description'], ]); @@ -536,11 +533,10 @@ class Novel extends BaseController 'strKeywords' => $strKeywords, 'strDescription' => $strDescription, ]); - if ($boolIsMobile) { - return View::fetch(); - } else { - return View::fetch('pc/getNovelInfo'); - } + + $strView = $boolIsMobile ? '' : 'pc/getNovelInfo'; + + return $this->rending($strView); } /** @@ -626,11 +622,10 @@ class Novel extends BaseController 'strKeywords' => $strKeywords, 'strDescription' => $strDescription, ]); - if ($boolIsMobile) { - return View::fetch('getNovelChapter'); - } else { - return View::fetch('pc/getNovelChapter'); - } + + $strView = $boolIsMobile ? 'getNovelChapter' : 'pc/getNovelChapter'; + + return $this->rending($strView); } @@ -702,11 +697,10 @@ class Novel extends BaseController 'strKeywords' => $strKeywords, 'strDescription' => $strDescription, ]); - if ($boolIsMobile) { - return View::fetch(); - } else { - return View::fetch('pc/getNovelChapter'); - } + + $strView = $boolIsMobile ? '' : 'pc/getNovelChapter'; + + return $this->rending($strView); } /** @@ -754,7 +748,7 @@ class Novel extends BaseController // 更新值 ConverterMovel::setVal([ 'intPage' => $intPage, - 'strNovelSex' => $arrNovel['category_sex'] == 'man' ? '男生' : '女生', + 'strNovelSex' => $arrNovel['category_sex'] == 'man' ? '男生' : '女生', 'strNovelName' => $arrNovel['og_novel_book_name'], 'strNovelAuthor' => $arrNovel['og_novel_author'], 'strNovelCategoryName' => $arrNovel['og_novel_category'], @@ -783,11 +777,11 @@ class Novel extends BaseController 'strKeywords' => $strKeywords, 'strDescription' => $strDescription, ]); - if ($boolIsMobile) { - return View::fetch(); - } else { - return View::fetch('pc/getNovelChapterAll'); - } + + + $strView = $boolIsMobile ? '' : 'pc/getNovelChapterAll'; + + return $this->rending($strView); } /** @@ -832,9 +826,9 @@ class Novel extends BaseController ConverterMovel::setVal([ 'intPage' => $intPage, 'strSearchKeywords' => $strSearchKeywords, - // FIXED 如果不知道怎么做,就不要用这个模板,你现在太过依赖这个模板,这个模板如果是一个刚毕业的大学生的垃圾论文项目,你也被他的四维锁死? - // 这个和模板没有关系, 昨天 grok 使用超限制了,使用you.com 提供的 tkd 设计,它设计的 tkd模板 需要的 字段比较多,那几个 性别 和 分类 放在搜索是不太合理 - // 现在改了,使用grok 设计的 ,ai 记录在 app/home/view/kuangyu/推广SEO过程设计记录/TKD/搜索页Tkd.md + // FIXED 如果不知道怎么做,就不要用这个模板,你现在太过依赖这个模板,这个模板如果是一个刚毕业的大学生的垃圾论文项目,你也被他的四维锁死? + // 这个和模板没有关系, 昨天 grok 使用超限制了,使用you.com 提供的 tkd 设计,它设计的 tkd模板 需要的 字段比较多,那几个 性别 和 分类 放在搜索是不太合理 + // 现在改了,使用grok 设计的 ,ai 记录在 app/home/view/kuangyu/推广SEO过程设计记录/TKD/搜索页Tkd.md ]); $strTitleTemplate = $Request->DomainModel->getFomartSubject(getFomartSubjectKey(__METHOD__) . '@TITLE'); @@ -856,12 +850,10 @@ class Novel extends BaseController 'strKeywords' => $strKeywords, 'strDescription' => $strDescription, ]); + + $strView = $boolIsMobile ? '' : 'pc/getSearchNovel'; - if ($boolIsMobile) { - return View::fetch(); - } else { - return View::fetch('pc/getSearchNovel'); - } + return $this->rending($strView); } /**