diff --git a/addons/mail/static/src/js/mail.js b/addons/mail/static/src/js/mail.js index 5e4e4d7d689..7025dcb2bd1 100644 --- a/addons/mail/static/src/js/mail.js +++ b/addons/mail/static/src/js/mail.js @@ -1307,7 +1307,7 @@ openerp.mail = function(session) { var thread_displayed = this.message_render(); this.options.domain = this.options.domain.concat(this.search_results['domain']); this.bind_events(); - return (searchview_ready && thread_displayed); + return $.when(searchview_ready, thread_displayed); }, /** @@ -1377,6 +1377,7 @@ openerp.mail = function(session) { bind_events: function(){ var self=this; this.$("button.oe_write_full:first").click(function(){ self.thread.ComposeMessage.on_compose_fullmail(); }); + this.$("button.oe_write_onwall:first").click(function(){ self.thread.ComposeMessage.$el.toggle(); }); } });