| Total Complexity | 4 |
| Total Lines | 42 |
| Duplicated Lines | 0 % |
| Changes | 0 | ||
| 1 | <?php |
||
| 16 | class FaqCategoryRequest extends FormRequest |
||
| 17 | { |
||
| 18 | /** |
||
| 19 | * Determine if the user is authorized to make this request. |
||
| 20 | * |
||
| 21 | * @return bool |
||
| 22 | */ |
||
| 23 | public function authorize() |
||
| 24 | { |
||
| 25 | return true; |
||
| 26 | } |
||
| 27 | |||
| 28 | /** |
||
| 29 | * Get the validation rules that apply to the request. |
||
| 30 | * |
||
| 31 | * @return array |
||
| 32 | */ |
||
| 33 | public function rules() |
||
| 34 | { |
||
| 35 | return [ |
||
| 36 | 'name' => 'required', |
||
| 37 | ]; |
||
| 38 | } |
||
| 39 | |||
| 40 | /** |
||
| 41 | * @return array |
||
| 42 | */ |
||
| 43 | public function messages(): array |
||
| 44 | { |
||
| 45 | return [ |
||
| 46 | 'name.required' => '请输入分类名', |
||
| 47 | ]; |
||
| 48 | } |
||
| 49 | |||
| 50 | /** |
||
| 51 | * @return array |
||
| 52 | */ |
||
| 53 | public function filldata(): array |
||
| 58 | ]; |
||
| 59 | } |
||
| 60 | } |
||
| 61 |