This commit is contained in:
Default
2025-03-28 21:56:51 +08:00
parent 817dadf876
commit 04005aba7c
11 changed files with 251 additions and 55 deletions

View File

@@ -13,7 +13,7 @@ class Novel extends BaseController
{
public function index()
{
return View::fetch();
}
@@ -120,10 +120,10 @@ class Novel extends BaseController
}
// 书库 [:strNovelChannel]-[:intCategoryId]-[:strStatus]-[:strTextNumber]-[:strUpdateTime]-[:strSort]
public function getLibrary(Request $Request,$strNovelChannel=null,$intCategoryId=null,$strStatus=null,$strTextNumber=null,$strUpdateTime=null,$strSort=null,$intPage=1)
public function getLibrary(Request $Request, $strNovelChannel = null, $intCategoryId = null, $strStatus = null, $strTextNumber = null, $strUpdateTime = null, $strSort = null, $intPage = 1)
{
$boolIsMobile = $Request->param('boolIsMobile');
// 模拟数据
$arrNovel = [
['id' => 1, 'name' => '小说1', 'author' => '作者1'],
@@ -151,7 +151,7 @@ class Novel extends BaseController
public function getBookShelf(Request $Request)
{
$boolIsMobile = $Request->param('boolIsMobile');
// 模拟数据
$arrNewsNovel = [
['id' => 1, 'name' => '小说1', 'author' => '作者1'],
@@ -180,7 +180,7 @@ class Novel extends BaseController
{
$boolIsMobile = $Request->param('boolIsMobile');
$strNovelChannel = $Request->param('strChannel'); // 区分男生/女生频道
// 模拟数据-推荐等级为9的连载的男生频道/女生频道, 随机12个小说
$arrRecommendSerializationNovel = [
['id' => 1, 'name' => '小说1', 'author' => '作者1'],
@@ -206,8 +206,8 @@ class Novel extends BaseController
['id' => 6, 'name' => '小说3', 'author' => '作者3'],
['id' => 7, 'name' => '小说3', 'author' => '作者3'],
['id' => 8, 'name' => '小说3', 'author' => '作者3'],
];
];
// 模拟数据-最近更新-随机50
$arrNewsUpdateNovel = [
@@ -246,13 +246,13 @@ class Novel extends BaseController
return View::fetch('pc/getNovelChannel');
}
}
// 分类
public function getNovelCategory(Request $Request)
{
$boolIsMobile = $Request->param('boolIsMobile');
$strChannel = $Request->param('strChannel'); // 区分男生 / 女生频道
// 模拟数据-推荐等级为9的连载的男生频道/女生频道, 随机12个小说
$arrRecommendSerializationNovel = [
['id' => 1, 'name' => '小说1', 'author' => '作者1'],
@@ -278,8 +278,8 @@ class Novel extends BaseController
['id' => 6, 'name' => '小说3', 'author' => '作者3'],
['id' => 7, 'name' => '小说3', 'author' => '作者3'],
['id' => 8, 'name' => '小说3', 'author' => '作者3'],
];
];
// 模拟数据-最近更新-随机50
$arrNewsUpdateNovel = [
@@ -320,10 +320,14 @@ class Novel extends BaseController
}
// 小说详情
public function getNovelInfo(Request $Request,$intNovelId = 1)
public function getNovelInfo(Request $Request)
{
$intNId = $Request->param('n_id');
$boolIsMobile = $Request->param('boolIsMobile');
// 模拟数据-随机推荐数据10条
$arrRecommendNovel = [
['id' => 1, 'name' => '小说1', 'author' => '作者1'],
@@ -340,7 +344,7 @@ class Novel extends BaseController
// 相邻推荐->关联的 kan 数据
// 精品推荐->同分类随机10条数据
// 最新要点->取新意章节, 随机提取一部分内容 大概150字数
View::assign([
'arrRecommendNovel' => $arrRecommendNovel,
@@ -357,7 +361,7 @@ class Novel extends BaseController
public function getNovelChapter(Request $Request, $intNovelId = 1, $intChapterId = 1, $intChapterPage = 1)
{
$boolIsMobile = $Request->param('boolIsMobile');
// 模拟数据
$arrNewsNovel = [
['id' => 1, 'name' => '小说1', 'author' => '作者1'],
@@ -385,7 +389,7 @@ class Novel extends BaseController
public function getNovelChapterAll(Request $Request)
{
$boolIsMobile = $Request->param('boolIsMobile');
// 模拟数据
$arrNovelChapterAll = [
['id' => 1, 'name' => '小说1', 'author' => '作者1'],
@@ -409,13 +413,13 @@ class Novel extends BaseController
}
}
// 小说章节-搜索
public function getSearchNovel(Request $Request)
{
$boolIsMobile = $Request->param('boolIsMobile');
// 模拟数据
$arrSearchNovel = [
['id' => 1, 'name' => '小说1', 'author' => '作者1'],
@@ -440,10 +444,10 @@ class Novel extends BaseController
}
// 小说章节-文章-自定义页面-列表
public function getArticleList(Request $Request,$intCategoryId = null ,$intPage = 1)
public function getArticleList(Request $Request, $intCategoryId = null, $intPage = 1)
{
$boolIsMobile = $Request->param('boolIsMobile');
// 模拟数据
$arrNewsNovel = [
['id' => 1, 'name' => '小说1', 'author' => '作者1'],
@@ -468,10 +472,10 @@ class Novel extends BaseController
}
// 小说章节-文章-自定义页面-详情
public function getArticleInfo(Request $Request,$intArticleId)
public function getArticleInfo(Request $Request, $intArticleId)
{
$boolIsMobile = $Request->param('boolIsMobile');
// 模拟数据
$arrNewsNovel = [
['id' => 1, 'name' => '小说1', 'author' => '作者1'],
@@ -494,7 +498,4 @@ class Novel extends BaseController
return View::fetch('pc/getArticleInfo');
}
}
}