From: Art Cancro Date: Mon, 10 Nov 2008 22:39:08 +0000 (+0000) Subject: Form-to-icalrecur logic for both types of yearly events. X-Git-Tag: v7.86~1799 X-Git-Url: https://code.citadel.org/?p=citadel.git;a=commitdiff_plain;h=97c0d070bd992929cfd50a9d1cf9fb05d77e1268 Form-to-icalrecur logic for both types of yearly events. The recurrence editor is now feature complete. Unfortunately we are already seeing the nightmare of time zones causing problems with events recurring on the wrong day. Let the dystopic nightmare of timezone debugging begin. --- diff --git a/webcit/event.c b/webcit/event.c index 86142ad8c..138bc0ff3 100644 --- a/webcit/event.c +++ b/webcit/event.c @@ -938,11 +938,15 @@ void save_individual_event(icalcomponent *supplied_vevent, long msgnum, char *fr break; case ICAL_YEARLY_RECURRENCE: - if (!strcasecmp(bstr("rrmonthtype"), "rryeartype_ymday")) { + if (!strcasecmp(bstr("rryeartype"), "rryeartype_ymday")) { /* no further action is needed here */ } - if (!strcasecmp(bstr("rrmonthtype"), "rryeartype_ywday")) { - /* FIXME implement this */ + else if (!strcasecmp(bstr("rryeartype"), "rryeartype_ywday")) { + recur.by_month[0] = atoi(bstr("rrymonth")); + recur.by_month[1] = ICAL_RECURRENCE_ARRAY_MAX; + recur.by_day[0] = (atoi(bstr("rrymweek")) * 8) + + atoi(bstr("rrymweekday")) + 1; + recur.by_day[1] = ICAL_RECURRENCE_ARRAY_MAX; } break;