40 lines
794 B
PHP
40 lines
794 B
PHP
<?php
|
|
/**
|
|
* UploadRequest.php
|
|
*
|
|
* @copyright 2022 opencart.cn - All Rights Reserved
|
|
* @link http://www.guangdawangluo.com
|
|
* @author TL <mengwb@opencart.cn>
|
|
* @created 2022-08-10 14:51:27
|
|
* @modified 2022-08-10 14:51:27
|
|
*/
|
|
|
|
namespace Beike\Shop\Http\Requests;
|
|
|
|
use Illuminate\Foundation\Http\FormRequest;
|
|
|
|
class UploadRequest extends FormRequest
|
|
{
|
|
/**
|
|
* Determine if the user is authorized to make this request.
|
|
*
|
|
* @return bool
|
|
*/
|
|
public function authorize()
|
|
{
|
|
return true;
|
|
}
|
|
|
|
/**
|
|
* Get the validation rules that apply to the request.
|
|
*
|
|
* @return array
|
|
*/
|
|
public function rules()
|
|
{
|
|
return [
|
|
'file' => 'required|image|mimes:jpg,png,jpeg,gif,svg|max:2048',
|
|
];
|
|
}
|
|
}
|