本文整理匯總了PHP中app\Setting::get方法的典型用法代碼示例。如果您正苦於以下問題:PHP Setting::get方法的具體用法?PHP Setting::get怎麽用?PHP Setting::get使用的例子?那麽, 這裏精選的方法代碼示例或許可以為您提供幫助。您也可以進一步了解該方法所在類app\Setting
的用法示例。
在下文中一共展示了Setting::get方法的4個代碼示例,這些例子默認根據受歡迎程度排序。您可以為喜歡或者感覺有用的代碼點讚,您的評價將有助於係統推薦出更棒的PHP代碼示例。
示例1: balance_currency
/**
* Баланс пользователя в валюте пользователя
* @return float
*/
public function balance_currency()
{
$currency = $this->currency;
$course = Setting::get($currency . '_course', 1);
$balance = $this->balance / $course;
return $balance;
}
示例2: handle
/**
* Handle an incoming request.
*
* @param \Illuminate\Http\Request $request
* @param \Closure $next
* @return mixed
*/
public function handle($request, Closure $next)
{
if (\Auth::check()) {
\View::share('user', \Auth::user());
}
\View::share('title', Setting::get('title'));
\View::share('main', 0);
return $next($request);
}
示例3: __construct
public function __construct()
{
$balance = Auth::user()->balance_display();
view()->share('user_balance', $balance);
$products = Auth::user()->list_active_products;
view()->share('user_need_products', count($products));
$members = Setting::get('members', '23 541');
view()->share('members', $members);
$best_member = Setting::get('best_member', 'Andrey87 - 3 400 руб.');
view()->share('best_member', $best_member);
}
示例4: settings
/**
* Display a settings edition screen
*
* @return \Illuminate\Http\Response
*/
public function settings()
{
return view('settings.list')->with('homepage_presentation', \App\Setting::get('homepage_presentation'));
}