FEATURE: add basic article list
This commit is contained in:
@@ -103,14 +103,20 @@ class Article extends Handler
|
||||
|
||||
$menu = \Menu::instance('mainMenu');
|
||||
|
||||
$menu->dropdown(trans('article::module.name'), function ($sub) {
|
||||
$blogSubmenu = $menu->whereTitle(trans('article::module.blog'));
|
||||
if (!$blogSubmenu) {
|
||||
$blogSubmenu = $menu->dropdown(trans('article::module.blog'), function ($sub) {
|
||||
}, 20, ['icon' => 'fa fa-fw fa-book']);
|
||||
}
|
||||
|
||||
$blogSubmenu->dropdown(trans('article::module.name'), function ($sub) {
|
||||
$sub->route('content.new', trans('article::article.new'), ['id' => self::getModuleId()], 10, ['icon' => 'fa fa-fw fa-pencil']);
|
||||
$sub->route('content.overview', trans('article::article.overview'), ['id' => self::getModuleId()], 30, ['icon' => 'fa fa-fw fa-book']);
|
||||
}, 10, ['icon' => 'fa fa-fw fa-book']);
|
||||
|
||||
$menu->dropdown(trans('article::module.comments'), function ($sub) {
|
||||
$blogSubmenu->dropdown(trans('article::module.comments'), function ($sub) {
|
||||
$sub->route('comments.overview', trans('article::module.commentsOverview'), [], 10, ['icon' => 'fa fa-fw fa-commenting-o']);
|
||||
}, 10, ['icon' => 'fa fa-fw fa-comments-o']);
|
||||
}, 20, ['icon' => 'fa fa-fw fa-comments-o']);
|
||||
}
|
||||
|
||||
public static function getModuleId()
|
||||
|
||||
Reference in New Issue
Block a user