|
@@ -196,6 +196,7 @@ class ChapterController extends BaseController
|
|
|
$this->book_info = $book_info;
|
|
|
//获取章节信息
|
|
|
$chapter = ChapterService::getChapterNameById($cid, $bid);
|
|
|
+
|
|
|
if (!$chapter) {
|
|
|
//短推长
|
|
|
$combination_chapter = $this->chapterNotExists($bid,$cid);
|
|
@@ -209,6 +210,7 @@ class ChapterController extends BaseController
|
|
|
return response()->error('QAPP_SYS_ERROR');
|
|
|
}
|
|
|
}
|
|
|
+
|
|
|
list($is_split,$is_change_chapter_name) = BookService::splitContent($bid);
|
|
|
if($is_split && ($book_info->channel_name == '男频' || $is_change_chapter_name) ){
|
|
|
$chapter->name = '第'.$chapter->sequence.'章';
|
|
@@ -243,7 +245,7 @@ class ChapterController extends BaseController
|
|
|
'uid' => $this->uid, 'bid' => $bid, 'book_name' => $book_info->book_name,
|
|
|
'cid' => $cid, 'chapter_name' => $chapter->name, 'sequence' => $chapter->sequence
|
|
|
]);
|
|
|
- return response()->item(new ChapterTransformer, $this->getChapter($bid, $cid, $chapter));
|
|
|
+ return response()->item(new ChapterTransformer, $this->getChapter($bid, $chapter->id, $chapter));
|
|
|
}
|
|
|
|
|
|
// 书籍是否限免
|