From fdb1595cd5d40481c4443ac7b94aa7526ba36e5a Mon Sep 17 00:00:00 2001 From: Yuri Kuznetsov Date: Mon, 26 Aug 2024 23:39:15 +0300 Subject: [PATCH] sticky bar fix --- client/res/templates/record/list-expanded.tpl | 4 ++-- client/src/views/notification/panel.js | 2 +- client/src/views/record/list.js | 6 ++++-- 3 files changed, 7 insertions(+), 5 deletions(-) diff --git a/client/res/templates/record/list-expanded.tpl b/client/res/templates/record/list-expanded.tpl index d3401a0ffa..ed839a99c7 100644 --- a/client/res/templates/record/list-expanded.tpl +++ b/client/res/templates/record/list-expanded.tpl @@ -1,11 +1,11 @@ {{#if collection.models.length}} - {{#hasStickyBar}} + {{#if hasStickyBar}} - {{/hasStickyBar}} + {{/if}} {{#if topBar}}
diff --git a/client/src/views/notification/panel.js b/client/src/views/notification/panel.js index 6569e3732a..c73f2e503a 100644 --- a/client/src/views/notification/panel.js +++ b/client/src/views/notification/panel.js @@ -122,7 +122,7 @@ class NotificationPanelView extends View { view: 'views/notification/fields/read', width: '10px', }, - } + }, }); } diff --git a/client/src/views/record/list.js b/client/src/views/record/list.js index dba5ca9337..35e46379dd 100644 --- a/client/src/views/record/list.js +++ b/client/src/views/record/list.js @@ -991,10 +991,12 @@ class ListRecordView extends View { topBar = false; } - const displayActionsButtonGroup = this.checkboxes || this.massActionList || this.buttonList.length || + const checkboxes = this.checkboxes && this.massActionList.length; + + const displayActionsButtonGroup = checkboxes || this.buttonList.length || this.dropdownItemList.length; - const hasStickyBar = this.forceStickyBar || displayActionsButtonGroup; + const hasStickyBar = this.forceStickyBar || displayActionsButtonGroup || this.pagination; const noDataDisabled = this.noDataDisabled || this._renderEmpty;