[FIX] calendar: tag template data
Tag template data were wrong since many2manytag color introduction
This commit is contained in:
@@ -239,7 +239,14 @@ var Many2ManyAttendee = FieldMany2ManyTags.extend({
|
||||
tag_template: "Many2ManyAttendeeTag",
|
||||
get_render_data: function(ids){
|
||||
var dataset = new data.DataSetStatic(this, this.field.relation, this.build_context());
|
||||
return dataset.call('get_attendee_detail',[ids, this.getParent().datarecord.id || false]);
|
||||
return dataset.call('get_attendee_detail',[ids, this.getParent().datarecord.id || false])
|
||||
.then(process_data);
|
||||
|
||||
function process_data(data) {
|
||||
return _.map(data, function(d) {
|
||||
return _.object(['id', 'name', 'status'], d);
|
||||
});
|
||||
}
|
||||
}
|
||||
});
|
||||
|
||||
|
||||
@@ -2,7 +2,7 @@
|
||||
<template>
|
||||
<t t-name="Many2ManyAttendeeTag" t-extend="FieldMany2ManyTag">
|
||||
<t t-jquery="span:first" t-operation="prepend">
|
||||
<span t-attf-class="o_calendar_invitation #{el[2]}"/>
|
||||
<span t-attf-class="o_calendar_invitation #{el['status']}"/>
|
||||
</t>
|
||||
</t>
|
||||
|
||||
|
||||
Reference in New Issue
Block a user