예제 #1
0
 /**
  * Register the Alert Container instance
  */
 protected function registerAlertContainer()
 {
     $this->app->bindShared('alert', function ($app) {
         $this->loadConfigurationOptions();
         $alert = new Alert($this->getAlertHandler(), $this->getTheme());
         if ($this->options['translate_texts']) {
             $alert->setLang($app['translator']);
         }
         return $alert;
     });
 }
예제 #2
0
 /**
  * Set the translator component (this is optional)
  *
  * @param \Illuminate\Translation\Translator $lang
  * @static 
  */
 public static function setLang($lang)
 {
     return \Styde\Html\Alert\Container::setLang($lang);
 }