Total Complexity | 4 |
Total Lines | 46 |
Duplicated Lines | 0 % |
Changes | 0 |
1 | <?php |
||
7 | class SkillTypeRequest extends FormRequest |
||
8 | { |
||
9 | /** |
||
10 | * Determine if the user is authorized to make this request. |
||
11 | * |
||
12 | * @return bool |
||
13 | */ |
||
14 | public function authorize() |
||
18 | } |
||
19 | |||
20 | /** |
||
21 | * Get the validation rules that apply to the request. |
||
22 | * |
||
23 | * @return array |
||
24 | */ |
||
25 | public function rules() |
||
26 | { |
||
27 | return [ |
||
28 | 'shortname' => 'required|max:6|unique:skill_types', |
||
29 | 'name' => 'required|max:60|unique:skill_types', |
||
30 | ]; |
||
31 | } |
||
32 | |||
33 | /** |
||
34 | * Get the validation attributes that apply to the request. |
||
35 | * |
||
36 | * @return array |
||
37 | */ |
||
38 | public function attributes() |
||
39 | { |
||
40 | return [ |
||
41 | // |
||
42 | ]; |
||
43 | } |
||
44 | |||
45 | /** |
||
46 | * Get the validation messages that apply to the request. |
||
47 | * |
||
48 | * @return array |
||
49 | */ |
||
50 | public function messages() |
||
53 | // |
||
54 | ]; |
||
55 | } |
||
57 |