Merge branch 'seeddms-5.1.x' into seeddms-6.0.x

This commit is contained in:
Uwe Steinmann 2021-07-06 06:44:29 +02:00
commit 00041b30bd
5 changed files with 52 additions and 50 deletions

View File

@ -58,6 +58,7 @@ class SeedDMS_View_AdminTools extends SeedDMS_Theme_Style {
function show() { /* {{{ */
$dms = $this->params['dms'];
$user = $this->params['user'];
$settings = $this->params['settings'];
$logfileenable = $this->params['logfileenable'];
$enablefullsearch = $this->params['enablefullsearch'];
$accessop = $this->params['accessobject'];
@ -74,37 +75,37 @@ class SeedDMS_View_AdminTools extends SeedDMS_Theme_Style {
<?= self::startRow(); ?>
<?php echo $this->callHook('startOfRow', 1); ?>
<?php if($accessop->check_view_access('UsrMgr')) { ?>
<?= self::rowButton("../out/out.UsrMgr.php", "user", "user_management"); ?>
<?= self::rowButton($settings->_httpRoot."out/out.UsrMgr.php", "user", "user_management"); ?>
<?php } ?>
<?php if($accessop->check_view_access('GroupMgr')) { ?>
<?= self::rowButton("../out/out.GroupMgr.php", "group", "group_management"); ?>
<?= self::rowButton($settings->_httpRoot."out/out.GroupMgr.php", "group", "group_management"); ?>
<?php } ?>
<?php if($accessop->check_view_access('RoleMgr')) { ?>
<?= self::rowButton("../out/out.RoleMgr.php", "bullseye", "role_management"); ?>
<?= self::rowButton($settings->_httpRoot."out/out.RoleMgr.php", "bullseye", "role_management"); ?>
<?php } ?>
<?php echo $this->callHook('endOfRow', 1); ?>
<?= self::endRow(); ?>
<?= self::startRow(); ?>
<?php echo $this->callHook('startOfRow', 2); ?>
<?php if($accessop->check_view_access('BackupTools')) { ?>
<?= self::rowButton("../out/out.BackupTools.php", "life-saver", "backup_tools"); ?>
<?= self::rowButton($settings->_httpRoot."out/out.BackupTools.php", "life-saver", "backup_tools"); ?>
<?php } ?>
<?php
if ($logfileenable && ($accessop->check_view_access('LogManagement')))
echo self::rowButton("../out/out.LogManagement.php", "list", "log_management");
echo self::rowButton($settings->_httpRoot."out/out.LogManagement.php", "list", "log_management");
?>
<?php echo $this->callHook('endOfRow', 2); ?>
</div>
<?= self::startRow(); ?>
<?php echo $this->callHook('startOfRow', 3); ?>
<?php if($accessop->check_view_access('DefaultKeywords')) { ?>
<?= self::rowButton("../out/out.DefaultKeywords.php", "reorder", "global_default_keywords"); ?>
<?= self::rowButton($settings->_httpRoot."out/out.DefaultKeywords.php", "reorder", "global_default_keywords"); ?>
<?php } ?>
<?php if($accessop->check_view_access('Categories')) { ?>
<?= self::rowButton("../out/out.Categories.php", "columns", "global_document_categories"); ?>
<?= self::rowButton($settings->_httpRoot."out/out.Categories.php", "columns", "global_document_categories"); ?>
<?php } ?>
<?php if($accessop->check_view_access('AttributeMgr')) { ?>
<?= self::rowButton("../out/out.AttributeMgr.php", "tags", "global_attributedefinitions"); ?>
<?= self::rowButton($settings->_httpRoot."out/out.AttributeMgr.php", "tags", "global_attributedefinitions"); ?>
<?php } ?>
<?php echo $this->callHook('endOfRow', 3); ?>
<?= self::endRow(); ?>
@ -114,13 +115,13 @@ class SeedDMS_View_AdminTools extends SeedDMS_Theme_Style {
<?= self::startRow(); ?>
<?php echo $this->callHook('startOfRow', 4); ?>
<?php if($accessop->check_view_access('WorkflowMgr')) { ?>
<?= self::rowButton("../out/out.WorkflowMgr.php", "sitemap", "global_workflows"); ?>
<?= self::rowButton($settings->_httpRoot."out/out.WorkflowMgr.php", "sitemap", "global_workflows"); ?>
<?php } ?>
<?php if($accessop->check_view_access('WorkflowStatesMgr')) { ?>
<?= self::rowButton("../out/out.WorkflowStatesMgr.php", "star", "global_workflow_states"); ?>
<?= self::rowButton($settings->_httpRoot."out/out.WorkflowStatesMgr.php", "star", "global_workflow_states"); ?>
<?php } ?>
<?php if($accessop->check_view_access('WorkflowActionsMgr')) { ?>
<?= self::rowButton("../out/out.WorkflowActionsMgr.php", "bolt", "global_workflow_actions"); ?>
<?= self::rowButton($settings->_httpRoot."out/out.WorkflowActionsMgr.php", "bolt", "global_workflow_actions"); ?>
<?php } ?>
<?php echo $this->callHook('endOfRow', 4); ?>
<?= self::endRow(); ?>
@ -131,13 +132,13 @@ class SeedDMS_View_AdminTools extends SeedDMS_Theme_Style {
<?= self::startRow(); ?>
<?php echo $this->callHook('startOfRow', 5); ?>
<?php if($accessop->check_view_access('Indexer')) { ?>
<?= self::rowButton("../out/out.Indexer.php", "refresh", "update_fulltext_index"); ?>
<?= self::rowButton($settings->_httpRoot."out/out.Indexer.php", "refresh", "update_fulltext_index"); ?>
<?php } ?>
<?php if($accessop->check_view_access('CreateIndex')) { ?>
<?= self::rowButton("../out/out.CreateIndex.php", "search", "create_fulltext_index"); ?>
<?= self::rowButton($settings->_httpRoot."out/out.CreateIndex.php", "search", "create_fulltext_index"); ?>
<?php } ?>
<?php if($accessop->check_view_access('IndexInfo')) { ?>
<?= self::rowButton("../out/out.IndexInfo.php", "info-circle", "fulltext_info"); ?>
<?= self::rowButton($settings->_httpRoot."out/out.IndexInfo.php", "info-circle", "fulltext_info"); ?>
<?php } ?>
<?php echo $this->callHook('endOfRow', 5); ?>
<?= self::endRow(); ?>
@ -147,32 +148,32 @@ class SeedDMS_View_AdminTools extends SeedDMS_Theme_Style {
<?= self::startRow(); ?>
<?php echo $this->callHook('startOfRow', 6); ?>
<?php if($accessop->check_view_access('Statistic')) { ?>
<?= self::rowButton("../out/out.Statistic.php", "sitemap", "folders_and_documents_statistic"); ?>
<?= self::rowButton($settings->_httpRoot."out/out.Statistic.php", "sitemap", "folders_and_documents_statistic"); ?>
<?php } ?>
<?php if($accessop->check_view_access('Charts')) { ?>
<?= self::rowButton("../out/out.Charts.php", "bar-chart", "charts"); ?>
<?= self::rowButton($settings->_httpRoot."out/out.Charts.php", "bar-chart", "charts"); ?>
<?php } ?>
<?php if($accessop->check_view_access('ObjectCheck')) { ?>
<?= self::rowButton("../out/out.ObjectCheck.php", "check", "objectcheck"); ?>
<?= self::rowButton($settings->_httpRoot."out/out.ObjectCheck.php", "check", "objectcheck"); ?>
<?php } ?>
<?php if($accessop->check_view_access('Timeline')) { ?>
<?= self::rowButton("../out/out.Timeline.php", "signal", "timeline"); ?>
<?= self::rowButton($settings->_httpRoot."out/out.Timeline.php", "signal", "timeline"); ?>
<?php } ?>
<?php echo $this->callHook('endOfRow', 6); ?>
<?= self::endRow(); ?>
<?= self::startRow(); ?>
<?php echo $this->callHook('startOfRow', 7); ?>
<?php if($accessop->check_view_access('Settings')) { ?>
<?= self::rowButton("../out/out.Settings.php", "wrench", "settings"); ?>
<?= self::rowButton($settings->_httpRoot."out/out.Settings.php", "wrench", "settings"); ?>
<?php } ?>
<?php if($accessop->check_view_access('ExtensionMgr')) { ?>
<?= self::rowButton("../out/out.ExtensionMgr.php", "cogs", "extension_manager"); ?>
<?= self::rowButton($settings->_httpRoot."out/out.ExtensionMgr.php", "cogs", "extension_manager"); ?>
<?php } ?>
<?php if($accessop->check_view_access('SchedulerTaskMgr')) { ?>
<?= self::rowButton("../out/out.SchedulerTaskMgr.php", "clock-o", "scheduler_task_mgr"); ?>
<?= self::rowButton($settings->_httpRoot."out/out.SchedulerTaskMgr.php", "clock-o", "scheduler_task_mgr"); ?>
<?php } ?>
<?php if($accessop->check_view_access('Info')) { ?>
<?= self::rowButton("../out/out.Info.php", "info-circle", "version_info"); ?>
<?= self::rowButton($settings->_httpRoot."out/out.Info.php", "info-circle", "version_info"); ?>
<?php } ?>
<?php echo $this->callHook('endOfRow', 7); ?>
<?= self::endRow(); ?>

View File

@ -61,24 +61,24 @@ class SeedDMS_View_Clipboard extends SeedDMS_Theme_Style {
$subitems = [];
foreach($clipboard['folders'] as $folderid) {
if($folder = $this->params['dms']->getFolder($folderid)) {
$content .= " <li><a href=\"../out/out.ViewFolder.php?folderid=".$folder->getID()."\" class=\"table-row-folder droptarget\" data-droptarget=\"folder_".$folder->getID()."\" rel=\"folder_".$folder->getID()."\" data-name=\"".htmlspecialchars($folder->getName(), ENT_QUOTES)."\" data-uploadformtoken=\"".createFormKey('')."\" formtoken=\"".createFormKey('')."\"><i class=\"fa fa-folder-o\"></i> ".htmlspecialchars($folder->getName())."</a></li>\n";
$subitems[] = array('label'=>'<i class="fa fa-folder-o"></i> '.$folder->getName(), 'link'=>"../out/out.ViewFolder.php?folderid=".$folder->getID(), 'class'=>"table-row-folder droptarget", 'rel'=>"folder_".$folder->getID(), 'attributes'=>array(array('data-droptarget', "folder_".$folder->getID()), array('data-name', htmlspecialchars($folder->getName(), ENT_QUOTES))));
$content .= " <li><a href=\"".$this->params['settings']->_httpRoot."out/out.ViewFolder.php?folderid=".$folder->getID()."\" class=\"table-row-folder droptarget\" data-droptarget=\"folder_".$folder->getID()."\" rel=\"folder_".$folder->getID()."\" data-name=\"".htmlspecialchars($folder->getName(), ENT_QUOTES)."\" data-uploadformtoken=\"".createFormKey('')."\" formtoken=\"".createFormKey('')."\"><i class=\"fa fa-folder-o\"></i> ".htmlspecialchars($folder->getName())."</a></li>\n";
$subitems[] = array('label'=>'<i class="fa fa-folder-o"></i> '.$folder->getName(), 'link'=>$this->params['settings']->_httpRoot."out/out.ViewFolder.php?folderid=".$folder->getID(), 'class'=>"table-row-folder droptarget", 'rel'=>"folder_".$folder->getID(), 'attributes'=>array(array('data-droptarget', "folder_".$folder->getID()), array('data-name', htmlspecialchars($folder->getName(), ENT_QUOTES))));
}
}
foreach($clipboard['docs'] as $docid) {
if($document = $this->params['dms']->getDocument($docid))
$content .= " <li><a href=\"../out/out.ViewDocument.php?documentid=".$document->getID()."\" class=\"table-row-document droptarget\" data-droptarget=\"document_".$document->getID()."\" rel=\"document_".$document->getID()."\" data-name=\"".htmlspecialchars($document->getName(), ENT_QUOTES)."\" formtoken=\"".createFormKey('')."\"><i class=\"fa fa-file\"></i> ".htmlspecialchars($document->getName())."</a></li>\n";
$subitems[] = array('label'=>'<i class="fa fa-file"></i> '.$document->getName(), 'link'=>"../out/out.ViewDocument.php?documentid=".$document->getID(), 'class'=>"table-row-document droptarget", 'rel'=>"document_".$document->getID(), 'attributes'=>array(array('data-droptarget', "document_".$document->getID()), array('data-name', htmlspecialchars($document->getName(), ENT_QUOTES))));
$content .= " <li><a href=\"".$this->params['settings']->_httpRoot."out/out.ViewDocument.php?documentid=".$document->getID()."\" class=\"table-row-document droptarget\" data-droptarget=\"document_".$document->getID()."\" rel=\"document_".$document->getID()."\" data-name=\"".htmlspecialchars($document->getName(), ENT_QUOTES)."\" formtoken=\"".createFormKey('')."\"><i class=\"fa fa-file\"></i> ".htmlspecialchars($document->getName())."</a></li>\n";
$subitems[] = array('label'=>'<i class="fa fa-file"></i> '.$document->getName(), 'link'=>$this->params['settings']->_httpRoot."out/out.ViewDocument.php?documentid=".$document->getID(), 'class'=>"table-row-document droptarget", 'rel'=>"document_".$document->getID(), 'attributes'=>array(array('data-droptarget', "document_".$document->getID()), array('data-name', htmlspecialchars($document->getName(), ENT_QUOTES))));
}
$content .= " <li class=\"divider\"></li>\n";
$subitems[] = array('divider'=>true);
if(isset($this->params['folder']) && $this->params['folder']->getAccessMode($this->params['user']) >= M_READWRITE) {
$content .= " <li><a href=\"../op/op.MoveClipboard.php?targetid=".$this->params['folder']->getID()."&refferer=".urlencode('../out/out.ViewFolder.php?folderid='.$this->params['folder']->getID())."\">".getMLText("move_clipboard")."</a></li>\n";
$subitems[] = array('label'=>getMLText("move_clipboard"), 'link'=>"../op/op.MoveClipboard.php?targetid=".$this->params['folder']->getID()."&refferer=".urlencode('../out/out.ViewFolder.php?folderid='.$this->params['folder']->getID()));
$content .= " <li><a href=\"".$this->params['settings']->_httpRoot."op/op.MoveClipboard.php?targetid=".$this->params['folder']->getID()."&refferer=".urlencode($this->params['settings']->_httpRoot.'out/out.ViewFolder.php?folderid='.$this->params['folder']->getID())."\">".getMLText("move_clipboard")."</a></li>\n";
$subitems[] = array('label'=>getMLText("move_clipboard"), 'link'=>$this->params['settings']->_httpRoot."op/op.MoveClipboard.php?targetid=".$this->params['folder']->getID()."&refferer=".urlencode($this->params['settings']->_httpRoot.'out/out.ViewFolder.php?folderid='.$this->params['folder']->getID()));
}
// $content .= " <li><a href=\"../op/op.ClearClipboard.php?refferer=".urlencode($this->params['refferer'])."\">".getMLText("clear_clipboard")."</a><a class=\"ajax-click\" data-href=\"../op/op.Ajax.php\" data-param1=\"command=clearclipboard\">kkk</a> </li>\n";
// $content .= " <li><a class=\"ajax-click\" data-href=\"../op/op.Ajax.php\" data-param1=\"command=clearclipboard\">".getMLText("clear_clipboard")."</a></li>\n";
$subitems[] = array('label'=>getMLText('clear_clipboard'), 'attributes'=>array(array('class', 'ajax-click'), array('data-href', '../op/op.Ajax.php'), array('data-param1', 'command=clearclipboard')));
$subitems[] = array('label'=>getMLText('clear_clipboard'), 'attributes'=>array(array('class', 'ajax-click'), array('data-href', $this->params['settings']->_httpRoot.'op/op.Ajax.php'), array('data-param1', 'command=clearclipboard')));
if($this->hasHook('clipboardMenuItems'))
$subitems = $this->callHook('clipboardMenuItems', $clipboard, $subitems);
/*
@ -157,9 +157,9 @@ class SeedDMS_View_Clipboard extends SeedDMS_Theme_Style {
$content .= $this->documentListRowStart($document);
if (file_exists($dms->contentDir . $latestContent->getPath())) {
$content .= "<td><a draggable=\"false\" href=\"../op/op.Download.php?documentid=".$document->getID()."&version=".$version."\">";
$content .= "<td><a draggable=\"false\" href=\"".$this->params['settings']->_httpRoot."op/op.Download.php?documentid=".$document->getID()."&version=".$version."\">";
if($previewer->hasPreview($latestContent)) {
$content .= "<img draggable=\"false\" class=\"mimeicon\" width=\"40\"src=\"../op/op.Preview.php?documentid=".$document->getID()."&version=".$latestContent->getVersion()."&width=40\" title=\"".htmlspecialchars($latestContent->getMimeType())."\">";
$content .= "<img draggable=\"false\" class=\"mimeicon\" width=\"40\"src=\"".$this->params['settings']->_httpRoot."op/op.Preview.php?documentid=".$document->getID()."&version=".$latestContent->getVersion()."&width=40\" title=\"".htmlspecialchars($latestContent->getMimeType())."\">";
} else {
$content .= "<img draggable=\"false\" class=\"mimeicon\" src=\"".$this->getMimeIcon($latestContent->getFileType())."\" title=\"".htmlspecialchars($latestContent->getMimeType())."\">";
}
@ -176,7 +176,7 @@ class SeedDMS_View_Clipboard extends SeedDMS_Theme_Style {
$content .= $this->getListRowPath($document);
$content .= "</td>\n";
$content .= "<td>\n";
$content .= "<div class=\"list-action\"><a class=\"removefromclipboard\" rel=\"D".$document->getID()."\" msg=\"".getMLText('splash_removed_from_clipboard')."\" _href=\"../op/op.RemoveFromClipboard.php?folderid=".(isset($this->params['folder']) ? $this->params['folder']->getID() : '')."&id=".$document->getID()."&type=document\" title=\"".getMLText('rm_from_clipboard')."\"><i class=\"fa fa-remove\"></i></a></div>";
$content .= "<div class=\"list-action\"><a class=\"removefromclipboard\" rel=\"D".$document->getID()."\" msg=\"".getMLText('splash_removed_from_clipboard')."\" _href=\"".$this->params['settings']->_httpRoot."op/op.RemoveFromClipboard.php?folderid=".(isset($this->params['folder']) ? $this->params['folder']->getID() : '')."&id=".$document->getID()."&type=document\" title=\"".getMLText('rm_from_clipboard')."\"><i class=\"fa fa-remove\"></i></a></div>";
$content .= "</td>\n";
$content .= "</tr>";
}

View File

@ -55,6 +55,7 @@ $('.folderselect').click(function(ev) {
public function menuList() { /* {{{ */
$dms = $this->params['dms'];
$user = $this->params['user'];
$settings = $this->params['settings'];
$dropfolderdir = $this->params['dropfolderdir'];
$showfolders = $this->params['showfolders'];
$cachedir = $this->params['cachedir'];
@ -82,13 +83,13 @@ $('.folderselect').click(function(ev) {
$c++;
$subitem = array('label'=>'', 'attributes'=>array(array('title', getMLText('menu_upload_from_dropfolder'))));
if($folder)
$subitem['link'] = '../out/out.AddDocument.php?folderid='.$folder->getId()."&dropfolderfileform1=".urldecode($entry);
$subitem['link'] = $settings->_httpRoot.'out/out.AddDocument.php?folderid='.$folder->getId()."&dropfolderfileform1=".urldecode($entry);
$mimetype = finfo_file($finfo, $dir.'/'.$entry);
if(file_exists($dir.'/'.$entry)) {
if($previewwidth) {
$previewer->createRawPreview($dir.'/'.$entry, 'dropfolder/', $mimetype);
if($previewer->hasRawPreview($dir.'/'.$entry, 'dropfolder/')) {
$subitem['label'] .= "<div class=\"dropfolder-menu-img\" style=\"display: none; overflow:hidden; position: absolute; left:-".($previewwidth+10)."px; border: 1px solid #888;background: white;\"><img filename=\"".$entry."\" width=\"".$previewwidth."\" src=\"../op/op.DropFolderPreview.php?filename=".$entry."&width=".$previewwidth."\" title=\"".htmlspecialchars($mimetype)."\"></div>";
$subitem['label'] .= "<div class=\"dropfolder-menu-img\" style=\"display: none; overflow:hidden; position: absolute; left:-".($previewwidth+10)."px; border: 1px solid #888;background: white;\"><img filename=\"".$entry."\" width=\"".$previewwidth."\" src=\"".$settings->_httpRoot."op/op.DropFolderPreview.php?filename=".$entry."&width=".$previewwidth."\" title=\"".htmlspecialchars($mimetype)."\"></div>";
}
}
$subitem['label'] .= "<div class=\"dropfolder-menu-text\" style=\"margin-left:10px; margin-right: 10px; display:inline-block;\">".$entry."<br /><span style=\"font-size: 85%;\">".SeedDMS_Core_File::format_filesize(filesize($dir.'/'.$entry)).", ".date('Y-m-d H:i:s', filectime($dir.'/'.$entry))."</span></div>";

View File

@ -258,7 +258,7 @@ function typeahead() { /* {{{ */
</ul>
<div class="tab-content">
<div class="tab-pane <?php echo ($fullsearch == false) ? 'active' : ''; ?>" id="database">
<form class="form-horizontal" action="../out/out.Search.php" name="form1">
<form class="form-horizontal" action="<?= $this->params['settings']->_httpRoot ?>out/out.Search.php" name="form1">
<input type="hidden" name="fullsearch" value="0" />
<?php
// Database search Form {{{
@ -520,7 +520,7 @@ function typeahead() { /* {{{ */
if($enablefullsearch) {
echo "<div class=\"tab-pane ".(($fullsearch == true) ? 'active' : '')."\" id=\"fulltext\">\n";
?>
<form action="../out/out.Search.php" name="form2" style="min-height: 330px;">
<form action="<?= $this->params['settings']->_httpRoot ?>out/out.Search.php" name="form2" style="min-height: 330px;">
<input type="hidden" name="fullsearch" value="1" />
<?php
$this->contentContainerStart();

View File

@ -307,7 +307,7 @@ class SeedDMS_View_Tasks extends SeedDMS_Theme_Style {
$subitems = [];
foreach($tasks['review'] as $t) {
$doc = $dms->getDocument($t['id']);
$subitems[] = array('label'=>$doc->getName(), 'link'=>"../out/out.ViewDocument.php?documentid=".$doc->getID()."&currenttab=revapp", 'class'=>"table-row-document", 'rel'=>"document_".$doc->getID());
$subitems[] = array('label'=>$doc->getName(), 'link'=>$this->params['settings']->_httpRoot."out/out.ViewDocument.php?documentid=".$doc->getID()."&currenttab=revapp", 'class'=>"table-row-document", 'rel'=>"document_".$doc->getID());
}
$menuitems['tasks']['children']['review'] = array('label'=>getMLText('documents_to_review'), 'children'=>$subitems);
@ -316,7 +316,7 @@ class SeedDMS_View_Tasks extends SeedDMS_Theme_Style {
$subitems = [];
foreach($tasks['approval'] as $t) {
$doc = $dms->getDocument($t['id']);
$subitems[] = array('label'=>$doc->getName(), 'link'=>"../out/out.ViewDocument.php?documentid=".$doc->getID()."&currenttab=revapp", 'class'=>"table-row-document", 'rel'=>"document_".$doc->getID());
$subitems[] = array('label'=>$doc->getName(), 'link'=>$this->params['settings']->_httpRoot."out/out.ViewDocument.php?documentid=".$doc->getID()."&currenttab=revapp", 'class'=>"table-row-document", 'rel'=>"document_".$doc->getID());
}
$menuitems['tasks']['children']['approval'] = array('label'=>getMLText('documents_to_approve'), 'children'=>$subitems);
}
@ -324,7 +324,7 @@ class SeedDMS_View_Tasks extends SeedDMS_Theme_Style {
$subitems = [];
foreach($tasks['workflow'] as $t) {
$doc = $dms->getDocument($t['id']);
$subitems[] = array('label'=>$doc->getName(), 'link'=>"../out/out.ViewDocument.php?documentid=".$doc->getID()."&currenttab=workflow", 'class'=>"table-row-document", 'rel'=>"document_".$doc->getID());
$subitems[] = array('label'=>$doc->getName(), 'link'=>$this->params['settings']->_httpRoot."out/out.ViewDocument.php?documentid=".$doc->getID()."&currenttab=workflow", 'class'=>"table-row-document", 'rel'=>"document_".$doc->getID());
}
$menuitems['tasks']['children']['workflow'] = array('label'=>getMLText('documents_to_trigger_workflow'), 'children'=>$subitems);
}
@ -356,7 +356,7 @@ class SeedDMS_View_Tasks extends SeedDMS_Theme_Style {
$subitems = [];
foreach($tasks['rejected'] as $t) {
$doc = $dms->getDocument($t['id']);
$subitems[] = array('label'=>$doc->getName(), 'link'=>"../out/out.ViewDocument.php?documentid=".$doc->getID()."&currenttab=docinfo", 'class'=>"table-row-document", 'rel'=>"document_".$doc->getID());
$subitems[] = array('label'=>$doc->getName(), 'link'=>$this->params['settings']->_httpRoot."out/out.ViewDocument.php?documentid=".$doc->getID()."&currenttab=docinfo", 'class'=>"table-row-document", 'rel'=>"document_".$doc->getID());
}
$menuitems['tasks']['children']['rejected'] = array('label'=>getMLText('documents_rejected'), 'children'=>$subitems);
}
@ -370,7 +370,7 @@ class SeedDMS_View_Tasks extends SeedDMS_Theme_Style {
}
if ($accessobject->check_view_access('MyDocuments')) {
$menuitems['tasks']['children']['divider'] = array('divider'=>true);
$menuitems['tasks']['children']['mydocuments'] = array('label'=>getMLText('my_documents'), 'link'=>'../out/out.MyDocuments.php');
$menuitems['tasks']['children']['mydocuments'] = array('label'=>getMLText('my_documents'), 'link'=>$this->params['settings']->_httpRoot.'out/out.MyDocuments.php');
}
self::showNavigationBar($menuitems, array('right'=>true));
}
@ -398,18 +398,18 @@ class SeedDMS_View_Tasks extends SeedDMS_Theme_Style {
$content .= " <ul class=\"dropdown-menu\" role=\"menu\">\n";
foreach($clipboard['folders'] as $folderid) {
if($folder = $this->params['dms']->getFolder($folderid))
$content .= " <li><a href=\"../out/out.ViewFolder.php?folderid=".$folder->getID()."\"><i class=\"fa fa-folder-o\"></i> ".htmlspecialchars($folder->getName())."</a></li>\n";
$content .= " <li><a href=\"".$this->params['settings']->_httpRoot."out/out.ViewFolder.php?folderid=".$folder->getID()."\"><i class=\"fa fa-folder-o\"></i> ".htmlspecialchars($folder->getName())."</a></li>\n";
}
foreach($clipboard['docs'] as $docid) {
if($document = $this->params['dms']->getDocument($docid))
$content .= " <li><a href=\"../out/out.ViewDocument.php?documentid=".$document->getID()."\"><i class=\"fa fa-file\"></i> ".htmlspecialchars($document->getName())."</a></li>\n";
$content .= " <li><a href=\"".$this->params['settings']->_httpRoot."out/out.ViewDocument.php?documentid=".$document->getID()."\"><i class=\"fa fa-file\"></i> ".htmlspecialchars($document->getName())."</a></li>\n";
}
$content .= " <li class=\"divider\"></li>\n";
if(isset($this->params['folder']) && $this->params['folder']->getAccessMode($this->params['user']) >= M_READWRITE) {
$content .= " <li><a href=\"../op/op.MoveClipboard.php?targetid=".$this->params['folder']->getID()."&refferer=".urlencode($this->params['refferer'])."\">".getMLText("move_clipboard")."</a></li>\n";
$content .= " <li><a href=\"".$this->params['settings']->_httpRoot."op/op.MoveClipboard.php?targetid=".$this->params['folder']->getID()."&refferer=".urlencode($this->params['refferer'])."\">".getMLText("move_clipboard")."</a></li>\n";
}
// $content .= " <li><a href=\"../op/op.ClearClipboard.php?refferer=".urlencode($this->params['refferer'])."\">".getMLText("clear_clipboard")."</a><a class=\"ajax-click\" data-href=\"../op/op.Ajax.php\" data-param1=\"command=clearclipboard\">kkk</a> </li>\n";
$content .= " <li><a class=\"ajax-click\" data-href=\"../op/op.Ajax.php\" data-param1=\"command=clearclipboard\">".getMLText("clear_clipboard")."</a></li>\n";
// $content .= " <li><a href=\"".$this->params['settings']->_httpRoot."op/op.ClearClipboard.php?refferer=".urlencode($this->params['refferer'])."\">".getMLText("clear_clipboard")."</a><a class=\"ajax-click\" data-href=\"".$this->params['settings']->_httpRoot."op/op.Ajax.php\" data-param1=\"command=clearclipboard\">kkk</a> </li>\n";
$content .= " <li><a class=\"ajax-click\" data-href=\"".$this->params['settings']->_httpRoot."op/op.Ajax.php\" data-param1=\"command=clearclipboard\">".getMLText("clear_clipboard")."</a></li>\n";
$content .= " </ul>\n";
$content .= " </li>\n";
$content .= " </ul>\n";
@ -448,7 +448,7 @@ class SeedDMS_View_Tasks extends SeedDMS_Theme_Style {
}
$content .= "</td>\n";
$content .= "<td>\n";
$content .= "<div class=\"list-action\"><a class=\"removefromclipboard\" rel=\"F".$folderid."\" msg=\"".getMLText('splash_removed_from_clipboard')."\" _href=\"../op/op.RemoveFromClipboard.php?folderid=".(isset($this->params['folder']) ? $this->params['folder']->getID() : '')."&id=".$folderid."&type=folder\" title=\"".getMLText('rm_from_clipboard')."\"><i class=\"fa fa-remove\"></i></a></div>";
$content .= "<div class=\"list-action\"><a class=\"removefromclipboard\" rel=\"F".$folderid."\" msg=\"".getMLText('splash_removed_from_clipboard')."\" _href=\"".$this->params['settings']->_httpRoot."op/op.RemoveFromClipboard.php?folderid=".(isset($this->params['folder']) ? $this->params['folder']->getID() : '')."&id=".$folderid."&type=folder\" title=\"".getMLText('rm_from_clipboard')."\"><i class=\"fa fa-remove\"></i></a></div>";
$content .= "</td>\n";
//$content .= "</tr>\n";
$content .= $this->folderListRowEnd($folder);
@ -470,9 +470,9 @@ class SeedDMS_View_Tasks extends SeedDMS_Theme_Style {
$content .= "<tr draggable=\"true\" rel=\"document_".$docid."\" class=\"table-row-document\" formtoken=\"".createFormKey('movedocument')."\">";
if (file_exists($dms->contentDir . $latestContent->getPath())) {
$content .= "<td><a draggable=\"false\" href=\"../op/op.Download.php?documentid=".$docid."&version=".$version."\">";
$content .= "<td><a draggable=\"false\" href=\"".$this->params['settings']->_httpRoot."op/op.Download.php?documentid=".$docid."&version=".$version."\">";
if($previewer->hasPreview($latestContent)) {
$content .= "<img draggable=\"false\" class=\"mimeicon\" width=\"40\"src=\"../op/op.Preview.php?documentid=".$document->getID()."&version=".$latestContent->getVersion()."&width=40\" title=\"".htmlspecialchars($latestContent->getMimeType())."\">";
$content .= "<img draggable=\"false\" class=\"mimeicon\" width=\"40\"src=\"".$this->params['settings']->_httpRoot."op/op.Preview.php?documentid=".$document->getID()."&version=".$latestContent->getVersion()."&width=40\" title=\"".htmlspecialchars($latestContent->getMimeType())."\">";
} else {
$content .= "<img draggable=\"false\" class=\"mimeicon\" src=\"".$this->getMimeIcon($latestContent->getFileType())."\" title=\"".htmlspecialchars($latestContent->getMimeType())."\">";
}
@ -486,7 +486,7 @@ class SeedDMS_View_Tasks extends SeedDMS_Theme_Style {
}
$content .= "</td>\n";
$content .= "<td>\n";
$content .= "<div class=\"list-action\"><a class=\"removefromclipboard\" rel=\"D".$docid."\" msg=\"".getMLText('splash_removed_from_clipboard')."\" _href=\"../op/op.RemoveFromClipboard.php?folderid=".(isset($this->params['folder']) ? $this->params['folder']->getID() : '')."&id=".$docid."&type=document\" title=\"".getMLText('rm_from_clipboard')."\"><i class=\"fa fa-remove\"></i></a></div>";
$content .= "<div class=\"list-action\"><a class=\"removefromclipboard\" rel=\"D".$docid."\" msg=\"".getMLText('splash_removed_from_clipboard')."\" _href=\"".$this->params['settings']->_httpRoot."op/op.RemoveFromClipboard.php?folderid=".(isset($this->params['folder']) ? $this->params['folder']->getID() : '')."&id=".$docid."&type=document\" title=\"".getMLText('rm_from_clipboard')."\"><i class=\"fa fa-remove\"></i></a></div>";
$content .= "</td>\n";
$content .= "</tr>";
$doccount++;