Skip to content
Snippets Groups Projects
Commit 0c294774 authored by Peter Rotich's avatar Peter Rotich
Browse files

bug: Page Limit

Default to system default of staff doesn't have page limit set.

Credit: @antriver PR#2951
parent 593b3753
Branches
Tags
No related merge requests found
......@@ -48,7 +48,7 @@ class ConfigAjaxAPI extends AjaxController {
'primary_lang_flag' => strtolower($primary_info['flag'] ?: $primary_locale ?: $primary_sl),
'primary_language' => Internationalization::rfc1766($primary),
'secondary_languages' => $cfg->getSecondaryLanguages(),
'page_size' => $thisstaff->getPageLimit(),
'page_size' => $thisstaff->getPageLimit() ?: PAGE_LIMIT,
);
return $this->json_encode($config);
}
......
......@@ -107,7 +107,7 @@ $ost->addExtraHeader('<meta name="csrf_token" content="'.$ost->getCSRFToken().'"
require_once(INCLUDE_DIR.'class.nav.php');
/******* SET STAFF DEFAULTS **********/
define('PAGE_LIMIT', $thisstaff->getPageLimit()?$thisstaff->getPageLimit():DEFAULT_PAGE_LIMIT);
define('PAGE_LIMIT', $thisstaff->getPageLimit() ?: DEFAULT_PAGE_LIMIT);
$tabs=array();
$submenu=array();
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Please register or to comment