37 lines
855 B
PHP
37 lines
855 B
PHP
<?php
|
|
|
|
declare(strict_types=1);
|
|
|
|
namespace App\Request\Admin;
|
|
|
|
use Hyperf\Validation\Request\FormRequest;
|
|
|
|
class MemberRequest extends FormRequest
|
|
{
|
|
/**
|
|
* Determine if the user is authorized to make this request.
|
|
*/
|
|
public function authorize(): bool
|
|
{
|
|
return true;
|
|
}
|
|
|
|
/**
|
|
* Get the validation rules that apply to the request.
|
|
*/
|
|
public function rules(): array
|
|
{
|
|
return [
|
|
'limit' => 'required|integer',
|
|
'query_id' =>'sometimes|integer|exists:user,id',
|
|
'query_name' =>'sometimes|string',
|
|
'query_mobile' =>'sometimes|digits:11',
|
|
'query_city_id' => 'sometimes|integer|exists:system_city,id',
|
|
];
|
|
}
|
|
|
|
protected array $scenes = [
|
|
'list' => ['limit','query_id','query_name','query_mobile','query_city_id'],
|
|
];
|
|
}
|