mirror of
https://git.code.sf.net/p/seeddms/code
synced 2025-02-06 15:14:58 +00:00
Merge branch 'seeddms-5.1.x' into seeddms-6.0.x
This commit is contained in:
commit
8ae40fbc9e
|
@ -148,6 +148,7 @@
|
||||||
Changes in version 5.1.17
|
Changes in version 5.1.17
|
||||||
--------------------------------------------------------------------------------
|
--------------------------------------------------------------------------------
|
||||||
- new version 5.16.2 of fine uploader
|
- new version 5.16.2 of fine uploader
|
||||||
|
- obey max_upload_size whenever a file is uploaded
|
||||||
|
|
||||||
--------------------------------------------------------------------------------
|
--------------------------------------------------------------------------------
|
||||||
Changes in version 5.1.16
|
Changes in version 5.1.16
|
||||||
|
|
|
@ -1062,8 +1062,8 @@ class SeedDMS_Core_DMS {
|
||||||
* 'AppRevOwner', 'ReceiptByMe', 'ReviseByMe', 'LockedByMe', 'MyDocs'
|
* 'AppRevOwner', 'ReceiptByMe', 'ReviseByMe', 'LockedByMe', 'MyDocs'
|
||||||
* @param SeedDMS_Core_User $param1 user
|
* @param SeedDMS_Core_User $param1 user
|
||||||
* @param bool $param2 set to true
|
* @param bool $param2 set to true
|
||||||
* if 'AppRevByMe', 'ReviseByMe', 'ReceiptByMe' shall return even documents
|
* if 'ReviewByMe', 'ApproveByMe', 'AppRevByMe', 'ReviseByMe', 'ReceiptByMe'
|
||||||
* І have already taken care of.
|
* shall return even documents І have already taken care of.
|
||||||
* @param string $param3 sort list by this field
|
* @param string $param3 sort list by this field
|
||||||
* @param string $param4 order direction
|
* @param string $param4 order direction
|
||||||
* @return array|bool
|
* @return array|bool
|
||||||
|
@ -1101,7 +1101,7 @@ class SeedDMS_Core_DMS {
|
||||||
* It doesn't need the where clause anymore. Hence the statement could be
|
* It doesn't need the where clause anymore. Hence the statement could be
|
||||||
* extended with further left joins.
|
* extended with further left joins.
|
||||||
*/
|
*/
|
||||||
$selectStr = "SELECT `tblDocuments`.*, `tblDocumentLocks`.`userID` as `lockUser`, ".
|
$selectStr = "`tblDocuments`.*, `tblDocumentLocks`.`userID` as `lockUser`, ".
|
||||||
"`tblDocumentContent`.`version`, `tblDocumentStatus`.*, `tblDocumentStatusLog`.`status`, ".
|
"`tblDocumentContent`.`version`, `tblDocumentStatus`.*, `tblDocumentStatusLog`.`status`, ".
|
||||||
"`tblDocumentStatusLog`.`comment` AS `statusComment`, `tblDocumentStatusLog`.`date` as `statusDate`, ".
|
"`tblDocumentStatusLog`.`comment` AS `statusComment`, `tblDocumentStatusLog`.`date` as `statusDate`, ".
|
||||||
"`tblDocumentStatusLog`.`userID`, `oTbl`.`fullName` AS `ownerName`, `sTbl`.`fullName` AS `statusName` ";
|
"`tblDocumentStatusLog`.`userID`, `oTbl`.`fullName` AS `ownerName`, `sTbl`.`fullName` AS `statusName` ";
|
||||||
|
@ -1176,9 +1176,11 @@ class SeedDMS_Core_DMS {
|
||||||
$orderdir = 'ASC';
|
$orderdir = 'ASC';
|
||||||
|
|
||||||
$groups = array();
|
$groups = array();
|
||||||
$tmp = $user->getGroups();
|
if($user) {
|
||||||
foreach($tmp as $group)
|
$tmp = $user->getGroups();
|
||||||
$groups[] = $group->getID();
|
foreach($tmp as $group)
|
||||||
|
$groups[] = $group->getID();
|
||||||
|
}
|
||||||
|
|
||||||
$selectStr .= ", `tblDocumentReviewLog`.`date` as `duedate` ";
|
$selectStr .= ", `tblDocumentReviewLog`.`date` as `duedate` ";
|
||||||
$queryStr .=
|
$queryStr .=
|
||||||
|
@ -1187,10 +1189,12 @@ class SeedDMS_Core_DMS {
|
||||||
"LEFT JOIN `tblDocumentReviewLog` ON `tblDocumentReviewLog`.`reviewLogID`=`ttreviewid`.`maxLogID` ";
|
"LEFT JOIN `tblDocumentReviewLog` ON `tblDocumentReviewLog`.`reviewLogID`=`ttreviewid`.`maxLogID` ";
|
||||||
|
|
||||||
if(1) {
|
if(1) {
|
||||||
$queryStr .= "WHERE (`tblDocumentReviewers`.`type` = 0 AND `tblDocumentReviewers`.`required` = ".$user->getID()." ";
|
if($user) {
|
||||||
if($groups)
|
$queryStr .= "WHERE (`tblDocumentReviewers`.`type` = 0 AND `tblDocumentReviewers`.`required` = ".$user->getID()." ";
|
||||||
$queryStr .= "OR `tblDocumentReviewers`.`type` = 1 AND `tblDocumentReviewers`.`required` IN (".implode(',', $groups).") ";
|
if($groups)
|
||||||
$queryStr .= ") ";
|
$queryStr .= "OR `tblDocumentReviewers`.`type` = 1 AND `tblDocumentReviewers`.`required` IN (".implode(',', $groups).") ";
|
||||||
|
$queryStr .= ") ";
|
||||||
|
}
|
||||||
$queryStr .= "AND `tblDocumentStatusLog`.`status` IN (".S_DRAFT_REV.", ".S_EXPIRED.") ";
|
$queryStr .= "AND `tblDocumentStatusLog`.`status` IN (".S_DRAFT_REV.", ".S_EXPIRED.") ";
|
||||||
if(!$param2)
|
if(!$param2)
|
||||||
$queryStr .= " AND `tblDocumentReviewLog`.`status` = 0 ";
|
$queryStr .= " AND `tblDocumentReviewLog`.`status` = 0 ";
|
||||||
|
@ -1251,9 +1255,11 @@ class SeedDMS_Core_DMS {
|
||||||
$orderdir = 'ASC';
|
$orderdir = 'ASC';
|
||||||
|
|
||||||
$groups = array();
|
$groups = array();
|
||||||
$tmp = $user->getGroups();
|
if($user) {
|
||||||
foreach($tmp as $group)
|
$tmp = $user->getGroups();
|
||||||
$groups[] = $group->getID();
|
foreach($tmp as $group)
|
||||||
|
$groups[] = $group->getID();
|
||||||
|
}
|
||||||
|
|
||||||
$selectStr .= ", `tblDocumentApproveLog`.`date` as `duedate` ";
|
$selectStr .= ", `tblDocumentApproveLog`.`date` as `duedate` ";
|
||||||
$queryStr .=
|
$queryStr .=
|
||||||
|
@ -1262,10 +1268,12 @@ class SeedDMS_Core_DMS {
|
||||||
"LEFT JOIN `tblDocumentApproveLog` ON `tblDocumentApproveLog`.`approveLogID`=`ttapproveid`.`maxLogID` ";
|
"LEFT JOIN `tblDocumentApproveLog` ON `tblDocumentApproveLog`.`approveLogID`=`ttapproveid`.`maxLogID` ";
|
||||||
|
|
||||||
if(1) {
|
if(1) {
|
||||||
|
if($user) {
|
||||||
$queryStr .= "WHERE (`tblDocumentApprovers`.`type` = 0 AND `tblDocumentApprovers`.`required` = ".$user->getID()." ";
|
$queryStr .= "WHERE (`tblDocumentApprovers`.`type` = 0 AND `tblDocumentApprovers`.`required` = ".$user->getID()." ";
|
||||||
if($groups)
|
if($groups)
|
||||||
$queryStr .= "OR `tblDocumentApprovers`.`type` = 1 AND `tblDocumentApprovers`.`required` IN (".implode(',', $groups).")";
|
$queryStr .= "OR `tblDocumentApprovers`.`type` = 1 AND `tblDocumentApprovers`.`required` IN (".implode(',', $groups).")";
|
||||||
$queryStr .= ") ";
|
$queryStr .= ") ";
|
||||||
|
}
|
||||||
$queryStr .= "AND `tblDocumentStatusLog`.`status` IN (".S_DRAFT_APP.", ".S_EXPIRED.") ";
|
$queryStr .= "AND `tblDocumentStatusLog`.`status` IN (".S_DRAFT_APP.", ".S_EXPIRED.") ";
|
||||||
if(!$param2)
|
if(!$param2)
|
||||||
$queryStr .= " AND `tblDocumentApproveLog`.`status` = 0 ";
|
$queryStr .= " AND `tblDocumentApproveLog`.`status` = 0 ";
|
||||||
|
@ -1483,9 +1491,39 @@ class SeedDMS_Core_DMS {
|
||||||
$queryStr .= ", `tblDocumentContent`.`revisiondate` ASC";
|
$queryStr .= ", `tblDocumentContent`.`revisiondate` ASC";
|
||||||
break; // }}}
|
break; // }}}
|
||||||
case 'WorkflowByMe': // Documents I to trigger in Worklflow {{{
|
case 'WorkflowByMe': // Documents I to trigger in Worklflow {{{
|
||||||
$queryStr .= "WHERE 1=1 ";
|
|
||||||
|
|
||||||
$user = $param1;
|
$user = $param1;
|
||||||
|
$orderby = $param3;
|
||||||
|
if($param4 == 'desc')
|
||||||
|
$orderdir = 'DESC';
|
||||||
|
else
|
||||||
|
$orderdir = 'ASC';
|
||||||
|
|
||||||
|
if(1) {
|
||||||
|
$groups = array();
|
||||||
|
if($user) {
|
||||||
|
$tmp = $user->getGroups();
|
||||||
|
foreach($tmp as $group)
|
||||||
|
$groups[] = $group->getID();
|
||||||
|
}
|
||||||
|
$selectStr = 'distinct '.$selectStr;
|
||||||
|
$queryStr .=
|
||||||
|
"LEFT JOIN `tblWorkflowDocumentContent` on `ttcontentid`.`document`=`tblWorkflowDocumentContent`.`document` AND `ttcontentid`.`maxVersion`=`tblWorkflowDocumentContent`.`version` ".
|
||||||
|
"LEFT JOIN `tblWorkflowTransitions` on `tblWorkflowDocumentContent`.`workflow`=`tblWorkflowTransitions`.`workflow` AND `tblWorkflowDocumentContent`.`state`=`tblWorkflowTransitions`.`state` ".
|
||||||
|
"LEFT JOIN `tblWorkflowTransitionUsers` on `tblWorkflowTransitionUsers`.`transition` = `tblWorkflowTransitions`.`id` ".
|
||||||
|
"LEFT JOIN `tblWorkflowTransitionGroups` on `tblWorkflowTransitionGroups`.`transition` = `tblWorkflowTransitions`.`id` ";
|
||||||
|
|
||||||
|
if($user) {
|
||||||
|
$queryStr .= "WHERE (`tblWorkflowTransitionUsers`.`userid` = ".$user->getID()." ";
|
||||||
|
if($groups)
|
||||||
|
$queryStr .= "OR `tblWorkflowTransitionGroups`.`groupid` IN (".implode(',', $groups).")";
|
||||||
|
$queryStr .= ") ";
|
||||||
|
}
|
||||||
|
// echo 'SELECT '.$selectStr." ".$queryStr;
|
||||||
|
if ($orderby=='e') $queryStr .= "ORDER BY `expires`";
|
||||||
|
else if ($orderby=='u') $queryStr .= "ORDER BY `statusDate`";
|
||||||
|
else $queryStr .= "ORDER BY `name`";
|
||||||
|
} else {
|
||||||
|
$queryStr .= "WHERE 1=1 ";
|
||||||
// Get document list for the current user.
|
// Get document list for the current user.
|
||||||
$workflowStatus = $user->getWorkflowStatus();
|
$workflowStatus = $user->getWorkflowStatus();
|
||||||
|
|
||||||
|
@ -1515,6 +1553,7 @@ class SeedDMS_Core_DMS {
|
||||||
} else {
|
} else {
|
||||||
$queryStr = '';
|
$queryStr = '';
|
||||||
}
|
}
|
||||||
|
}
|
||||||
break; // }}}
|
break; // }}}
|
||||||
case 'AppRevOwner': // Documents waiting for review/approval/revision I'm owning {{{
|
case 'AppRevOwner': // Documents waiting for review/approval/revision I'm owning {{{
|
||||||
$queryStr .= "WHERE 1=1 ";
|
$queryStr .= "WHERE 1=1 ";
|
||||||
|
@ -1804,7 +1843,7 @@ class SeedDMS_Core_DMS {
|
||||||
}
|
}
|
||||||
|
|
||||||
if($queryStr) {
|
if($queryStr) {
|
||||||
$resArr = $this->db->getResultArray($selectStr.$queryStr);
|
$resArr = $this->db->getResultArray('SELECT '.$selectStr.$queryStr);
|
||||||
if (is_bool($resArr) && !$resArr) {
|
if (is_bool($resArr) && !$resArr) {
|
||||||
return false;
|
return false;
|
||||||
}
|
}
|
||||||
|
|
|
@ -137,8 +137,8 @@ class UI extends UI_Default {
|
||||||
$view->setParam('enablesessionlist', $settings->_enableSessionList);
|
$view->setParam('enablesessionlist', $settings->_enableSessionList);
|
||||||
$view->setParam('workflowmode', $settings->_workflowMode);
|
$view->setParam('workflowmode', $settings->_workflowMode);
|
||||||
$view->setParam('checkoutdir', $settings->_checkOutDir);
|
$view->setParam('checkoutdir', $settings->_checkOutDir);
|
||||||
$view->setParam('partitionsize', (int) $settings->_partitionSize);
|
$view->setParam('partitionsize', SeedDMS_Core_File::parse_filesize( $settings->_partitionSize));
|
||||||
$view->setParam('maxuploadsize', (int) $settings->_maxUploadSize);
|
$view->setParam('maxuploadsize', SeedDMS_Core_File::parse_filesize($settings->_maxUploadSize));
|
||||||
$view->setParam('showmissingtranslations', $settings->_showMissingTranslations);
|
$view->setParam('showmissingtranslations', $settings->_showMissingTranslations);
|
||||||
$view->setParam('defaultsearchmethod', $settings->_defaultSearchMethod);
|
$view->setParam('defaultsearchmethod', $settings->_defaultSearchMethod);
|
||||||
$view->setParam('cachedir', $settings->_cacheDir);
|
$view->setParam('cachedir', $settings->_cacheDir);
|
||||||
|
|
|
@ -408,10 +408,14 @@ if(!empty($_POST['notification_groups'])) {
|
||||||
}
|
}
|
||||||
|
|
||||||
/* Check files for Errors first */
|
/* Check files for Errors first */
|
||||||
|
$maxuploadsize = SeedDMS_Core_File::parse_filesize($settings->_maxUploadSize);
|
||||||
for ($file_num=0;$file_num<count($_FILES["userfile"]["tmp_name"]);$file_num++){
|
for ($file_num=0;$file_num<count($_FILES["userfile"]["tmp_name"]);$file_num++){
|
||||||
if ($_FILES["userfile"]["size"][$file_num]==0) {
|
if ($_FILES["userfile"]["size"][$file_num]==0) {
|
||||||
UI::exitError(getMLText("folder_title", array("foldername" => $folder->getName())),getMLText("uploading_zerosize"));
|
UI::exitError(getMLText("folder_title", array("foldername" => $folder->getName())),getMLText("uploading_zerosize"));
|
||||||
}
|
}
|
||||||
|
if ($maxuploadsize && $_FILES["userfile"]["size"][$file_num] > $maxuploadsize) {
|
||||||
|
UI::exitError(getMLText("folder_title", array("foldername" => $folder->getName())),getMLText("uploading_maxsize"));
|
||||||
|
}
|
||||||
if (/* is_uploaded_file($_FILES["userfile"]["tmp_name"][$file_num]) && */$_FILES['userfile']['error'][$file_num]!=0){
|
if (/* is_uploaded_file($_FILES["userfile"]["tmp_name"][$file_num]) && */$_FILES['userfile']['error'][$file_num]!=0){
|
||||||
UI::exitError(getMLText("folder_title", array("foldername" => $folder->getName())),getMLText("uploading_failed"));
|
UI::exitError(getMLText("folder_title", array("foldername" => $folder->getName())),getMLText("uploading_failed"));
|
||||||
}
|
}
|
||||||
|
|
|
@ -62,10 +62,14 @@ if(isset($_POST[$prefix.'-fine-uploader-uuids']) && $_POST[$prefix.'-fine-upload
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
|
$maxuploadsize = SeedDMS_Core_File::parse_filesize($settings->_maxUploadSize);
|
||||||
for ($file_num=0;$file_num<count($_FILES["userfile"]["tmp_name"]);$file_num++){
|
for ($file_num=0;$file_num<count($_FILES["userfile"]["tmp_name"]);$file_num++){
|
||||||
if ($_FILES["userfile"]["size"][$file_num]==0) {
|
if ($_FILES["userfile"]["size"][$file_num]==0) {
|
||||||
UI::exitError(getMLText("document_title", array("documentname" => $document->getName())),getMLText("uploading_zerosize"));
|
UI::exitError(getMLText("document_title", array("documentname" => $document->getName())),getMLText("uploading_zerosize"));
|
||||||
}
|
}
|
||||||
|
if ($maxuploadsize && $_FILES["userfile"]["size"][$file_num] > $maxuploadsize) {
|
||||||
|
UI::exitError(getMLText("folder_title", array("documentname" => $document->getName())),getMLText("uploading_maxsize"));
|
||||||
|
}
|
||||||
if (is_uploaded_file($_FILES["userfile"]["tmp_name"][$file_num]) && $_FILES['userfile']['error'][$file_num] != 0){
|
if (is_uploaded_file($_FILES["userfile"]["tmp_name"][$file_num]) && $_FILES['userfile']['error'][$file_num] != 0){
|
||||||
UI::exitError(getMLText("document_title", array("documentname" => $document->getName())),getMLText("uploading_failed"));
|
UI::exitError(getMLText("document_title", array("documentname" => $document->getName())),getMLText("uploading_failed"));
|
||||||
}
|
}
|
||||||
|
|
|
@ -91,6 +91,11 @@ if (isset($_FILES['userfile']) && $_FILES['userfile']['error'] == 0) {
|
||||||
if($_FILES["userfile"]["size"] == 0)
|
if($_FILES["userfile"]["size"] == 0)
|
||||||
UI::exitError(getMLText("document_title", array("documentname" => $document->getName())),getMLText("uploading_zerosize"));
|
UI::exitError(getMLText("document_title", array("documentname" => $document->getName())),getMLText("uploading_zerosize"));
|
||||||
|
|
||||||
|
$maxuploadsize = SeedDMS_Core_File::parse_filesize($settings->_maxUploadSize);
|
||||||
|
if ($maxuploadsize && $_FILES["userfile"]["size"] > $maxuploadsize) {
|
||||||
|
UI::exitError(getMLText("document_title", array("documentname" => $document->getName())),getMLText("uploading_maxsize"));
|
||||||
|
}
|
||||||
|
|
||||||
$userfiletmp = $_FILES["userfile"]["tmp_name"];
|
$userfiletmp = $_FILES["userfile"]["tmp_name"];
|
||||||
$userfiletype = $_FILES["userfile"]["type"];
|
$userfiletype = $_FILES["userfile"]["type"];
|
||||||
$userfilename = $_FILES["userfile"]["name"];
|
$userfilename = $_FILES["userfile"]["name"];
|
||||||
|
|
|
@ -91,7 +91,6 @@ if($view) {
|
||||||
$view->setParam('presetexpiration', $settings->_presetExpirationDate);
|
$view->setParam('presetexpiration', $settings->_presetExpirationDate);
|
||||||
$view->setParam('sortusersinlist', $settings->_sortUsersInList);
|
$view->setParam('sortusersinlist', $settings->_sortUsersInList);
|
||||||
$view->setParam('defaultposition', $settings->_defaultDocPosition);
|
$view->setParam('defaultposition', $settings->_defaultDocPosition);
|
||||||
$view->setParam('maxuploadsize', $settings->_maxUploadSize);
|
|
||||||
$view->setParam('orderby', $settings->_sortFoldersDefault);
|
$view->setParam('orderby', $settings->_sortFoldersDefault);
|
||||||
$view->setParam('accessobject', $accessop);
|
$view->setParam('accessobject', $accessop);
|
||||||
$view($_GET);
|
$view($_GET);
|
||||||
|
|
|
@ -158,6 +158,7 @@ $(document).ready(function() {
|
||||||
$folder = $this->params['folder'];
|
$folder = $this->params['folder'];
|
||||||
$enablelargefileupload = $this->params['enablelargefileupload'];
|
$enablelargefileupload = $this->params['enablelargefileupload'];
|
||||||
$enablemultiupload = $this->params['enablemultiupload'];
|
$enablemultiupload = $this->params['enablemultiupload'];
|
||||||
|
$maxuploadsize = $this->params['maxuploadsize'];
|
||||||
$enableadminrevapp = $this->params['enableadminrevapp'];
|
$enableadminrevapp = $this->params['enableadminrevapp'];
|
||||||
$enableownerrevapp = $this->params['enableownerrevapp'];
|
$enableownerrevapp = $this->params['enableownerrevapp'];
|
||||||
$enableselfrevapp = $this->params['enableselfrevapp'];
|
$enableselfrevapp = $this->params['enableselfrevapp'];
|
||||||
|
@ -188,7 +189,11 @@ $(document).ready(function() {
|
||||||
$this->contentStart();
|
$this->contentStart();
|
||||||
$this->pageNavigation($this->getFolderPathHTML($folder, true), "view_folder", $folder);
|
$this->pageNavigation($this->getFolderPathHTML($folder, true), "view_folder", $folder);
|
||||||
|
|
||||||
$msg = getMLText("max_upload_size").": ".ini_get( "upload_max_filesize");
|
$mus2 = SeedDMS_Core_File::parse_filesize(ini_get("upload_max_filesize"));
|
||||||
|
if($maxuploadsize && $maxuploadsize < $mus2)
|
||||||
|
$msg = getMLText("max_upload_size").": ".SeedDMS_Core_File::format_filesize($maxuploadsize);
|
||||||
|
else
|
||||||
|
$msg = getMLText("max_upload_size").": ".SeedDMS_Core_File::format_filesize($mus2);
|
||||||
$this->warningMsg($msg);
|
$this->warningMsg($msg);
|
||||||
$this->contentHeading(getMLText("add_document"));
|
$this->contentHeading(getMLText("add_document"));
|
||||||
|
|
||||||
|
|
|
@ -126,6 +126,7 @@ $(document).ready( function() {
|
||||||
$document = $this->params['document'];
|
$document = $this->params['document'];
|
||||||
$strictformcheck = $this->params['strictformcheck'];
|
$strictformcheck = $this->params['strictformcheck'];
|
||||||
$enablelargefileupload = $this->params['enablelargefileupload'];
|
$enablelargefileupload = $this->params['enablelargefileupload'];
|
||||||
|
$maxuploadsize = $this->params['maxuploadsize'];
|
||||||
|
|
||||||
$this->htmlAddHeader('<script type="text/javascript" src="../styles/'.$this->theme.'/validate/jquery.validate.js"></script>'."\n", 'js');
|
$this->htmlAddHeader('<script type="text/javascript" src="../styles/'.$this->theme.'/validate/jquery.validate.js"></script>'."\n", 'js');
|
||||||
if($enablelargefileupload) {
|
if($enablelargefileupload) {
|
||||||
|
@ -139,16 +140,13 @@ $(document).ready( function() {
|
||||||
$this->pageNavigation($this->getFolderPathHTML($folder, true, $document), "view_document", $document);
|
$this->pageNavigation($this->getFolderPathHTML($folder, true, $document), "view_document", $document);
|
||||||
|
|
||||||
$this->contentHeading(getMLText("linked_files"));
|
$this->contentHeading(getMLText("linked_files"));
|
||||||
?>
|
$mus2 = SeedDMS_Core_File::parse_filesize(ini_get("upload_max_filesize"));
|
||||||
<div class="alert alert-warning">
|
if($maxuploadsize && $maxuploadsize < $mus2)
|
||||||
<?php echo getMLText("max_upload_size").": ".ini_get( "upload_max_filesize"); ?>
|
$msg = getMLText("max_upload_size").": ".SeedDMS_Core_File::format_filesize($maxuploadsize);
|
||||||
<?php
|
else
|
||||||
if(0 && $enablelargefileupload) {
|
$msg = getMLText("max_upload_size").": ".SeedDMS_Core_File::format_filesize($mus2);
|
||||||
printf('<p>'.getMLText('link_alt_updatedocument').'</p>', "out.AddFile2.php?documentid=".$document->getId());
|
$this->warningMsg($msg);
|
||||||
}
|
|
||||||
?>
|
|
||||||
</div>
|
|
||||||
<?php
|
|
||||||
$this->contentContainerStart();
|
$this->contentContainerStart();
|
||||||
?>
|
?>
|
||||||
|
|
||||||
|
|
|
@ -212,6 +212,12 @@ console.log(element);
|
||||||
} else {
|
} else {
|
||||||
$msg = getMLText("max_upload_size").": ".ini_get( "upload_max_filesize");
|
$msg = getMLText("max_upload_size").": ".ini_get( "upload_max_filesize");
|
||||||
}
|
}
|
||||||
|
$mus2 = SeedDMS_Core_File::parse_filesize(ini_get("upload_max_filesize"));
|
||||||
|
if($maxuploadsize && $maxuploadsize < $mus2)
|
||||||
|
$msg = getMLText("max_upload_size").": ".SeedDMS_Core_File::format_filesize($maxuploadsize);
|
||||||
|
else
|
||||||
|
$msg = getMLText("max_upload_size").": ".SeedDMS_Core_File::format_filesize($mus2);
|
||||||
|
|
||||||
if(0 && $enablelargefileupload) {
|
if(0 && $enablelargefileupload) {
|
||||||
$msg .= "<p>".sprintf(getMLText('link_alt_updatedocument'), "out.AddMultiDocument.php?folderid=".$folder->getID()."&showtree=".showtree())."</p>";
|
$msg .= "<p>".sprintf(getMLText('link_alt_updatedocument'), "out.AddMultiDocument.php?folderid=".$folder->getID()."&showtree=".showtree())."</p>";
|
||||||
}
|
}
|
||||||
|
|
|
@ -1128,7 +1128,7 @@ class SeedDMS_View_ViewDocument extends SeedDMS_Bootstrap_Style {
|
||||||
echo "<td>";
|
echo "<td>";
|
||||||
if($latestContent->triggerWorkflowTransitionIsAllowed($user, $transition)) {
|
if($latestContent->triggerWorkflowTransitionIsAllowed($user, $transition)) {
|
||||||
$action = $transition->getAction();
|
$action = $transition->getAction();
|
||||||
print "<form action=\"../out/out.TriggerWorkflow.php\" method=\"get\"><input type=\"hidden\" name=\"documentid\" value=\"".$latestContent->getDocument()->getId()."\" /><input type=\"hidden\" name=\"version\" value=\"".$latestContent->getVersion()."\" /><input type=\"hidden\" name=\"transition\" value=\"".$transition->getID()."\" /><input type=\"submit\" class=\"btn\" value=\"".getMLText('action_'.strtolower($action->getName()), array(), $action->getName())."\" /></form>";
|
print "<form action=\"../out/out.TriggerWorkflow.php\" method=\"get\"><input type=\"hidden\" name=\"documentid\" value=\"".$latestContent->getDocument()->getId()."\" /><input type=\"hidden\" name=\"version\" value=\"".$latestContent->getVersion()."\" /><input type=\"hidden\" name=\"transition\" value=\"".$transition->getID()."\" /><input type=\"submit\" class=\"btn\" value=\"".getMLText('action_'.strtolower($action->getName()), array(), htmlspecialchars($action->getName()))."\" /></form>";
|
||||||
$allowedtransitions[] = $transition;
|
$allowedtransitions[] = $transition;
|
||||||
}
|
}
|
||||||
echo "</td>";
|
echo "</td>";
|
||||||
|
|
|
@ -109,6 +109,7 @@ class SeedDMS_View_ViewFolder extends SeedDMS_Bootstrap_Style {
|
||||||
$expandFolderTree = $this->params['expandFolderTree'];
|
$expandFolderTree = $this->params['expandFolderTree'];
|
||||||
$enableDropUpload = $this->params['enableDropUpload'];
|
$enableDropUpload = $this->params['enableDropUpload'];
|
||||||
$maxItemsPerPage = $this->params['maxItemsPerPage'];
|
$maxItemsPerPage = $this->params['maxItemsPerPage'];
|
||||||
|
$maxuploadsize = $this->params['maxuploadsize'];
|
||||||
$showtree = $this->params['showtree'];
|
$showtree = $this->params['showtree'];
|
||||||
$onepage = $this->params['onepage'];
|
$onepage = $this->params['onepage'];
|
||||||
$sitename = trim(strip_tags($this->params['sitename']));
|
$sitename = trim(strip_tags($this->params['sitename']));
|
||||||
|
@ -214,7 +215,11 @@ $('body').on('click', '.order-btn', function(ev) {
|
||||||
echo "SeedDMSUpload.setUrl('../op/op.Ajax.php');";
|
echo "SeedDMSUpload.setUrl('../op/op.Ajax.php');";
|
||||||
echo "SeedDMSUpload.setAbortBtnLabel('".getMLText("cancel")."');";
|
echo "SeedDMSUpload.setAbortBtnLabel('".getMLText("cancel")."');";
|
||||||
echo "SeedDMSUpload.setEditBtnLabel('".getMLText("edit_document_props")."');";
|
echo "SeedDMSUpload.setEditBtnLabel('".getMLText("edit_document_props")."');";
|
||||||
echo "SeedDMSUpload.setMaxFileSize(".SeedDMS_Core_File::parse_filesize(ini_get("upload_max_filesize")).");";
|
$mus2 = SeedDMS_Core_File::parse_filesize(ini_get("upload_max_filesize"));
|
||||||
|
if($maxuploadsize && $maxuploadsize < $mus2)
|
||||||
|
echo "SeedDMSUpload.setMaxFileSize($maxuploadsize);";
|
||||||
|
else
|
||||||
|
echo "SeedDMSUpload.setMaxFileSize($mus2);";
|
||||||
echo "SeedDMSUpload.setMaxFileSizeMsg('".getMLText("uploading_maxsize")."');";
|
echo "SeedDMSUpload.setMaxFileSizeMsg('".getMLText("uploading_maxsize")."');";
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
Loading…
Reference in New Issue
Block a user