25 lines
593 B
PHP
25 lines
593 B
PHP
<?php
|
|
|
|
namespace App\Http\Requests;
|
|
|
|
use Illuminate\Foundation\Http\FormRequest;
|
|
|
|
class UpdateSimulationScenarioRequest extends FormRequest
|
|
{
|
|
public function authorize(): bool
|
|
{
|
|
return true;
|
|
}
|
|
|
|
/** @return array<string, list<mixed>> */
|
|
public function rules(): array
|
|
{
|
|
return [
|
|
'label' => ['required', 'string', 'min:1', 'max:100'],
|
|
'base' => ['required', 'numeric', 'min:0'],
|
|
'rate' => ['required', 'numeric', 'between:0,100'],
|
|
'reduction' => ['required', 'numeric', 'between:0,100'],
|
|
];
|
|
}
|
|
}
|