mirror of
https://github.com/apache/cloudstack.git
synced 2025-10-26 08:42:29 +01:00
CS-15572: Fix page index for list view filters
This fixes an issue where the page index is not reset back 1 when activating the search or filter functionality, causing truncation when trying to scroll down to later pages.
This commit is contained in:
parent
dfb0eed5a4
commit
2b2e491f27
@ -974,8 +974,8 @@
|
||||
if (!options) options = {};
|
||||
var context = options.context;
|
||||
var reorder = options.reorder;
|
||||
|
||||
var $tbody = $table.find('tbody');
|
||||
|
||||
if (!loadArgs) loadArgs = {
|
||||
page: 1,
|
||||
filterBy: {
|
||||
@ -1262,6 +1262,7 @@
|
||||
});
|
||||
|
||||
var search = function() {
|
||||
page = 1;
|
||||
loadBody(
|
||||
$table,
|
||||
listViewData.dataProvider,
|
||||
@ -1269,7 +1270,7 @@
|
||||
listViewData.fields,
|
||||
false,
|
||||
{
|
||||
page: 1,
|
||||
page: page,
|
||||
filterBy: {
|
||||
kind: $listView.find('select[id=filterBy]').val(),
|
||||
search: {
|
||||
@ -1316,7 +1317,8 @@
|
||||
var context = $listView.data('view-args').context;
|
||||
|
||||
if (loadMoreData) {
|
||||
page = page + 1;
|
||||
page = page + 1;
|
||||
|
||||
loadBody($table, listViewData.dataProvider, listViewData.preFilter, listViewData.fields, true, {
|
||||
context: context,
|
||||
page: page,
|
||||
|
||||
Loading…
x
Reference in New Issue
Block a user