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

This commit is contained in:
Uwe Steinmann 2020-02-28 11:18:09 +01:00
commit c8df1533e6
7 changed files with 31 additions and 3 deletions

View File

@ -130,6 +130,8 @@
- Improved import from file system
- HTTP Proxy for access on external extension repository can be set
- Do not use unzip in ExtensionMgr anymore
- fix version compare on info page
- allow one page mode on search page
--------------------------------------------------------------------------------
Changes in version 5.1.14

View File

@ -469,7 +469,7 @@ if($settings->_showSingleSearchHit && count($entries) == 1) {
$view->setParam('searchtime', $searchTime);
$view->setParam('urlparams', $_GET);
$view->setParam('cachedir', $settings->_cacheDir);
$view->setParam('onepage', false); // do most navigation by reloading areas of pages with ajax
$view->setParam('onepage', $settings->_onePageMode); // do most navigation by reloading areas of pages with ajax
$view->setParam('showtree', showtree());
$view->setParam('enableRecursiveCount', $settings->_enableRecursiveCount);
$view->setParam('maxRecursiveCount', $settings->_maxRecursiveCount);

View File

@ -95,6 +95,7 @@ if($view) {
$view->setParam('currenttab', isset($_GET['currenttab']) ? $_GET['currenttab'] : "");
$view->setParam('timeout', $settings->_cmdTimeout);
$view->setParam('xsendfile', $settings->_enableXsendfile);
$view->setParam('onepage', $settings->_onePageMode); // do most navigation by reloading areas of pages with ajax
$view($_GET);
exit;
}

View File

@ -2449,6 +2449,27 @@ $('body').on('click', '[id^=\"table-row-document\"] td:nth-child(2)', function(e
}
} /* }}} */
/**
* Print js code which catches clicks on folder rows
*
* This method will catch a click on a folder row and changes the
* window.location to the out.ViewFolder.php page
* This code is not needed on the out.ViewFolder.php page itself, because
* a click will just reload the list of folders and documents.
*/
function printClickFolderJs() { /* {{{ */
$onepage = $this->params['onepage'];
if($onepage) {
?>
/* catch click on a document row in the list folders and documents */
$('body').on('click', '[id^=\"table-row-folder\"] td:nth-child(2)', function(ev) {
attr_id = $(ev.currentTarget).parent().attr('id').split('-')[3];
window.location = '../out/out.ViewFolder.php?folderid=' + attr_id;
});
<?php
}
} /* }}} */
/**
* Start the row for a folder in list of documents and folders
*

View File

@ -47,7 +47,7 @@ class SeedDMS_View_Info extends SeedDMS_Bootstrap_Style {
if($availversion[0] == 'stable')
$newversion = $availversion[1];
}
if($newversion > $version->_number) {
if($newversion > $version->version()) {
$this->warningMsg(getMLText('no_current_version', array('latestversion'=>$newversion)));
}
} else {
@ -63,4 +63,3 @@ class SeedDMS_View_Info extends SeedDMS_Bootstrap_Style {
$this->htmlEndPage();
} /* }}} */
}
?>

View File

@ -68,6 +68,9 @@ $(document).ready( function() {
$this->printFolderChooserJs("form1");
$this->printDeleteFolderButtonJs();
$this->printDeleteDocumentButtonJs();
/* Add js for catching click on document in one page mode */
$this->printClickDocumentJs();
$this->printClickFolderJs();
} /* }}} */
function export() { /* {{{ */

View File

@ -196,6 +196,8 @@ class SeedDMS_View_ViewDocument extends SeedDMS_Bootstrap_Style {
}
$this->printDocumentChooserJs("form1");
$this->printDeleteDocumentButtonJs();
/* Add js for catching click on document in one page mode */
$this->printClickDocumentJs();
} /* }}} */
function documentInfos() { /* {{{ */