new config _enableHiddenRevApp (currently set to false)

This commit is contained in:
Uwe Steinmann 2023-10-13 19:33:25 +02:00
parent dca43ea703
commit 34697b62bd
7 changed files with 14 additions and 0 deletions

View File

@ -176,6 +176,8 @@ class Settings { /* {{{ */
var $_enableOwnerRevApp = false;
// enable/disable listing logged in user as reviewer/approver
var $_enableSelfRevApp = false;
// enable/disable hidden user as reviewer/approver
var $_enableHiddenRevApp = false;
// enable/disable update of a review/approval by the reviewer/approver
var $_enableUpdateRevApp = false;
// enable/disable removal of a review/approval by the admiistrator

View File

@ -64,6 +64,7 @@ if($view) {
$view->setParam('enableadminrevapp', $settings->_enableAdminRevApp);
$view->setParam('enableownerrevapp', $settings->_enableOwnerRevApp);
$view->setParam('enableselfrevapp', $settings->_enableSelfRevApp);
$view->setParam('enablehiddenrevapp', $settings->_enableHiddenRevApp);
$view->setParam('dropfolderdir', $settings->_dropFolderDir);
$view->setParam('dropfolderfile', isset($_REQUEST["dropfolderfileform1"]) ?$_REQUEST["dropfolderfileform1"] : '');
$view->setParam('workflowmode', $settings->_workflowMode);

View File

@ -66,6 +66,7 @@ if($view) {
$view->setParam('enableadminrevapp', $settings->_enableAdminRevApp);
$view->setParam('enableownerrevapp', $settings->_enableOwnerRevApp);
$view->setParam('enableselfrevapp', $settings->_enableSelfRevApp);
$view->setParam('enablehiddenrevapp', $settings->_enableHiddenRevApp);
$view->setParam('accessobject', $accessop);
$view($_GET);
exit;

View File

@ -74,6 +74,7 @@ if($view) {
$view->setParam('enableadminrevapp', $settings->_enableAdminRevApp);
$view->setParam('enableownerrevapp', $settings->_enableOwnerRevApp);
$view->setParam('enableselfrevapp', $settings->_enableSelfRevApp);
$view->setParam('enablehiddenrevapp', $settings->_enableHiddenRevApp);
$view->setParam('dropfolderdir', $settings->_dropFolderDir);
$view->setParam('workflowmode', $settings->_workflowMode);
$view->setParam('presetexpiration', $settings->_presetExpirationDate);

View File

@ -149,6 +149,7 @@ console.log(params);
$enableadminrevapp = $this->params['enableadminrevapp'];
$enableownerrevapp = $this->params['enableownerrevapp'];
$enableselfrevapp = $this->params['enableselfrevapp'];
$enablehiddenrevapp = $this->params['enablehiddenrevapp'];
$strictformcheck = $this->params['strictformcheck'];
$nodocumentformfields = $this->params['nodocumentformfields'];
$dropfolderdir = $this->params['dropfolderdir'];
@ -511,6 +512,7 @@ console.log(params);
$options = array();
foreach ($docAccess["users"] as $usr) {
if(!$enablehiddenrevapp && $usr->isHidden()) continue;
if (!$enableselfrevapp && $usr->getID()==$user->getID()) continue;
$mandatory=false;
foreach ($res as $r) if ($r['reviewerUserID']==$usr->getID()) $mandatory=true;
@ -612,6 +614,7 @@ console.log(params);
$options = array();
foreach ($docAccess["users"] as $usr) {
if(!$enablehiddenrevapp && $usr->isHidden()) continue;
if (!$enableselfrevapp && $usr->getID()==$user->getID()) continue;
$mandatory=false;

View File

@ -41,6 +41,7 @@ class SeedDMS_View_SetReviewersApprovers extends SeedDMS_Theme_Style {
$enableadminrevapp = $this->params['enableadminrevapp'];
$enableownerrevapp = $this->params['enableownerrevapp'];
$enableselfrevapp = $this->params['enableselfrevapp'];
$enablehiddenrevapp = $this->params['enablehiddenrevapp'];
$overallStatus = $content->getStatus();
$owner = $document->getOwner();
@ -115,6 +116,7 @@ class SeedDMS_View_SetReviewersApprovers extends SeedDMS_Theme_Style {
break;
}
} else {
if(!$enablehiddenrevapp && $usr->isHidden()) continue;
if (!$enableselfrevapp && $usr->getID()==$user->getID()) continue;
$options[] = array($usr->getID(), htmlspecialchars($usr->getLogin() . " - ". $usr->getFullName()));
}
@ -236,6 +238,7 @@ class SeedDMS_View_SetReviewersApprovers extends SeedDMS_Theme_Style {
}
}
else {
if(!$enablehiddenrevapp && $usr->isHidden()) continue;
if (!$enableselfrevapp && $usr->getID()==$user->getID()) continue;
$options[] = array($usr->getID(), htmlspecialchars($usr->getLogin() . " - ". $usr->getFullName()));
}

View File

@ -141,6 +141,7 @@ console.log(element);
$enableadminrevapp = $this->params['enableadminrevapp'];
$enableownerrevapp = $this->params['enableownerrevapp'];
$enableselfrevapp = $this->params['enableselfrevapp'];
$enablehiddenrevapp = $this->params['enablehiddenrevapp'];
$dropfolderdir = $this->params['dropfolderdir'];
$workflowmode = $this->params['workflowmode'];
$presetexpiration = $this->params['presetexpiration'];
@ -339,6 +340,7 @@ console.log(element);
$res=$user->getMandatoryReviewers();
$options = array();
foreach ($docAccess["users"] as $usr) {
if(!$enablehiddenrevapp && $usr->isHidden()) continue;
if (!$enableselfrevapp && $usr->getID()==$user->getID()) continue;
$mandatory=false;
foreach ($res as $r) if ($r['reviewerUserID']==$usr->getID()) $mandatory=true;
@ -491,6 +493,7 @@ console.log(element);
$options = array();
$res=$user->getMandatoryApprovers();
foreach ($docAccess["users"] as $usr) {
if(!$enablehiddenrevapp && $usr->isHidden()) continue;
if (!$enableselfrevapp && $usr->getID()==$user->getID()) continue;
$mandatory=false;