From ecafa39d1e587eb5751dfb4b5d4eb38bb1669fd2 Mon Sep 17 00:00:00 2001 From: Uwe Steinmann Date: Mon, 15 Jun 2015 08:53:39 +0200 Subject: [PATCH] mayApprove() checks if document is in review --- inc/inc.ClassAccessOperation.php | 5 +++-- 1 file changed, 3 insertions(+), 2 deletions(-) diff --git a/inc/inc.ClassAccessOperation.php b/inc/inc.ClassAccessOperation.php index b7d7f7235..c430b13dc 100644 --- a/inc/inc.ClassAccessOperation.php +++ b/inc/inc.ClassAccessOperation.php @@ -251,14 +251,15 @@ class SeedDMS_AccessOperation { * Check if document content may be approved * * Approving a document content is only allowed if the document was not - * obsoleted. There are other requirements which are not taken into + * obsoleted and the document is not in review status. + * There are other requirements which are not taken into * account here. */ function mayApprove() { /* {{{ */ if(get_class($this->obj) == 'SeedDMS_Core_Document') { $latestContent = $this->obj->getLatestContent(); $status = $latestContent->getStatus(); - if ($status["status"]!=S_OBSOLETE) { + if ($status["status"]!=S_OBSOLETE && $status["status"]!=S_DRAFT_REV) { return true; } }