diff options
| author | Christophe Simonis <chs@odoo.com> | 2018-01-08 11:15:33 +0100 |
|---|---|---|
| committer | Christophe Simonis <chs@odoo.com> | 2018-01-08 11:15:33 +0100 |
| commit | e3080d8433e77c3efb9be65637cdc50086297ef2 (patch) | |
| tree | 6735018f3d9a1ba7e028a8784600580dfb327833 /addons/mail/static/src | |
| parent | bc3d5ca7755d8a0d9a3e4c185b26e201ed8fefc3 (diff) | |
| parent | 35c829f12b28615351cb306397b1a3dfbfdeaccb (diff) | |
[MERGE] forward port branch 9.0 up to 35c829f12b2
Diffstat (limited to 'addons/mail/static/src')
| -rw-r--r-- | addons/mail/static/src/js/client_action.js | 10 |
1 files changed, 9 insertions, 1 deletions
diff --git a/addons/mail/static/src/js/client_action.js b/addons/mail/static/src/js/client_action.js index bd7638ab9e2..165dda719c2 100644 --- a/addons/mail/static/src/js/client_action.js +++ b/addons/mail/static/src/js/client_action.js @@ -249,6 +249,9 @@ var ChatAction = Widget.extend(ControlPanelMixin, { var def3 = this.extended_composer.appendTo(this.$('.o_mail_chat_content')); var def4 = this.searchview.appendTo($("<div>")).then(function () { self.$searchview_buttons = self.searchview.$buttons.contents(); + // manually call do_search to generate the initial domain and filter + // the messages in the default channel + self.searchview.do_search(); }); this.render_sidebar(); @@ -565,7 +568,12 @@ var ChatAction = Widget.extend(ControlPanelMixin, { }); this.domain = result.domain; - this.fetch_and_render_thread(); + if (this.channel) { + // initially (when do_search is called manually), there is no + // channel set yet, so don't try to fetch and render the thread as + // this will be done as soon as the default channel is set + this.fetch_and_render_thread(); + } }, on_post_message: function (message) { |
