pass on orderby to ajax calls

This commit is contained in:
Uwe Steinmann 2019-08-27 21:46:19 +02:00
parent bd99b078ca
commit 4a22ed2ce7

View File

@ -106,8 +106,7 @@ class SeedDMS_View_ViewFolder extends SeedDMS_Bootstrap_Style {
?> ?>
function folderSelected(id, name) { function folderSelected(id, name) {
// window.location = '../out/out.ViewFolder.php?folderid=' + id; // window.location = '../out/out.ViewFolder.php?folderid=' + id;
console.log(id); $('div.ajax').trigger('update', {folderid: id, orderby: '<?= $orderby ?>'});
$('div.ajax').trigger('update', {folderid: id});
} }
<?php if($maxItemsPerPage) { ?> <?php if($maxItemsPerPage) { ?>
function loadMoreObjects(element, limit) { function loadMoreObjects(element, limit) {
@ -544,7 +543,7 @@ $('#loadmore').click(function(e) {
// $this->folderList(); // $this->folderList();
?> ?>
<div class="ajax" data-view="ViewFolder" data-action="folderList" <?php echo ($folder ? "data-query=\"folderid=".$folder->getID()."\"" : "") ?>></div> <div class="ajax" data-view="ViewFolder" data-action="folderList" <?php echo ($folder ? "data-query=\"folderid=".$folder->getID()."&orderby=".$orderby."\"" : "") ?>></div>
<?php <?php
echo "</div>\n"; // End of right column div echo "</div>\n"; // End of right column div
echo "</div>\n"; // End of div around left and right column echo "</div>\n"; // End of div around left and right column