adding a review returns the log id not 0

This commit is contained in:
Uwe Steinmann 2021-09-29 17:23:59 +02:00
parent 989572e069
commit 2b1f637e9c

View File

@ -3957,13 +3957,12 @@ class SeedDMS_Core_DocumentContent extends SeedDMS_Core_Object { /* {{{ */
"VALUES ('". $reviewID ."', '0', '', ".$db->getCurrentDatetime().", '". $requestUser->getID() ."')"; "VALUES ('". $reviewID ."', '0', '', ".$db->getCurrentDatetime().", '". $requestUser->getID() ."')";
$res = $db->getResult($queryStr); $res = $db->getResult($queryStr);
if (is_bool($res) && !$res) { if (is_bool($res) && !$res) {
return -1; return false;
} }
// Add reviewer to event notification table. $reviewLogID = $db->getInsertID('tblDocumentReviewLog', 'reviewLogID');
//$this->_document->addNotify($groupID, false); $db->dropTemporaryTable('ttreviewid');
return $reviewLogID;
return 0;
} /* }}} */ } /* }}} */
/** /**
@ -4274,13 +4273,11 @@ class SeedDMS_Core_DocumentContent extends SeedDMS_Core_Object { /* {{{ */
"VALUES ('". $approveID ."', '0', '', ".$db->getCurrentDatetime().", '". $requestUser->getID() ."')"; "VALUES ('". $approveID ."', '0', '', ".$db->getCurrentDatetime().", '". $requestUser->getID() ."')";
$res = $db->getResult($queryStr); $res = $db->getResult($queryStr);
if (is_bool($res) && !$res) { if (is_bool($res) && !$res) {
return -1; return false;
} }
// Add approver to event notification table. $approveLogID = $db->getInsertID('tblDocumentApproveLog', 'approveLogID');
//$this->_document->addNotify($groupID, false); $db->dropTemporaryTable('ttapproveid');
$approveLogID = $db->getInsertID('tblDocumentApproveLog', 'approveLogID');
return $approveLogID; return $approveLogID;
} /* }}} */ } /* }}} */