update styling for conditionals and simplifying conditional by only
relying on dtstart instead of also counting vevents (since they imply
the same condition, assuming valid events)
Signed-off-by: leith abdulla <online-nextcloud@eleith.com>
when importing ics files from third party services (ex: google), long
running recurrence vcalander objects can contain numerous vevents
relating to past exemptions or edits.
these objects are handled incorrectly, leading to incorrect first and/or
last occurence dates from being inferred. as a result, a number of
imported events are not rendered in the calendar.
this PR makes use of EventIterator's constructor that takes in an array
of VEVENTS to properly handle these complex cases.
Also of note is that other parameter signatures of EventIterator's constructor,
will be deprecated, according to comments in sabre dav EventIterator.php
Signed-off-by: leith abdulla <online-nextcloud@eleith.com>
when iterating through a calendar, recurrance events can throw an
exception if no instances of the recurrance are found.
this exception is of class `Exception` but the try/catch clause in the
webcal refresh loop only catches `BadRequest` exception.
this leads to the exception bubbling up and thus other calendar events
do not get processed by the event iterator.
this PR broadens the exception to handle both BadRequest and
NoInstanceFoundException so that the full webcal can be processed, even
if minor hiccups are processing on vobject
Signed-off-by: leith abdulla <online-nextcloud@eleith.com>
IMipPlugin.php Removed blank lines to make php-cs-fixer happy.
Minor cleanup: bugs found by Psalm static checker
IEMailTemplate: The public interface to addBodyListItem also needs to include the new plainIndent parameter.
IMipPlugin: Fixes an undefined variable for events that do not have DTEND. Also use explicit string conversion for parameters and properties in several places.
The new email template adds an additional blank line before "button" links in plain text, so the tests were fixed to include that additional blank line.
Signed-off-by: Brad Rubenstein <brad@wbr.tech>
iMIP e-mails were, as a hack, using filetypes icons for caldav
elements (titles, locations). This commit creates a folder of
caldav element icons. To start, they are used in iMIP emails,
but eventually should be used by any app that wants to have icon
labels for caldav elements.
Signed-off-by: brad2014 <brad2014@users.noreply.github.com>
This PR is a replacement for PR #17195. It is intended to be simpler
to review and approve, with fewer changes, some disabled by default.
It addresses issues #12391 and #13555, with the following changes:
- The plainText of iMIP emails has been upgraded as described in
issue #12391. The HTML design style has not been changed.
- Some of the HTML and plainText content has been rearranged
(simplified header language, moving the event title to from text
body to the first item in the bullet list, spelling corrections,
moving the description to the end of the list), per issue #12391.
- The interface for EMailTemplate has been extended: addBodyListItem
now takes an optional `plainIndent` parameter. Existing callers
see no change. Where new calls set the new parameter >0, the list
item label (metaInfo) is put in column 1, and the value is indented
into column 2 (properly accounting for multiple lines, if any).
- An optional dav config setting has been added,
`invitation_list_attendees`. It defaults to 'no', leaving emails
unchanged. If set by the site admin to 'yes', then iMIP emails
include, for the organizer and each attendee, their name, email,
and a ✔︎ if they have accepted the invitation.
- Minor refactoring.
Notes:
- The labels for organizers and attendees list items are new, and
require translation/localization.
- Dav config settings are documented in the code, but not in the
Administrator's Guide.
Signed-off-by: brad2014 <brad2014@users.noreply.github.com>