Файловый менеджер - Редактировать - /home/clickysoft/public_html/assets.clickysoft.net/app/Http/Requests/UpdateBranchRequest.php
Назад
<?php namespace App\Http\Requests; use App\Models\Branch; use Gate; use Illuminate\Foundation\Http\FormRequest; use Illuminate\Http\Response; class UpdateBranchRequest extends FormRequest { public function authorize() { return Gate::allows('branch_edit'); } public function rules() { return [ 'company_id' => [ 'required', 'integer', 'exists:companies,id,organization_id,' . auth()->user()->organization_id, ], 'name' => [ 'required', 'string', 'min:1', 'max:50', ], 'email' => [ 'nullable', 'string', 'max:255', ], 'contact_number' => [ 'nullable', 'string', 'min:10', 'max:12', ], 'address_line_1' => [ 'nullable', 'string', 'min:1', 'max:100', ], 'address_line_2' => [ 'nullable', 'string', 'min:1', 'max:100', ], 'city' => [ 'nullable', 'string', 'min:1', 'max:50', ], 'state' => [ 'nullable', 'string', 'min:1', 'max:50', ], 'zip' => [ 'nullable', 'string', 'min:1', 'max:15', ], 'country_id' => [ 'required', 'integer', 'exists:countries,id', ], ]; } public function attributes() { return [ 'company_id' => 'Company', 'name' => 'Branch name', 'email' => 'Email', 'contact_number' => 'Contact number', 'address_line_1' => 'Address line 1', 'address_line_2' => 'Address line 2', 'city' => 'City', 'state' => 'State', 'zip' => 'Zip', 'country_id' => 'Country', ]; } }
| ver. 1.4 |
Github
|
.
| PHP 8.1.29 | Генерация страницы: 0 |
proxy
|
phpinfo
|
Настройка