[FIX] web_calendar, website: avoid rendering errors with special characters
This commit is contained in:
parent
d0735fc557
commit
e3bd2a5914
|
@ -544,7 +544,7 @@ openerp.web_calendar = function(instance) {
|
||||||
attendee_showed += 1;
|
attendee_showed += 1;
|
||||||
if (attendee_showed<= MAX_ATTENDEES) {
|
if (attendee_showed<= MAX_ATTENDEES) {
|
||||||
if (self.avatar_model !== null) {
|
if (self.avatar_model !== null) {
|
||||||
the_title_avatar += '<img title="' + self.all_attendees[the_attendee_people] + '" class="attendee_head" \
|
the_title_avatar += '<img title="' + _.escape(self.all_attendees[the_attendee_people]) + '" class="attendee_head" \
|
||||||
src="/web/binary/image?model=' + self.avatar_model + '&field=image_small&id=' + the_attendee_people + '"></img>';
|
src="/web/binary/image?model=' + self.avatar_model + '&field=image_small&id=' + the_attendee_people + '"></img>';
|
||||||
}
|
}
|
||||||
else {
|
else {
|
||||||
|
@ -552,12 +552,12 @@ openerp.web_calendar = function(instance) {
|
||||||
tempColor = (self.all_filters[the_attendee_people] !== undefined)
|
tempColor = (self.all_filters[the_attendee_people] !== undefined)
|
||||||
? self.all_filters[the_attendee_people].color
|
? self.all_filters[the_attendee_people].color
|
||||||
: (self.all_filters[-1] ? self.all_filters[-1].color : 1);
|
: (self.all_filters[-1] ? self.all_filters[-1].color : 1);
|
||||||
the_title_avatar += '<i class="fa fa-user attendee_head color_'+tempColor+'" title="' + self.all_attendees[the_attendee_people] + '" ></i>';
|
the_title_avatar += '<i class="fa fa-user attendee_head color_'+tempColor+'" title="' + _.escape(self.all_attendees[the_attendee_people]) + '" ></i>';
|
||||||
}//else don't add myself
|
}//else don't add myself
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
else {
|
else {
|
||||||
attendee_other += self.all_attendees[the_attendee_people] +", ";
|
attendee_other += _.escape(self.all_attendees[the_attendee_people]) +", ";
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
);
|
);
|
||||||
|
|
|
@ -152,7 +152,7 @@
|
||||||
website.snippet.animationRegistry.media_video = website.snippet.Animation.extend({
|
website.snippet.animationRegistry.media_video = website.snippet.Animation.extend({
|
||||||
selector: ".media_iframe_video",
|
selector: ".media_iframe_video",
|
||||||
start: function () {
|
start: function () {
|
||||||
this.$target.html('<div class="css_editable_mode_display"> </div><iframe src="'+this.$target.data("src")+'" frameborder="0" allowfullscreen="allowfullscreen"></iframe>');
|
this.$target.html('<div class="css_editable_mode_display"> </div><iframe src="'+_.escape(this.$target.data("src"))+'" frameborder="0" allowfullscreen="allowfullscreen"></iframe>');
|
||||||
},
|
},
|
||||||
});
|
});
|
||||||
})();
|
})();
|
||||||
|
|
Loading…
Reference in New Issue