mirror of
https://git.code.sf.net/p/seeddms/code
synced 2024-11-26 15:32:13 +00:00
fix line indenting
This commit is contained in:
parent
022fdc86b3
commit
663dc869f4
|
@ -657,11 +657,11 @@ class SeedDMS_Core_Document extends SeedDMS_Core_Object { /* {{{ */
|
|||
function setFolder($newFolder) { /* {{{ */
|
||||
$db = $this->_dms->getDB();
|
||||
|
||||
if(!$newFolder)
|
||||
return false;
|
||||
if(!$newFolder)
|
||||
return false;
|
||||
|
||||
if(!$newFolder->isType('folder'))
|
||||
return false;
|
||||
if(!$newFolder->isType('folder'))
|
||||
return false;
|
||||
|
||||
$queryStr = "UPDATE `tblDocuments` SET `folder` = " . $newFolder->getID() . " WHERE `id` = ". $this->_id;
|
||||
if (!$db->getResult($queryStr))
|
||||
|
@ -707,11 +707,11 @@ class SeedDMS_Core_Document extends SeedDMS_Core_Object { /* {{{ */
|
|||
function setOwner($newOwner) { /* {{{ */
|
||||
$db = $this->_dms->getDB();
|
||||
|
||||
if(!$newOwner)
|
||||
return false;
|
||||
if(!$newOwner)
|
||||
return false;
|
||||
|
||||
if(!$newOwner->isType('user'))
|
||||
return false;
|
||||
if(!$newOwner->isType('user'))
|
||||
return false;
|
||||
|
||||
$queryStr = "UPDATE `tblDocuments` set `owner` = " . $newOwner->getID() . " WHERE `id` = " . $this->_id;
|
||||
if (!$db->getResult($queryStr))
|
||||
|
@ -752,8 +752,8 @@ class SeedDMS_Core_Document extends SeedDMS_Core_Object { /* {{{ */
|
|||
function setDefaultAccess($mode, $noclean="false") { /* {{{ */
|
||||
$db = $this->_dms->getDB();
|
||||
|
||||
if($mode < M_LOWEST_RIGHT || $mode > M_HIGHEST_RIGHT)
|
||||
return false;
|
||||
if($mode < M_LOWEST_RIGHT || $mode > M_HIGHEST_RIGHT)
|
||||
return false;
|
||||
|
||||
$queryStr = "UPDATE `tblDocuments` set `defaultAccess` = " . (int) $mode . " WHERE `id` = " . $this->_id;
|
||||
if (!$db->getResult($queryStr))
|
||||
|
@ -2079,8 +2079,8 @@ class SeedDMS_Core_Document extends SeedDMS_Core_Object { /* {{{ */
|
|||
if (file_exists( $this->_dms->contentDir.$version->getPath() ))
|
||||
if (!SeedDMS_Core_File::removeFile( $this->_dms->contentDir.$version->getPath() )) {
|
||||
$db->rollbackTransaction();
|
||||
return false;
|
||||
}
|
||||
return false;
|
||||
}
|
||||
|
||||
$db->commitTransaction();
|
||||
return true;
|
||||
|
@ -4187,14 +4187,14 @@ class SeedDMS_Core_DocumentContent extends SeedDMS_Core_Object { /* {{{ */
|
|||
|
||||
$db = $this->_document->getDMS()->getDB();
|
||||
|
||||
if(!$group->isType('group'))
|
||||
return -1;
|
||||
if(!$group->isType('group'))
|
||||
return -1;
|
||||
|
||||
// Check if the group is on the review list at all.
|
||||
$reviewStatus = $group->getReviewStatus($this->_document->getID(), $this->_version);
|
||||
if (is_bool($reviewStatus) && !$reviewStatus) {
|
||||
return false;
|
||||
}
|
||||
}
|
||||
if (count($reviewStatus)==0) {
|
||||
// User is not assigned to review this document. No action required.
|
||||
// Return an error.
|
||||
|
@ -4216,13 +4216,13 @@ class SeedDMS_Core_DocumentContent extends SeedDMS_Core_Object { /* {{{ */
|
|||
$requestUser->getID() ."')";
|
||||
$res=$db->getResult($queryStr);
|
||||
if (is_bool($res) && !$res)
|
||||
return false;
|
||||
return false;
|
||||
|
||||
$reviewLogID = $db->getInsertID('tblDocumentReviewLog', 'reviewLogID');
|
||||
if($file) {
|
||||
SeedDMS_Core_File::copyFile($file, $this->_dms->contentDir . $this->_document->getDir() . 'r' . $reviewLogID);
|
||||
}
|
||||
return $reviewLogID;
|
||||
$reviewLogID = $db->getInsertID('tblDocumentReviewLog', 'reviewLogID');
|
||||
if($file) {
|
||||
SeedDMS_Core_File::copyFile($file, $this->_dms->contentDir . $this->_document->getDir() . 'r' . $reviewLogID);
|
||||
}
|
||||
return $reviewLogID;
|
||||
} /* }}} */
|
||||
|
||||
/**
|
||||
|
@ -5315,9 +5315,9 @@ class SeedDMS_Core_DocumentContent extends SeedDMS_Core_Object { /* {{{ */
|
|||
|
||||
/**
|
||||
* Get the so far logged operations on the document content within the
|
||||
* workflow. Even after finishing the workflow (when the document content
|
||||
* does not have workflow set anymore) this function returns the list of all
|
||||
* log entries.
|
||||
* workflow. Even after finishing the workflow (when the document content
|
||||
* does not have workflow set anymore) this function returns the list of all
|
||||
* log entries.
|
||||
*
|
||||
* @return array list of objects
|
||||
*/
|
||||
|
@ -5354,8 +5354,8 @@ class SeedDMS_Core_DocumentContent extends SeedDMS_Core_Object { /* {{{ */
|
|||
/**
|
||||
* Get the latest workflow log entry for the document content within the
|
||||
* workflow. Even after finishing the workflow (when the document content
|
||||
* does not have workflow set anymore) this function returns the last
|
||||
* log entry.
|
||||
* does not have workflow set anymore) this function returns the last
|
||||
* log entry.
|
||||
*
|
||||
* @return object
|
||||
*/
|
||||
|
@ -5376,7 +5376,7 @@ class SeedDMS_Core_DocumentContent extends SeedDMS_Core_Object { /* {{{ */
|
|||
if (is_bool($resArr) && !$resArr)
|
||||
return false;
|
||||
|
||||
$i = 0;
|
||||
$i = 0;
|
||||
$workflow = $this->_document->getDMS()->getWorkflow($resArr[$i]["workflow"]);
|
||||
$workflowlog = new SeedDMS_Core_Workflow_Log($resArr[$i]["id"], $this->_document->getDMS()->getDocument($resArr[$i]["document"]), $resArr[$i]["version"], $workflow, $this->_document->getDMS()->getUser($resArr[$i]["userid"]), $workflow->getTransition($resArr[$i]["transition"]), $resArr[$i]["date"], $resArr[$i]["comment"]);
|
||||
$workflowlog->setDMS($this);
|
||||
|
|
Loading…
Reference in New Issue
Block a user