From 9eca8b6bb0d553ca892cf04669b81cd9a4833a18 Mon Sep 17 00:00:00 2001 From: michael Date: Tue, 17 Jun 2003 10:26:32 +0000 Subject: [PATCH] added extra div switching parameter factored document download and inline view to a separate page --- presentation/lookAndFeel/knowledgeTree/documentmanagement/viewBL.php | 21 +-------------------- 1 file changed, 1 insertion(+), 20 deletions(-) diff --git a/presentation/lookAndFeel/knowledgeTree/documentmanagement/viewBL.php b/presentation/lookAndFeel/knowledgeTree/documentmanagement/viewBL.php index 3ffea41..491594f 100644 --- a/presentation/lookAndFeel/knowledgeTree/documentmanagement/viewBL.php +++ b/presentation/lookAndFeel/knowledgeTree/documentmanagement/viewBL.php @@ -70,23 +70,6 @@ if (checkSession()) { $oPatternCustom->setHtml(getPage($oDocument, true)); $main->setErrorMessage("You cannot edit a document collaboration step that is completed or currently underway"); $main->setFormAction("$default->rootUrl/control.php?action=modifyDocument&fDocumentID=" . $oDocument->getID()); - } else if (isset($fForInlineView) && Permission::userHasDocumentReadPermission($fDocumentID)) { - $oDocumentTransaction = & new DocumentTransaction($fDocumentID, "Inline view", VIEW); - $oDocumentTransaction->create(); - PhysicalDocumentManager::inlineViewPhysicalDocument($fDocumentID); - } else if (isset($fForDownload) && Permission::userHasDocumentReadPermission($fDocumentID)) { - //if the user has document read permission, perform the download - if (isset($fVersion)) { - // we're downloading an old version of the document - $oDocumentTransaction = & new DocumentTransaction($fDocumentID, "Document version $fVersion downloaded", DOWNLOAD); - $oDocumentTransaction->create(); - PhysicalDocumentManager::downloadVersionedPhysicalDocument($fDocumentID, $fVersion); - } else { - // download the current version - $oDocumentTransaction = & new DocumentTransaction($fDocumentID, "Document downloaded", DOWNLOAD); - $oDocumentTransaction->create(); - PhysicalDocumentManager::downloadPhysicalDocument($fDocumentID); - } } else if (isset($fBeginCollaboration) && Permission::userHasDocumentWritePermission($fDocumentID)) { //begin the collaboration process //first ensure that all steps in the collaboration process are assigned @@ -182,8 +165,6 @@ if (checkSession()) { // prompt for the website to publish to $oPatternCustom->setHtml(getWebPublishPage($oDocument)); $main->setFormAction($_SERVER['PHP_SELF']); - //$main->setDHTMLScrolling(false); - //$main->setOnLoadJavaScript("switchDiv('documentData')"); } } else if (Permission::userHasDocumentWritePermission($fDocumentID) || Permission::userHasDocumentReadPermission($fDocumentID)) { @@ -220,7 +201,7 @@ if (checkSession()) { $main->setErrorMessage("The document you have chosen no longer exists in the DMS."); } $main->setDHTMLScrolling(false); - $main->setOnLoadJavaScript("switchDiv('documentData')"); + $main->setOnLoadJavaScript("switchDiv('documentData', 'document')"); $main->setFormAction("$default->rootUrl/control.php?action=modifyDocument&fDocumentID=" . $oDocument->getID()); } else { if ($oDocument) { -- libgit2 0.21.4