diff options
| author | Christophe Simonis <chs@odoo.com> | 2015-01-06 11:49:04 +0100 |
|---|---|---|
| committer | Christophe Simonis <chs@odoo.com> | 2015-01-06 11:49:04 +0100 |
| commit | fab4d6d442ebbf081ead7e747f04b61e01ae9db2 (patch) | |
| tree | 3dd9aad0f429f4229e500db503bbf8b7155f9c38 /addons/mail/static/src/js/mail.js | |
| parent | 7fea986fd9f6f3ce1cc6c015a2523fdd23cf814d (diff) | |
| parent | ea54d4af9f75e518c5871213a668a9f516e56830 (diff) | |
[MERGE] forward port of branch 8.0 up to ea54d4a
Diffstat (limited to 'addons/mail/static/src/js/mail.js')
| -rw-r--r-- | addons/mail/static/src/js/mail.js | 10 |
1 files changed, 7 insertions, 3 deletions
diff --git a/addons/mail/static/src/js/mail.js b/addons/mail/static/src/js/mail.js index 2cdfcdff4ac..d99fd5d2f15 100644 --- a/addons/mail/static/src/js/mail.js +++ b/addons/mail/static/src/js/mail.js @@ -652,8 +652,8 @@ openerp.mail = function (session) { if (self.flag_post) { return; } - self.flag_post = true; if (this.do_check_attachment_upload() && (this.attachment_ids.length || this.$('textarea').val().match(/\S+/))) { + self.flag_post = true; if (this.is_log) { this.do_send_message_post([], this.is_log); } @@ -880,7 +880,11 @@ openerp.mail = function (session) { self.parent_thread.message_fetch(this.domain, this.context, false, function (arg, data) { self.id = false; // insert the message on dom after this message - self.parent_thread.switch_new_message(data, self.$el); + var element = self.$el; + if (self.thread_level === 0){ + element = element.parent(); + } + self.parent_thread.switch_new_message(data, element); self.animated_destroy(200); }); @@ -1943,7 +1947,7 @@ openerp.mail = function (session) { 'show_compact_message': this.action.params.view_mailbox ? false : 1, 'view_inbox': false, 'emails_from_on_composer': false, - 'fetch_limit': 1000 // allow inbox to load all children messages + 'fetch_limit': 30 // allow inbox to load all children messages }, this.action.params); }, |
