From 0b13d0deacc9e5f24d8d15f8c64b73991b9fc9b7 Mon Sep 17 00:00:00 2001 From: Nathan Gray Date: Tue, 17 Nov 2015 20:48:29 +0000 Subject: [PATCH] Nicer formatting in tooltip for multiple categories --- calendar/js/et2_widget_event.js | 7 +++++-- 1 file changed, 5 insertions(+), 2 deletions(-) diff --git a/calendar/js/et2_widget_event.js b/calendar/js/et2_widget_event.js index f440400153..05b04ff669 100644 --- a/calendar/js/et2_widget_event.js +++ b/calendar/js/et2_widget_event.js @@ -331,7 +331,10 @@ var et2_calendar_event = et2_valueWidget.extend([et2_IDetachedDOM], ''+this.egw().lang('End') + ':' + end var cat = et2_createWidget('select-cat',{'readonly':true},this); cat.set_value(this.options.value.category); - var cat_label = cat.span.text(); + var cat_label = []; + cat.span.children().each(function() { + cat_label.push($j(this).text()); + }); cat.destroy(); return '
'+ @@ -346,7 +349,7 @@ var et2_calendar_event = et2_valueWidget.extend([et2_IDetachedDOM], this.options.value.description+'

'+ '

'+times+'

'+ (this.options.value.location ? '

'+this.egw().lang('Location') + ':' + this.options.value.location+'

' : '')+ - (cat_label ? '

'+this.egw().lang('Category') + ':' + cat_label+'

' : '')+ + (cat_label ? '

'+this.egw().lang('Category') + ':' + cat_label.join(', ')+'

' : '')+ '

'+this.egw().lang('Participants')+':
'+ (this.options.value.parts ? this.options.value.parts.replace("\n","
"):'')+'

'+ '
'+