From cc6a60bec935a42e19bac0bef5771dfcbad81f83 Mon Sep 17 00:00:00 2001 From: Julien Mougenot Date: Fri, 31 Jul 2020 11:50:56 +0000 Subject: [IMP] web: Optimize action model loading The loading of the action model extensions have been split in this commit: - when calling load, a first promise is returned. It is meant to be resolved as soon as all the query informations are available. - a second promise returned by a new method "isReady" is resolved when all of the extension data have been fetched. This difference allow to not wait for server calls irrelevant for the query. By default "isReady" will always wait for a full load call, but this is meant to be overridden in case optimisations can be made. --- addons/web/static/src/js/views/abstract_controller.js | 1 - 1 file changed, 1 deletion(-) (limited to 'addons/web/static/src/js/views/abstract_controller.js') diff --git a/addons/web/static/src/js/views/abstract_controller.js b/addons/web/static/src/js/views/abstract_controller.js index 5128fa6d9a8..2f819bff7a5 100644 --- a/addons/web/static/src/js/views/abstract_controller.js +++ b/addons/web/static/src/js/views/abstract_controller.js @@ -222,7 +222,6 @@ var AbstractController = mvc.Controller.extend(ActionMixin, { reload: async function (params = {}) { if (params.controllerState) { this.importState(params.controllerState); - await this.searchModel.load(); Object.assign(params, this.searchModel.get('query')); } return this.update(params, {}); -- cgit v1.2.3