Hello,
I am trying to add an event on tags of many2many fields if form is in edit mode. For that I have written below code:
var FieldMany2ManyTags = relationalField.FieldMany2ManyTags.extend({
events: _.extend({}, FieldMany2ManyTags.prototype.events, {
'click .o_tag_color_0': '_onClickTag',
}),
_onClickTag: function(events){
console.log('Test');
alert('many2many tag');
},
But click on tags click event is not call. It give me following error on inspect console as:
TypeError: Cannot read property 'prototype' of undefined
I am doing somthing wrong? Any alternative way is available for the same
Thanks In advance.