1
0
mirror of https://github.com/invoiceninja/invoiceninja.git synced 2024-11-10 13:12:50 +01:00

Fixes for validation rules for exports

This commit is contained in:
David Bomba 2022-05-21 08:37:19 +10:00
parent f9c70719ae
commit dfd82520a2
3 changed files with 4 additions and 2 deletions

View File

@ -32,7 +32,7 @@ class GenericReportRequest extends Request
'end_date' => 'string|date', 'end_date' => 'string|date',
'date_key' => 'string', 'date_key' => 'string',
'date_range' => 'required|string', 'date_range' => 'required|string',
'report_keys' => 'present|array', 'report_keys' => 'required|present|array',
'send_email' => 'required|bool', 'send_email' => 'required|bool',
]; ];
} }

View File

@ -153,7 +153,7 @@ Route::group(['middleware' => ['throttle:100,1', 'api_db', 'token_auth', 'locale
Route::post('recurring_quotes/bulk', 'RecurringQuoteController@bulk')->name('recurring_quotes.bulk'); Route::post('recurring_quotes/bulk', 'RecurringQuoteController@bulk')->name('recurring_quotes.bulk');
Route::put('recurring_quotes/{recurring_quote}/upload', 'RecurringQuoteController@upload'); Route::put('recurring_quotes/{recurring_quote}/upload', 'RecurringQuoteController@upload');
Route::post('refresh', 'Auth\LoginController@refresh')->middleware('throttle:30,1'); Route::post('refresh', 'Auth\LoginController@refresh')->middleware('throttle:50,1');
Route::post('reports/clients', 'Reports\ClientReportController'); Route::post('reports/clients', 'Reports\ClientReportController');
Route::post('reports/contacts', 'Reports\ClientContactReportController'); Route::post('reports/contacts', 'Reports\ClientContactReportController');

View File

@ -45,6 +45,7 @@ class ClientCsvTest extends TestCase
$data = [ $data = [
"date_range" => "this_year", "date_range" => "this_year",
"report_keys" => [], "report_keys" => [],
"send_email" => false
]; ];
$response = $this->withHeaders([ $response = $this->withHeaders([
@ -62,6 +63,7 @@ class ClientCsvTest extends TestCase
$data = [ $data = [
"date_range" => "this_year", "date_range" => "this_year",
"report_keys" => [], "report_keys" => [],
"send_email" => false
]; ];
$response = $this->withHeaders([ $response = $this->withHeaders([