Файловый менеджер - Редактировать - /home/clickysoft/public_html/app/Http/Requests/UpdateUserRequest.php
Назад
<?php namespace App\Http\Requests; use App\Models\User; use Gate; use Illuminate\Foundation\Http\FormRequest; use Illuminate\Http\Response; class UpdateUserRequest extends FormRequest { public function authorize() { return Gate::allows('user_edit'); } public function rules() { return [ 'companies' => [ 'required', 'array', ], 'companies.*.company_id' => [ 'integer', 'exists:companies,id,organization_id,' . auth()->user()->organization_id, ], 'companies.*.branch_id' => [ 'required', 'integer', 'exists:branches,id,organization_id,' . auth()->user()->organization_id, ], 'first_name' => [ 'string', 'required', ], 'email' => [ 'required', 'unique:users,email,' . request()->route('user')->id, ], 'password' => [ 'required', ], 'contact_number' => [ 'string', 'min:10', 'max:12', 'nullable', ], 'roles' => [ 'required', 'array', ], 'roles.*' => [ 'integer', 'exists:roles,id,organization_id,' . auth()->user()->organization_id, ], ]; } }
| ver. 1.4 |
Github
|
.
| PHP 8.1.29 | Генерация страницы: 0 |
proxy
|
phpinfo
|
Настройка