|
@@ -32,12 +32,11 @@ class ArticleController extends WebBaseController
|
|
|
$this->navigationService = $navigationService;
|
|
|
}
|
|
|
|
|
|
- public function index(Request $request, $id = '1', $num = '8', $focus = '3', $recommend = '4', $other_num = '5')
|
|
|
+ public function index(Request $request, $id = '57', $num = '8', $focus = '3', $recommend = '4', $other_num = '5')
|
|
|
{
|
|
|
$key = $request->input('key');
|
|
|
$categorys = $this->articleCategoryService->getChildCategorys($id, $num);
|
|
|
- $search_id = '';
|
|
|
- if ($categorys) {
|
|
|
+ if (!$categorys->isEmpty()) {
|
|
|
$search_id = $categorys[0]->id;
|
|
|
$search_where = [];
|
|
|
$search_where['id'] = $search_id;
|