summaryrefslogtreecommitdiff
path: root/addons/web/static/src/js/views/basic
diff options
context:
space:
mode:
Diffstat (limited to 'addons/web/static/src/js/views/basic')
-rw-r--r--addons/web/static/src/js/views/basic/basic_controller.js11
1 files changed, 11 insertions, 0 deletions
diff --git a/addons/web/static/src/js/views/basic/basic_controller.js b/addons/web/static/src/js/views/basic/basic_controller.js
index 2847003f5df..c21d7a43335 100644
--- a/addons/web/static/src/js/views/basic/basic_controller.js
+++ b/addons/web/static/src/js/views/basic/basic_controller.js
@@ -108,6 +108,17 @@ return AbstractController.extend(FieldManagerMixin, {
}
},
/**
+ * Used by list and kanban views to determine whether or not to display
+ * the no content helper (if there is no data in the state to display)
+ *
+ * @private
+ * @param {Object} state
+ * @returns {boolean}
+ */
+ _hasContent: function (state) {
+ return state.count !== 0;
+ },
+ /**
* Hook method, called when record(s) has been deleted.
*
* @see _deleteRecord