Ignore user preferences for lists when setup modal is disabled (#4921)

This commit is contained in:
Rike-cz 2020-02-10 07:24:09 +01:00 committed by GitHub
parent dc5431f9c4
commit 495b0f085a
1 changed files with 4 additions and 2 deletions

View File

@ -210,7 +210,9 @@ class Lists extends WidgetBase
/* /*
* Configure the list widget * Configure the list widget
*/ */
$this->recordsPerPage = $this->getUserPreference('per_page', $this->recordsPerPage); if ($this->showSetup) {
$this->recordsPerPage = $this->getUserPreference('per_page', $this->recordsPerPage);
}
if ($this->showPagination == 'auto') { if ($this->showPagination == 'auto') {
$this->showPagination = $this->recordsPerPage && $this->recordsPerPage > 0; $this->showPagination = $this->recordsPerPage && $this->recordsPerPage > 0;
@ -728,7 +730,7 @@ class Lists extends WidgetBase
/* /*
* Supplied column list * Supplied column list
*/ */
if ($this->columnOverride === null) { if ($this->showSetup && $this->columnOverride === null) {
$this->columnOverride = $this->getUserPreference('visible', null); $this->columnOverride = $this->getUserPreference('visible', null);
} }