From 3385942a58265edcd416dab56094958efea8d929 Mon Sep 17 00:00:00 2001 From: Anvit Srivastav Date: Mon, 12 Feb 2024 14:18:59 -0800 Subject: [PATCH] Increase default treeview items per page (#1748) Increase the default limit for items per page in treeview to 8000 --- apps/qubit/modules/browse/actions/hierarchyAction.class.php | 2 +- apps/qubit/modules/default/actions/fullTreeViewAction.class.php | 2 +- .../informationobject/actions/treeViewComponent.class.php | 2 +- apps/qubit/modules/settings/actions/treeviewAction.class.php | 2 +- 4 files changed, 4 insertions(+), 4 deletions(-) diff --git a/apps/qubit/modules/browse/actions/hierarchyAction.class.php b/apps/qubit/modules/browse/actions/hierarchyAction.class.php index 63e0f92fca..49cebb3778 100644 --- a/apps/qubit/modules/browse/actions/hierarchyAction.class.php +++ b/apps/qubit/modules/browse/actions/hierarchyAction.class.php @@ -9,6 +9,6 @@ public function execute($request) QubitAcl::forwardUnauthorized(); } - $this->itemsPerPage = sfConfig::get('app_treeview_full_items_per_page', 50); + $this->itemsPerPage = sfConfig::get('app_treeview_full_items_per_page', 8000); } } diff --git a/apps/qubit/modules/default/actions/fullTreeViewAction.class.php b/apps/qubit/modules/default/actions/fullTreeViewAction.class.php index 756ff949e7..b4208adf32 100644 --- a/apps/qubit/modules/default/actions/fullTreeViewAction.class.php +++ b/apps/qubit/modules/default/actions/fullTreeViewAction.class.php @@ -343,7 +343,7 @@ protected function formatResultData($result, $options) protected function getPageLimit($options) { // Get default limit from config - $limit = sfConfig::get('app_treeview_full_items_per_page', 50); + $limit = sfConfig::get('app_treeview_full_items_per_page', 8000); if (isset($options['limit']) && intval($options['limit']) > 0) { $limit = intval($options['limit']); diff --git a/apps/qubit/modules/informationobject/actions/treeViewComponent.class.php b/apps/qubit/modules/informationobject/actions/treeViewComponent.class.php index f43ffdaa4d..e8e88b6fb4 100644 --- a/apps/qubit/modules/informationobject/actions/treeViewComponent.class.php +++ b/apps/qubit/modules/informationobject/actions/treeViewComponent.class.php @@ -26,7 +26,7 @@ public function execute($request) $this->treeviewType = sfConfig::get('app_treeview_type__source', 'sidebar'); if ('sidebar' != $this->treeviewType) { $this->collapsible = sfConfig::get('app_treeview_allow_full_width_collapse'); - $this->itemsPerPage = sfConfig::get('app_treeview_full_items_per_page', 50); + $this->itemsPerPage = sfConfig::get('app_treeview_full_items_per_page', 8000); return sfView::SUCCESS; } diff --git a/apps/qubit/modules/settings/actions/treeviewAction.class.php b/apps/qubit/modules/settings/actions/treeviewAction.class.php index 1d17dfef07..816851556a 100644 --- a/apps/qubit/modules/settings/actions/treeviewAction.class.php +++ b/apps/qubit/modules/settings/actions/treeviewAction.class.php @@ -147,7 +147,7 @@ protected function addField($name) case 'fullItemsPerPage': $this->fullItemsPerPageSetting = QubitSetting::getByName('treeview_full_items_per_page'); - $default = 50; + $default = 8000; if (isset($this->fullItemsPerPageSetting)) { $default = $this->fullItemsPerPageSetting->getValue(['sourceCulture' => true]); }