예제 #1
0
 public function __construct(Application $app)
 {
     $this->app_name = 'cms';
     parent::__construct($app);
     $app->register(new SessionServiceProvider());
     $app->register(new ValidatorServiceProvider());
     // TODO: Requires additional setup.
     //$app->register(new SecurityServiceProvider());
     $app->register(new SwiftmailerServiceProvider());
     $this->app_view = $this->registerView(new AppView($this), $app);
     $this->exhibit_model = new ExhibitModel($this);
     $this->exhibit_model->is_public = false;
     $app->register($this->exhibit_model);
 }
예제 #2
0
 public function __construct(Application $app)
 {
     $this->app_name = 'site';
     $this->templater = true;
     $this->component_names = array('exhibit', 'plugin');
     parent::__construct($app);
     $this->exhibit_model = new ExhibitModel($this);
     $app->register($this->exhibit_model);
     // Override default dedicated `templater`.
     $this->templater = $this->registerTemplater($app, 'templater', array('template_path' => "{$this->paths['app_web']}/mustache", 'partial_path' => "{$this->paths['theme_web']}/mustache"));
     $app->register(new ExhibitWidgetFactory());
     $app->register(new PluginFactoryServiceProvider());
     $this->registerComponentFactories($app);
     $this->exhibit_view = $this->registerView(new ExhibitView($this), $app);
 }