bzr revid: fp@tinyerp.com-20120820192910-eodns32qy7pmoq6c
This commit is contained in:
Fabien Pinckaers 2012-08-20 21:29:10 +02:00
parent 7586e24a65
commit 4c65e524be
1 changed files with 4 additions and 4 deletions

View File

@ -479,10 +479,10 @@ openerp.mail = function(session) {
this.$element.find('div.oe_mail_thread_display').empty();
// var domain = this.get_fetch_domain(this.comments_structure);
return this.fetch_comments(this.options.limit, this.options.offset, domain).then();
return this.fetch_comments(this.options.domain || []).then();
},
fetch_comments: function (limit, offset, domain) {
fetch_comments: function (domain) {
var self = this;
var defer = this.ds.call('message_read', [[this.options.res_id], (this.options.thread_level > 0), (this.comments_structure['root_ids']),
(limit+1) || (this.options.limit+1), offset||this.options.offset, domain||undefined ]).then(function (records) {
@ -622,7 +622,7 @@ openerp.mail = function(session) {
do_more: function () {
domain = this.get_fetch_domain(this.comments_structure);
return this.fetch_comments(this.options.limit, this.options.offset, domain);
return this.fetch_comments(domain);
},
});
@ -645,7 +645,7 @@ openerp.mail = function(session) {
init: function() {
this._super.apply(this, arguments);
this.params = this.options;
this.params = this.options || {};
this.params.thread_level = this.params.thread_level || 0;
this.thread = null;
},