External_Registration> No esta derivando el archivo adjunto en File
This commit is contained in:
dheeyi william
2016-09-22 12:21:01 -04:00
parent 91d5605365
commit b77cffd129

View File

@@ -3675,7 +3675,7 @@ class Cases
* @param string $fileSize File size ($_FILES["form"]["size"]["APP_DOC_FILENAME"] or 0) * @param string $fileSize File size ($_FILES["form"]["size"]["APP_DOC_FILENAME"] or 0)
* @return string Return application document ID * @return string Return application document ID
*/ */
public function addInputDocument($inputDocumentUid, $appDocUid, $docVersion, $appDocType, $appDocComment, $inputDocumentAction, $applicationUid, $delIndex, $taskUid, $userUid, $option, $file, $fileError = 0, $fileTmpName = null, $fileSize = 0) public function addInputDocument($inputDocumentUid, $appDocUid, $docVersion, $appDocType, $appDocComment, $inputDocumentAction, $applicationUid, $delIndex, $taskUid, $userUid, $option, $file, $fileError = 0, $fileTmpName = null, $fileSize = 0, $isInputDocumentOfGrid = false)
{ {
$appDocFileName = null; $appDocFileName = null;
$sw = 0; $sw = 0;
@@ -3701,28 +3701,32 @@ class Cases
return null; return null;
} }
//Info $folderId = '';
$inputDocument = new InputDocument(); $tags = '';
$arrayInputDocumentData = $inputDocument->load($inputDocumentUid);
//--- Validate Filesize of $_FILE if (!$isInputDocumentOfGrid) {
$inpDocMaxFilesize = $arrayInputDocumentData["INP_DOC_MAX_FILESIZE"]; //Info
$inpDocMaxFilesizeUnit = $arrayInputDocumentData["INP_DOC_MAX_FILESIZE_UNIT"]; $inputDocument = new InputDocument();
$arrayInputDocumentData = $inputDocument->load($inputDocumentUid);
$inpDocMaxFilesize = $inpDocMaxFilesize * (($inpDocMaxFilesizeUnit == "MB")? 1024 *1024 : 1024); //Bytes //--- Validate Filesize of $_FILE
$inpDocMaxFilesize = $arrayInputDocumentData["INP_DOC_MAX_FILESIZE"];
$inpDocMaxFilesizeUnit = $arrayInputDocumentData["INP_DOC_MAX_FILESIZE_UNIT"];
if ($inpDocMaxFilesize > 0 && $fileSize > 0) { $inpDocMaxFilesize = $inpDocMaxFilesize * (($inpDocMaxFilesizeUnit == "MB") ? 1024 * 1024 : 1024); //Bytes
if ($fileSize > $inpDocMaxFilesize) {
throw new Exception(G::LoadTranslation("ID_SIZE_VERY_LARGE_PERMITTED")); if ($inpDocMaxFilesize > 0 && $fileSize > 0) {
if ($fileSize > $inpDocMaxFilesize) {
throw new Exception(G::LoadTranslation("ID_SIZE_VERY_LARGE_PERMITTED"));
}
} }
//Get the Custom Folder ID (create if necessary)
$appFolder = new AppFolder();
$folderId = $appFolder->createFromPath($arrayInputDocumentData["INP_DOC_DESTINATION_PATH"], $applicationUid);
$tags = $appFolder->parseTags($arrayInputDocumentData["INP_DOC_TAGS"], $applicationUid);
} }
//Get the Custom Folder ID (create if necessary)
$appFolder = new AppFolder();
$folderId = $appFolder->createFromPath($arrayInputDocumentData["INP_DOC_DESTINATION_PATH"], $applicationUid);
$tags = $appFolder->parseTags($arrayInputDocumentData["INP_DOC_TAGS"], $applicationUid);
$appDocument = new AppDocument(); $appDocument = new AppDocument();
$arrayField = array(); $arrayField = array();