mirror of
https://git.code.sf.net/p/seeddms/code
synced 2025-05-12 12:41:30 +00:00
check for current tab
This commit is contained in:
parent
380ac2f1bd
commit
82190c7d0e
|
@ -85,6 +85,7 @@ if($view) {
|
||||||
$view->setParam('previewWidthList', $settings->_previewWidthList);
|
$view->setParam('previewWidthList', $settings->_previewWidthList);
|
||||||
$view->setParam('previewWidthDetail', $settings->_previewWidthDetail);
|
$view->setParam('previewWidthDetail', $settings->_previewWidthDetail);
|
||||||
$view->setParam('checkOutDir', $settings->_checkOutDir);
|
$view->setParam('checkOutDir', $settings->_checkOutDir);
|
||||||
|
$view->setParam('currenttab', isset($_REQUEST['currenttab']) ? $_REQUEST['currenttab'] : '');
|
||||||
$view->show();
|
$view->show();
|
||||||
exit;
|
exit;
|
||||||
}
|
}
|
||||||
|
|
|
@ -212,6 +212,7 @@ class SeedDMS_View_ViewDocument extends SeedDMS_Bootstrap_Style {
|
||||||
$previewwidthdetail = $this->params['previewWidthDetail'];
|
$previewwidthdetail = $this->params['previewWidthDetail'];
|
||||||
$checkoutdir = $this->params['checkOutDir'];
|
$checkoutdir = $this->params['checkOutDir'];
|
||||||
$documentid = $document->getId();
|
$documentid = $document->getId();
|
||||||
|
$currenttab = $this->params['currenttab'];
|
||||||
|
|
||||||
$versions = $document->getContent();
|
$versions = $document->getContent();
|
||||||
|
|
||||||
|
@ -403,41 +404,41 @@ class SeedDMS_View_ViewDocument extends SeedDMS_Bootstrap_Style {
|
||||||
</div>
|
</div>
|
||||||
<div class="span9">
|
<div class="span9">
|
||||||
<ul class="nav nav-tabs" id="docinfotab">
|
<ul class="nav nav-tabs" id="docinfotab">
|
||||||
<li class="active"><a data-target="#docinfo" data-toggle="tab"><?php printMLText('current_version'); ?></a></li>
|
<li class="<?php if(!$currenttab || $currenttab == 'docinfo') echo 'active'; ?>"><a data-target="#docinfo" data-toggle="tab"><?php printMLText('current_version'); ?></a></li>
|
||||||
<?php if (count($versions)>1) { ?>
|
<?php if (count($versions)>1) { ?>
|
||||||
<li><a data-target="#previous" data-toggle="tab"><?php printMLText('previous_versions'); ?></a></li>
|
<li class="<?php if($currenttab == 'previous') echo 'active'; ?>"><a data-target="#previous" data-toggle="tab"><?php printMLText('previous_versions'); ?></a></li>
|
||||||
<?php
|
<?php
|
||||||
}
|
}
|
||||||
if($workflowmode == 'traditional' || $workflowmode == 'traditional_only_approval') {
|
if($workflowmode == 'traditional' || $workflowmode == 'traditional_only_approval') {
|
||||||
if((is_array($reviewStatus) && count($reviewStatus)>0) ||
|
if((is_array($reviewStatus) && count($reviewStatus)>0) ||
|
||||||
(is_array($approvalStatus) && count($approvalStatus)>0)) {
|
(is_array($approvalStatus) && count($approvalStatus)>0)) {
|
||||||
?>
|
?>
|
||||||
<li><a data-target="#revapp" data-toggle="tab"><?php if($workflowmode == 'traditional') echo getMLText('reviewers')."/"; echo getMLText('approvers'); ?></a></li>
|
<li class="<?php if($currenttab == 'revapp') echo 'active'; ?>"><a data-target="#revapp" data-toggle="tab"><?php if($workflowmode == 'traditional') echo getMLText('reviewers')."/"; echo getMLText('approvers'); ?></a></li>
|
||||||
<?php
|
<?php
|
||||||
}
|
}
|
||||||
} else {
|
} else {
|
||||||
if($workflow) {
|
if($workflow) {
|
||||||
?>
|
?>
|
||||||
<li><a data-target="#workflow" data-toggle="tab"><?php echo getMLText('workflow'); ?></a></li>
|
<li class="<?php if($currenttab == 'workflow') echo 'active'; ?>"><a data-target="#workflow" data-toggle="tab"><?php echo getMLText('workflow'); ?></a></li>
|
||||||
<?php
|
<?php
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
if(is_array($receiptStatus) && count($receiptStatus)>0) {
|
if(is_array($receiptStatus) && count($receiptStatus)>0) {
|
||||||
?>
|
?>
|
||||||
<li><a data-target="#recipients" data-toggle="tab"><?php echo getMLText('recipients'); ?></a></li>
|
<li class="<?php if($currenttab == 'recipients') echo 'active'; ?>"><a data-target="#recipients" data-toggle="tab"><?php echo getMLText('recipients'); ?></a></li>
|
||||||
<?php
|
<?php
|
||||||
}
|
}
|
||||||
if(is_array($revisionStatus) && count($revisionStatus)>0) {
|
if(is_array($revisionStatus) && count($revisionStatus)>0) {
|
||||||
?>
|
?>
|
||||||
<li><a data-target="#revision" data-toggle="tab"><?php echo getMLText('revise_document'); ?></a></li>
|
<li class="<?php if($currenttab == 'revision') echo 'active'; ?>"><a data-target="#revision" data-toggle="tab"><?php echo getMLText('revise_document'); ?></a></li>
|
||||||
<?php
|
<?php
|
||||||
}
|
}
|
||||||
?>
|
?>
|
||||||
<li><a data-target="#attachments" data-toggle="tab"><?php printMLText('linked_files'); echo (count($files)) ? " (".count($files).")" : ""; ?></a></li>
|
<li class="<?php if($currenttab == 'attachments') echo 'active'; ?>"><a data-target="#attachments" data-toggle="tab"><?php printMLText('linked_files'); echo (count($files)) ? " (".count($files).")" : ""; ?></a></li>
|
||||||
<li><a data-target="#links" data-toggle="tab"><?php printMLText('linked_documents'); echo (count($links)) ? " (".count($links).")" : ""; ?></a></li>
|
<li class="<?php if($currenttab == 'links') echo 'active'; ?>"><a data-target="#links" data-toggle="tab"><?php printMLText('linked_documents'); echo (count($links)) ? " (".count($links).")" : ""; ?></a></li>
|
||||||
</ul>
|
</ul>
|
||||||
<div class="tab-content">
|
<div class="tab-content">
|
||||||
<div class="tab-pane active" id="docinfo">
|
<div class="tab-pane <?php if(!$currenttab || $currenttab == 'docinfo') echo 'active'; ?>" id="docinfo">
|
||||||
<?php
|
<?php
|
||||||
if(!$latestContent) {
|
if(!$latestContent) {
|
||||||
$this->contentContainerStart();
|
$this->contentContainerStart();
|
||||||
|
@ -631,7 +632,7 @@ class SeedDMS_View_ViewDocument extends SeedDMS_Bootstrap_Style {
|
||||||
if((is_array($reviewStatus) && count($reviewStatus)>0) ||
|
if((is_array($reviewStatus) && count($reviewStatus)>0) ||
|
||||||
(is_array($approvalStatus) && count($approvalStatus)>0)) {
|
(is_array($approvalStatus) && count($approvalStatus)>0)) {
|
||||||
?>
|
?>
|
||||||
<div class="tab-pane" id="revapp">
|
<div class="tab-pane <?php if($currenttab == 'revapp') echo 'active'; ?>" id="revapp">
|
||||||
<?php
|
<?php
|
||||||
$this->contentContainerstart();
|
$this->contentContainerstart();
|
||||||
print "<table class=\"table-condensed\">\n";
|
print "<table class=\"table-condensed\">\n";
|
||||||
|
@ -802,7 +803,7 @@ class SeedDMS_View_ViewDocument extends SeedDMS_Bootstrap_Style {
|
||||||
} else {
|
} else {
|
||||||
if($workflow) {
|
if($workflow) {
|
||||||
?>
|
?>
|
||||||
<div class="tab-pane" id="workflow">
|
<div class="tab-pane <?php if($currenttab == 'workflow') echo 'active'; ?>" id="workflow">
|
||||||
<?php
|
<?php
|
||||||
$this->contentContainerStart();
|
$this->contentContainerStart();
|
||||||
if($user->isAdmin()) {
|
if($user->isAdmin()) {
|
||||||
|
@ -983,7 +984,7 @@ class SeedDMS_View_ViewDocument extends SeedDMS_Bootstrap_Style {
|
||||||
}
|
}
|
||||||
if(is_array($receiptStatus) && count($receiptStatus)>0) {
|
if(is_array($receiptStatus) && count($receiptStatus)>0) {
|
||||||
?>
|
?>
|
||||||
<div class="tab-pane" id="recipients">
|
<div class="tab-pane <?php if($currenttab == 'recipients') echo 'active'; ?>" id="recipients">
|
||||||
<?php
|
<?php
|
||||||
$this->contentContainerStart();
|
$this->contentContainerStart();
|
||||||
print "<table class=\"table-condensed\">\n";
|
print "<table class=\"table-condensed\">\n";
|
||||||
|
@ -1070,7 +1071,7 @@ class SeedDMS_View_ViewDocument extends SeedDMS_Bootstrap_Style {
|
||||||
}
|
}
|
||||||
if(is_array($revisionStatus) && count($revisionStatus)>0) {
|
if(is_array($revisionStatus) && count($revisionStatus)>0) {
|
||||||
?>
|
?>
|
||||||
<div class="tab-pane" id="revision">
|
<div class="tab-pane <?php if($currenttab == 'revision') echo 'active'; ?>" id="revision">
|
||||||
<?php
|
<?php
|
||||||
if($status['status'] == S_RELEASED) {
|
if($status['status'] == S_RELEASED) {
|
||||||
if($latestContent->getRevisionDate()) {
|
if($latestContent->getRevisionDate()) {
|
||||||
|
@ -1171,7 +1172,7 @@ class SeedDMS_View_ViewDocument extends SeedDMS_Bootstrap_Style {
|
||||||
}
|
}
|
||||||
if (count($versions)>1) {
|
if (count($versions)>1) {
|
||||||
?>
|
?>
|
||||||
<div class="tab-pane" id="previous">
|
<div class="tab-pane <?php if($currenttab == 'previous') echo 'active'; ?>" id="previous">
|
||||||
<?php
|
<?php
|
||||||
$this->contentContainerStart();
|
$this->contentContainerStart();
|
||||||
|
|
||||||
|
@ -1269,7 +1270,7 @@ class SeedDMS_View_ViewDocument extends SeedDMS_Bootstrap_Style {
|
||||||
<?php
|
<?php
|
||||||
}
|
}
|
||||||
?>
|
?>
|
||||||
<div class="tab-pane" id="attachments">
|
<div class="tab-pane <?php if($currenttab == 'attachments') echo 'active'; ?>" id="attachments">
|
||||||
<?php
|
<?php
|
||||||
|
|
||||||
$this->contentContainerStart();
|
$this->contentContainerStart();
|
||||||
|
@ -1345,7 +1346,7 @@ class SeedDMS_View_ViewDocument extends SeedDMS_Bootstrap_Style {
|
||||||
$this->contentContainerEnd();
|
$this->contentContainerEnd();
|
||||||
?>
|
?>
|
||||||
</div>
|
</div>
|
||||||
<div class="tab-pane" id="links">
|
<div class="tab-pane <?php if($currenttab == 'links') echo 'active'; ?>" id="links">
|
||||||
<?php
|
<?php
|
||||||
$this->contentContainerStart();
|
$this->contentContainerStart();
|
||||||
if (count($links) > 0) {
|
if (count($links) > 0) {
|
||||||
|
|
Loading…
Reference in New Issue
Block a user