mirror of
https://github.com/FH-Complete/FHC-Core.git
synced 2026-07-19 16:02:15 +00:00
Replaced global function uploadFile with the protected method FHC_Controller->uploadFile
This commit is contained in:
@@ -286,7 +286,7 @@ class ProfilUpdate extends Auth_Controller
|
||||
$_FILES['files']['error'] = $files['error'][$i];
|
||||
$_FILES['files']['size'] = $files['size'][$i];
|
||||
|
||||
$uploadDataResult = uploadFile('files', array('jpg', 'png', 'pdf'));
|
||||
$uploadDataResult = $this->uploadFile('files', array('jpg', 'png', 'pdf'));
|
||||
|
||||
if (hasData($uploadDataResult))
|
||||
{
|
||||
|
||||
@@ -457,7 +457,7 @@ class ProfilUpdate extends FHCAPI_Controller
|
||||
$_FILES['files']['size'] = $files['size'][$i];
|
||||
|
||||
// File upload
|
||||
$uploadDataResult = uploadFile('files', array('jpg', 'png', 'pdf'));
|
||||
$uploadDataResult = $this->uploadFile('files', array('jpg', 'png', 'pdf'));
|
||||
if (isError($uploadDataResult)) $this->addError(getError($uploadDataResult));
|
||||
if (!hasData($uploadDataResult)) $this->addError('Upload failed');
|
||||
|
||||
|
||||
@@ -159,7 +159,7 @@ class Unterbrechung extends FHCAPI_Controller
|
||||
$this->load->library('DmsLib');
|
||||
|
||||
|
||||
$uploadDataResult = uploadFile('attachment', $this->config->item('unterbrechung_dms_filetypes') ?: array('*'));
|
||||
$uploadDataResult = $this->uploadFile('attachment', $this->config->item('unterbrechung_dms_filetypes') ?: array('*'));
|
||||
|
||||
$data = $this->getDataOrTerminateWithError($uploadDataResult);
|
||||
|
||||
|
||||
@@ -343,7 +343,7 @@ class Dokumente extends FHCAPI_Controller
|
||||
|
||||
$this->db->trans_start();
|
||||
|
||||
$uploadDataResult = uploadFile('anhang', array('jpg', 'png', 'pdf'));
|
||||
$uploadDataResult = $this->uploadFile('anhang', array('jpg', 'png', 'pdf'));
|
||||
if (isError($uploadDataResult))
|
||||
{
|
||||
return $this->terminateWithError(getError($uploadDataResult), self::ERROR_TYPE_GENERAL);
|
||||
|
||||
@@ -225,7 +225,7 @@ class CreateAnrechnung extends Auth_Controller
|
||||
private function _uploadFile()
|
||||
{
|
||||
// Upload document
|
||||
$uploadDataResult = uploadFile('uploadfile', array('pdf'));
|
||||
$uploadDataResult = $this->uploadFile('uploadfile', array('pdf'));
|
||||
|
||||
// If an error occurred while uploading the file
|
||||
if (isError($uploadDataResult)) return $uploadDataResult;
|
||||
|
||||
@@ -365,7 +365,7 @@ class requestAnrechnung extends Auth_Controller
|
||||
private function _uploadFile()
|
||||
{
|
||||
// Upload document
|
||||
$uploadDataResult = uploadFile('uploadfile', array('pdf'));
|
||||
$uploadDataResult = $this->uploadFile('uploadfile', array('pdf'));
|
||||
|
||||
// If an error occurred while uploading the file
|
||||
if (isError($uploadDataResult)) return $uploadDataResult;
|
||||
|
||||
Reference in New Issue
Block a user