Welcome to mirror list, hosted at ThFree Co, Russian Federation.

github.com/zabbix/zabbix.git - Unnamed repository; edit this file 'description' to name the repository.
summaryrefslogtreecommitdiff
path: root/ui/app
diff options
context:
space:
mode:
authorGregory Chalenko <gregory.chalenko@zabbix.com>2020-08-02 14:18:51 +0300
committerGregory Chalenko <gregory.chalenko@zabbix.com>2020-08-02 14:18:51 +0300
commite30c15c716487d71f8329ddd2eb48ec8535c770b (patch)
tree12bfdaabca855fdef371553fdacc10834b751925 /ui/app
parentf5d80303bc8ae5489920f8ad63a47592eb7b3515 (diff)
..F....... [ZBXNEXT-710] fixed url for unsaved filter when sorting or changing result page
Diffstat (limited to 'ui/app')
-rw-r--r--ui/app/controllers/CControllerHost.php2
-rw-r--r--ui/app/controllers/CControllerHostViewRefresh.php6
2 files changed, 6 insertions, 2 deletions
diff --git a/ui/app/controllers/CControllerHost.php b/ui/app/controllers/CControllerHost.php
index cfec8b61cfd..f135594b070 100644
--- a/ui/app/controllers/CControllerHost.php
+++ b/ui/app/controllers/CControllerHost.php
@@ -217,7 +217,7 @@ abstract class CControllerHost extends CController {
// Sort for paging so we know which IDs go to which page.
CArrayHelper::sort($hosts, [['field' => $filter['sort'], 'order' => $filter['sortorder']]]);
- $view_curl = (new CUrl('zabbix.php'))->setArgument('action', 'host.view');
+ $view_curl = (new CUrl())->setArgument('action', 'host.view');
// Split result array and create paging.
$paging = CPagerHelper::paginate($filter['page'], $hosts, $filter['sortorder'], $view_curl);
diff --git a/ui/app/controllers/CControllerHostViewRefresh.php b/ui/app/controllers/CControllerHostViewRefresh.php
index f4894196386..70582d46f99 100644
--- a/ui/app/controllers/CControllerHostViewRefresh.php
+++ b/ui/app/controllers/CControllerHostViewRefresh.php
@@ -108,9 +108,13 @@ class CControllerHostViewRefresh extends CControllerHost {
});
$prepared_data = $this->getData($filter);
+ $view_url = (new CUrl())
+ ->setArgument('action', 'host.view')
+ ->removeArgument('page');
+
$data = [
'filter' => $filter,
- 'view_curl' => (new CUrl('zabbix.php'))->setArgument('action', 'host.view'),
+ 'view_curl' => $view_url,
'sort' => $filter['sort'],
'sortorder' => $filter['sortorder']
] + $prepared_data;