/
ximain1
/
tpu-backend
Обзор
Документация
Войти
/
ximain1
/
tpu-backend
Код
Запросы
0
Задачи
Вики
Пакеты
0
Релизы
0
CI/CD
Аналитика
Безопасность
develop
app/Http/Requests/TrainWorkRequest.php
34 строки
876 B
Попехин Константин Сергеевич
Корректировка валидаторов и создания записей
30 дек 2025, 17:31
30 дек 2025, 17:31
d9280a3
Код
Авторство
О чём код?
<?php namespace App\Http\Requests; use Illuminate\Foundation\Http\FormRequest; class TrainWorkRequest 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<mixed>|string> */ public function rules(): array { return [ 'date' => 'required|integer', 'shift_id' => 'required|integer', 'shoulder' => 'required', 'start_time' => 'required|date_format:H:i', 'end_time' => 'required|date_format:H:i', 'route_sheet_id' => 'required|integer', 'train_weight' => 'required|integer', ]; } }