[FIX] mail: needactions: send mentionned partners on message post
When posting a message, the ids of mentionned partners are specified in the
partner_ids array. This has been broken in commit 388f7a7d, my bad.
This commit is contained in:
@@ -108,6 +108,11 @@ var MentionManager = Widget.extend({
|
||||
return this.open;
|
||||
},
|
||||
|
||||
get_listener_selection: function (delimiter) {
|
||||
var listener = _.findWhere(this.listeners, {delimiter: delimiter});
|
||||
return listener ? listener.selection : [];
|
||||
},
|
||||
|
||||
proposition_navigation: function (keycode) {
|
||||
var $active = this.$('.o_mention_proposition.active');
|
||||
if (keycode === $.ui.keyCode.ENTER) { // selecting proposition
|
||||
@@ -398,7 +403,7 @@ var Composer = Widget.extend({
|
||||
return $.when({
|
||||
content: this.mention_manager.generate_links(value),
|
||||
attachment_ids: _.pluck(this.get('attachment_ids'), 'id'),
|
||||
partner_ids: _.pluck(this.get('mention_selected_partners'), 'id'),
|
||||
partner_ids: _.pluck(this.mention_manager.get_listener_selection('@'), 'id'),
|
||||
});
|
||||
},
|
||||
|
||||
|
||||
Reference in New Issue
Block a user