[FIX] Use $el.find() to find the current calendar, else we got undesired effect in dashboard where when we do a quick_create, all dashboards of type calendar was impacted by the selector $()

bzr revid: jke@openerp.com-20140218090322-fp3ybgfwmjcteadp
This commit is contained in:
jke-openerp 2014-02-18 00:03:22 -09:00
parent ec93eb7967
commit bbf433c13d
1 changed files with 13 additions and 12 deletions

View File

@ -393,7 +393,7 @@ openerp.web_calendar = function(instance) {
delete this.quick;
this.$calendar.fullCalendar('unselect');
});
this.quick.replace($(".oe_calendar_qc_placeholder"));
this.quick.replace(this.$el.find('.oe_calendar_qc_placeholder'));
this.quick.focus();
},
@ -573,7 +573,8 @@ openerp.web_calendar = function(instance) {
attendee_showed += 1;
if (attendee_showed<= MAX_ATTENDEES) {
if (self.avatar_model !== null) {
the_title_avatar += '<img title="' + 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>';
the_title_avatar += '<img title="' + 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>';
}
else {
if (!self.colorIsAttendee || the_attendee_people != temp_ret[self.color_field]) {
@ -1378,7 +1379,7 @@ openerp.web_calendar = function(instance) {
},
alternative_form_view: this.field.views ? this.field.views.form : undefined,
parent_view: this.view, //XXXvlab: to check ! this.view is likely undefined
parent_view: this.view,
child_name: this.name,
readonly: this.get("effective_readonly")
});