當前位置: 首頁>>代碼示例>>PHP>>正文


PHP Setting::lists方法代碼示例

本文整理匯總了PHP中Setting::lists方法的典型用法代碼示例。如果您正苦於以下問題:PHP Setting::lists方法的具體用法?PHP Setting::lists怎麽用?PHP Setting::lists使用的例子?那麽, 這裏精選的方法代碼示例或許可以為您提供幫助。您也可以進一步了解該方法所在Setting的用法示例。


在下文中一共展示了Setting::lists方法的5個代碼示例,這些例子默認根據受歡迎程度排序。您可以為喜歡或者感覺有用的代碼點讚,您的評價將有助於係統推薦出更棒的PHP代碼示例。

示例1: __construct

 /**
  * Initializer.
  *
  * @access   public
  * @return BaseController
  */
 public function __construct()
 {
     $is_admin = Request::is('admin*');
     $is_backend = Request::is('backend*');
     /* Set middleware(s) based on route URLs */
     if ($is_admin || $is_backend) {
         $this->middleware('auth');
         if ($is_backend) {
             // Backend specific middleware
             $this->middleware('auth.backend');
         }
         $this->middleware('auth.permissions');
         if (!Request::is('*users/change-password')) {
             // No validation for stale password if password is being changed
             $this->middleware('auth.pw_6_months');
         }
     }
     list($this->link_type, $this->link, $this->layout, $this->current_theme) = current_section();
     View::share('link_type', $this->link_type);
     View::share('current_theme', $this->current_theme);
     $website_settings = Setting::lists('value', 'name')->all();
     View::share('website_settings', $website_settings);
     $locale = Setting::value('language');
     App::setLocale($locale);
     Lang::setLocale($locale);
     $this->user = current_user();
     View::share('current_user', $this->user);
     View::share('current_user_companies', current_user_companies());
 }
開發者ID:doptor,項目名稱:doptor,代碼行數:35,代碼來源:BaseController.php

示例2: __construct

 /**
  * Initializer.
  *
  * @access   public
  * @return BaseController
  */
 public function __construct()
 {
     list($this->link_type, $this->link, $this->layout, $this->current_theme) = current_section();
     View::share('link_type', $this->link_type);
     View::share('current_theme', $this->current_theme);
     $website_settings = Setting::lists('value', 'name');
     View::share('website_settings', $website_settings);
     $this->user = current_user();
     View::share('current_user', $this->user);
 }
開發者ID:ratno,項目名稱:Doptor,代碼行數:16,代碼來源:BaseController.php

示例3: __construct

 /**
  * Initializer.
  *
  * @access   public
  * @return BaseController
  */
 public function __construct()
 {
     list($this->link_type, $this->link, $this->layout, $this->current_theme) = current_section();
     View::share('link_type', $this->link_type);
     View::share('current_theme', $this->current_theme);
     $website_settings = Setting::lists('value', 'name');
     View::share('website_settings', $website_settings);
     $locale = Setting::value('language');
     App::setLocale($locale);
     Lang::setLocale($locale);
     $this->user = current_user();
     View::share('current_user', $this->user);
     View::share('current_user_companies', current_user_companies());
 }
開發者ID:Kr3m,項目名稱:Doptor,代碼行數:20,代碼來源:BaseController.php

示例4: setupLayout

 protected function setupLayout()
 {
     $type_page = Type::where('status', 1)->lists('name', 'type');
     $settings = Setting::lists('value', 'name');
     View::share(['settings' => $settings, 'type_page' => $type_page]);
 }
開發者ID:ldin,項目名稱:project_kartinki,代碼行數:6,代碼來源:HomeController.php

示例5: setupLayout

 protected function setupLayout()
 {
     $type_page = Post::where('status', 1)->where('type_id', 4)->where('parent', 0)->lists('name', 'slug');
     $settings = Setting::lists('value', 'name');
     View::share(['settings' => $settings, 'type_page' => $type_page]);
 }
開發者ID:ldin,項目名稱:project_media,代碼行數:6,代碼來源:HomeController.php


注:本文中的Setting::lists方法示例由純淨天空整理自Github/MSDocs等開源代碼及文檔管理平台,相關代碼片段篩選自各路編程大神貢獻的開源項目,源碼版權歸原作者所有,傳播和使用請參考對應項目的License;未經允許,請勿轉載。