本文整理匯總了PHP中App\Http\Requests\Request::__construct方法的典型用法代碼示例。如果您正苦於以下問題:PHP Request::__construct方法的具體用法?PHP Request::__construct怎麽用?PHP Request::__construct使用的例子?那麽, 這裏精選的方法代碼示例或許可以為您提供幫助。您也可以進一步了解該方法所在類App\Http\Requests\Request
的用法示例。
在下文中一共展示了Request::__construct方法的7個代碼示例,這些例子默認根據受歡迎程度排序。您可以為喜歡或者感覺有用的代碼點讚,您的評價將有助於係統推薦出更棒的PHP代碼示例。
示例1: __construct
public function __construct(array $query = array(), array $request = array(), array $attributes = array(), array $cookies = array(), array $files = array(), array $server = array(), $content = null)
{
parent::__construct($query, $request, $attributes, $cookies, $files, $server, $content);
$this->min = config('options.cantidad_cursos.min');
$this->max = config('options.cantidad_cursos.max');
}
示例2: __construct
/**
* Class constructor.
*
* @param array
* @return void
*/
public function __construct($rules = [])
{
parent::__construct(['name' => [_('Name'), 'required|max:255|unique:roles,name{excludeCurrentId}'], 'is_default' => [_('Default'), 'required|integer|min:0|max:1']]);
}
示例3: __construct
/**
* Class constructor.
*
* @param array
* @return void
*/
public function __construct($rules = [])
{
parent::__construct(['name' => [_('Name'), 'required|max:255|unique:providers,name{excludeCurrentId}']]);
}
示例4: __construct
/**
* CreateRequest constructor.
*
* @param AccountRepository $accountRepository
*/
public function __construct(AccountRepository $accountRepository)
{
parent::__construct();
$this->accountRepository = $accountRepository;
}
示例5: __construct
/**
* Class constructor.
*
* @param array
* @return void
*/
public function __construct($rules = [])
{
parent::__construct(['category_id' => [_('Category'), 'integer|exists:categories,id'], 'name' => [_('Name'), 'required|max:255'], 'source' => [_('Content'), 'required']]);
}
示例6: __construct
public function __construct()
{
parent::__construct();
$this->customer = \Helper::getCustomerOrFail();
// $this->customer = Customer::find(1);
}
示例7: __construct
/**
* Class constructor.
*
* @param array
* @return void
*/
public function __construct($rules = [])
{
parent::__construct(['code' => [_('Code'), 'required|size:2|regex:/^[a-z]+$/|unique:languages,code{excludeCurrentId}'], 'name' => [_('Name'), 'required|max:255|unique:languages,name{excludeCurrentId}'], 'native_name' => [_('Native name'), 'required|max:255|alpha|unique:languages,native_name{excludeCurrentId}'], 'locale' => [_('Locale'), 'required|size:5|regex:/^[a-z]+_[A-Z]+$/'], 'is_default' => [_('Default'), 'required|integer|min:0|max:1']]);
}