Added user locale to REST API GET /api/users response; (#9486)
* Clearer reporting on import Signed-off-by: snipe <snipe@snipe.net> * Try adding text/x-Algol68 to import Signed-off-by: snipe <snipe@snipe.net> * Added user locale to REST API GET /api/users response; Co-authored-by: snipe <snipe@snipe.net>
This commit is contained in:
@@ -49,10 +49,12 @@ class ImportController extends Controller
|
||||
if (!in_array($file->getMimeType(), array(
|
||||
'application/vnd.ms-excel',
|
||||
'text/csv',
|
||||
'application/csv',
|
||||
'text/x-Algol68', // because wtf CSV files?
|
||||
'text/plain',
|
||||
'text/comma-separated-values',
|
||||
'text/tsv'))) {
|
||||
$results['error']='File type must be CSV';
|
||||
$results['error']='File type must be CSV. Uploaded file is '.$file->getMimeType();
|
||||
return response()->json(Helper::formatStandardApiResponse('error', null, $results['error']), 500);
|
||||
}
|
||||
|
||||
|
||||
@@ -49,6 +49,7 @@ class UsersController extends Controller
|
||||
'users.jobtitle',
|
||||
'users.last_login',
|
||||
'users.last_name',
|
||||
'users.locale',
|
||||
'users.location_id',
|
||||
'users.manager_id',
|
||||
'users.notes',
|
||||
|
||||
Reference in New Issue
Block a user