remove unneeded code, check if reception of document is allowed

This commit is contained in:
Uwe Steinmann 2018-03-29 15:10:18 +02:00
parent bf1473fbb1
commit 3976657a66
2 changed files with 12 additions and 26 deletions

View File

@ -78,6 +78,9 @@ if($view) {
$view->setParam('enableadminrevapp', $settings->_enableAdminRevApp);
$view->setParam('enableownerrevapp', $settings->_enableOwnerRevApp);
$view->setParam('enableselfrevapp', $settings->_enableSelfRevApp);
$view->setParam('enableadminreceipt', $settings->_enableAdminReceipt);
$view->setParam('enableownerreceipt', $settings->_enableOwnerReceipt);
$view->setParam('enableselfreceipt', $settings->_enableSelfReceipt);
$view->setParam('libraryfolder', $libfolder);
$view->setParam('dropfolderdir', $settings->_dropFolderDir);
$view->setParam('dropfolderfile', isset($_REQUEST["dropfolderfileform1"]) ?$_REQUEST["dropfolderfileform1"] : '');

View File

@ -160,6 +160,9 @@ $(document).ready(function() {
$enableadminrevapp = $this->params['enableadminrevapp'];
$enableownerrevapp = $this->params['enableownerrevapp'];
$enableselfrevapp = $this->params['enableselfrevapp'];
$enableadminreceipt = $this->params['enableadminreceipt'];
$enableownerreceipt = $this->params['enableownerreceipt'];
$enableselfreceipt = $this->params['enableselfreceipt'];
$strictformcheck = $this->params['strictformcheck'];
$dropfolderdir = $this->params['dropfolderdir'];
$libraryfolder = $this->params['libraryfolder'];
@ -186,10 +189,6 @@ $(document).ready(function() {
$this->warningMsg($msg);
$this->contentHeading(getMLText("add_document"));
$this->contentContainerStart();
// Retrieve a list of all users and groups that have review / approve
// privileges.
$docAccess = $folder->getReadAccessList($enableadminrevapp, $enableownerrevapp);
?>
<form action="../op/op.AddDocument.php" enctype="multipart/form-data" method="post" id="form1" name="form1">
<?php echo createHiddenFieldWithKey('adddocument'); ?>
@ -438,6 +437,9 @@ $(document).ready(function() {
</tr>
<?php
} else {
// Retrieve a list of all users and groups that have review / approve
// privileges.
$docAccess = $folder->getReadAccessList($enableadminrevapp, $enableownerrevapp);
if($workflowmode == 'traditional') {
?>
<tr>
@ -696,6 +698,9 @@ $(document).ready(function() {
</tr>
<?php
}
// Retrieve a list of all users and groups that have review / approve
// privileges.
$docAccess = $folder->getReadAccessList($enableadminreceipt, $enableownerreceipt);
?>
<tr>
<td colspan="2">
@ -715,17 +720,6 @@ $(document).ready(function() {
}
?>
</select>
<?php
$tmp = array();
foreach($receiptStatus as $r) {
if($r['type'] == 0) {
$tmp[] = $r['required'];
}
}
if($tmp) {
$this->printSelectPresetButtonHtml("IndRecipient", $tmp);
}
?>
</td>
</tr>
<tr>
@ -754,17 +748,6 @@ $(document).ready(function() {
}
?>
</select>
<?php
$tmp = array();
foreach($receiptStatus as $r) {
if($r['type'] == 1) {
$tmp[] = $r['required'];
}
}
if($tmp) {
$this->printSelectPresetButtonHtml("GrpRecipient", $tmp);
}
?>
</td>
</tr>
<tr>