27 lines
550 B
PHP
27 lines
550 B
PHP
|
|
<?php
|
||
|
|
|
||
|
|
namespace App\Http\Requests;
|
||
|
|
|
||
|
|
use Illuminate\Foundation\Http\FormRequest;
|
||
|
|
|
||
|
|
class StoreRouteRequest extends FormRequest
|
||
|
|
{
|
||
|
|
public function authorize(): bool
|
||
|
|
{
|
||
|
|
return true;
|
||
|
|
}
|
||
|
|
|
||
|
|
/**
|
||
|
|
* @return array<string, string>
|
||
|
|
*/
|
||
|
|
public function rules(): array
|
||
|
|
{
|
||
|
|
return [
|
||
|
|
'feed_id' => 'required|exists:feeds,id',
|
||
|
|
'platform_channel_id' => 'required|exists:platform_channels,id',
|
||
|
|
'is_active' => 'boolean',
|
||
|
|
'priority' => 'nullable|integer|min:0',
|
||
|
|
];
|
||
|
|
}
|
||
|
|
}
|