[FIX]Fixed the issue of false shown on event if the field shown on the event does not have value, which is usabilit issue.

bzr revid: msh@tinyerp.com-20120813091003-zql3k9d9uwoe2ay9
This commit is contained in:
msh-openerp
2012-08-13 14:40:03 +05:30
parent 1e9414c5aa
commit e50246bf3c
@@ -287,11 +287,15 @@ openerp.web_calendar.CalendarView = openerp.web.View.extend({
res_text = '';
if (this.info_fields) {
res_text = _.map(this.info_fields, function(fld) {
if(evt[fld] instanceof Array)
return evt[fld][1];
return evt[fld];
});
res_text = _.chain(this.info_fields)
.filter(function(fld){
return evt[fld] !== false;
})
.map(function(fld) {
if(evt[fld] instanceof Array)
return evt[fld][1];
return evt[fld];
}).value();
}
if (!date_stop && date_delay) {
date_stop = date_start.clone().addHours(date_delay);