public function boot() { app('view')->addNamespace('layouts', layouts_path()); Page::observe(new PageObserver()); PagePartModel::observe(new PagePartObserver()); $this->registerWidgets(); }
/** * Register any other events for your application. * * @param DispatcherContract $events * * @return void */ public function boot(DispatcherContract $events) { foreach ($this->listens() as $event => $listeners) { foreach ($listeners as $priority => $listener) { $events->listen($event, $listener, $priority); } } $events->listen('config.loaded', function () { BehaviorManager::init(); }); app('view')->addNamespace('layouts', layouts_path()); $events->listen('view.page.edit', function ($page) { WYSIWYG::loadAllEditors(); echo view('pages::parts.list')->with('page', $page); }, 999); }
public function __construct() { return parent::__construct(layouts_path()); }
public function __construct() { parent::__construct(layouts_path(), 'layouts'); }