2020-04-04 23:07:09 +00:00
|
|
|
<?php
|
|
|
|
|
|
|
|
namespace Pterodactyl\Http\Requests\Api\Remote;
|
|
|
|
|
|
|
|
use Illuminate\Foundation\Http\FormRequest;
|
|
|
|
|
|
|
|
class ReportBackupCompleteRequest extends FormRequest
|
|
|
|
{
|
|
|
|
/**
|
|
|
|
* @return string[]
|
|
|
|
*/
|
|
|
|
public function rules()
|
|
|
|
{
|
|
|
|
return [
|
2021-08-04 02:45:25 +00:00
|
|
|
'successful' => 'required|boolean',
|
2020-04-19 06:26:59 +00:00
|
|
|
'checksum' => 'nullable|string|required_if:successful,true',
|
2020-08-28 02:35:22 +00:00
|
|
|
'checksum_type' => 'nullable|string|required_if:successful,true',
|
2020-04-19 06:26:59 +00:00
|
|
|
'size' => 'nullable|numeric|required_if:successful,true',
|
2022-09-26 17:15:52 +00:00
|
|
|
'parts' => 'nullable|array',
|
|
|
|
'parts.*.etag' => 'required|string',
|
|
|
|
'parts.*.part_number' => 'required|numeric',
|
2020-04-04 23:07:09 +00:00
|
|
|
];
|
|
|
|
}
|
|
|
|
}
|