Backend for file uploads attached to any generic model, initially on aircraft and airports #226
This commit is contained in:
35
app/Http/Requests/UpdateFilesRequest.php
Normal file
35
app/Http/Requests/UpdateFilesRequest.php
Normal file
@@ -0,0 +1,35 @@
|
||||
<?php
|
||||
|
||||
namespace App\Http\Requests;
|
||||
|
||||
use Illuminate\Foundation\Http\FormRequest;
|
||||
|
||||
/**
|
||||
* Class CreateFilesRequest
|
||||
* @package App\Http\Requests
|
||||
*/
|
||||
class UpdateFilesRequest extends FormRequest
|
||||
{
|
||||
/**
|
||||
* Determine if the user is authorized to make this request.
|
||||
* @return bool
|
||||
*/
|
||||
public function authorize(): bool
|
||||
{
|
||||
return true;
|
||||
}
|
||||
|
||||
/**
|
||||
* Get the validation rules that apply to the request.
|
||||
* @return array
|
||||
*/
|
||||
public function rules(): array
|
||||
{
|
||||
return [
|
||||
'name' => 'required',
|
||||
'file' => 'nullable|file',
|
||||
|
||||
#'files.*' => 'required|file',
|
||||
];
|
||||
}
|
||||
}
|
||||
Reference in New Issue
Block a user