From ea8bf7cdee66921a04150b65896f8aefd424249f Mon Sep 17 00:00:00 2001 From: Jan Schneider Date: Tue, 8 Sep 2009 14:39:55 +0200 Subject: [PATCH] MFB: Allow to add address lists as attendees through the address book popup (Bug #7834). --- kronolith/docs/CHANGES | 4 ++++ kronolith/templates/contacts/contacts.inc | 13 +++++++------ 2 files changed, 11 insertions(+), 6 deletions(-) diff --git a/kronolith/docs/CHANGES b/kronolith/docs/CHANGES index d59752ccb..e5fc122fb 100644 --- a/kronolith/docs/CHANGES +++ b/kronolith/docs/CHANGES @@ -23,6 +23,10 @@ v3.0-git v2.3.2-cvs ---------- +[jan] Allow to add address lists as attendees through the address book popup + (Bug #7834). +[jan] Fix exporting certain weekday recurrence rules to iCalendar + (lst_hoe02@kwsoft.de, Bug #8501). [jan] Export recurrence end dates as date-time values in iCalendar data to improve compatibility with external clients (Bug #7846). [jan] Fix synchronization with output compression enabled (Bug #7769). diff --git a/kronolith/templates/contacts/contacts.inc b/kronolith/templates/contacts/contacts.inc index cb4997b77..3a55b4515 100644 --- a/kronolith/templates/contacts/contacts.inc +++ b/kronolith/templates/contacts/contacts.inc @@ -93,15 +93,16 @@ function updateMessage() var address = list.options[i].text; var fullname = decodeURIComponent(list.options[i].value); } - if (address.indexOf(':') != -1) { - continue; + if (address.indexOf(':') == -1) { + fullname = fullname.replace(/\\/g, '\\\\').replace(/"/g, '\\"'); + address = '"' + fullname + '" <' + address + '>'; } - fullname = fullname.replace(/\\/g, '\\\\').replace(/"/g, '\\"'); - address = '"' + fullname + '" <' + address + '>'; - if (field.value) { - field.value = field.value + ', ' + address; + if (!field.value.match(/;\s*$/)) { + field.value = field.value + ','; + } + field.value = field.value + ' ' + address; } else { field.value = address; } -- 2.11.0