%PDF- %PDF-
Direktori : /mnt/tnb2/git/loslex/app/Http/Requests/ |
Current File : //mnt/tnb2/git/loslex/app/Http/Requests/RegistrationUpdateRequest.php |
<?php namespace App\Http\Requests; use Illuminate\Foundation\Http\FormRequest; class RegistrationUpdateRequest 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. * * @return array<string, \Illuminate\Contracts\Validation\ValidationRule|array|string> */ public function rules(): array { return [ 'user_id' => 'required|integer|exists:users,id', 'contest_id' => 'required|integer', 'contest_division_id' => 'required|integer', 'squad' => 'required|integer|declined_if:referee,on', 'licence_number' => ['nullable','string','regex:/^(AL|ZP)\d{6}$/i'], 'lexmember' => 'sometimes|accepted', 'lex_hash' => 'bail|exclude_without:lexmember,alpha_num|ascii|size:8', 'note' => 'nullable|string', 'notcomp' => 'sometimes|accepted', 'rookie' => 'sometimes|accepted', 'builder' => 'sometimes|accepted', 'referee' => 'required_if:squad,0' ]; } }