Prepare database to manage recurring events

This commit is contained in:
Laurent Destailleur 2015-05-17 20:12:49 +02:00
parent c89c883d7d
commit 851007f1a8
3 changed files with 62 additions and 1 deletions

57
dev/ical/event_recu.txt Normal file
View File

@ -0,0 +1,57 @@
Example fo recurring event, 1 week, no end, exported by Google
# The recurring event were recorded every monday the 20150518. This is the Recurrence-id, but then
# first occurence was moved on tuesday. So this record were added.
BEGIN:VEVENT
DTSTART;TZID=Europe/Paris:20150519T100000
DTEND;TZID=Europe/Paris:20150519T110000
DTSTAMP:20150517T175754Z
UID:9026chuafli29ns5soshvckamc@google.com
RECURRENCE-ID;TZID=Europe/Paris:20150518T100000
CREATED:20150517T174404Z
DESCRIPTION:
LAST-MODIFIED:20150517T175008Z
LOCATION:
SEQUENCE:1
STATUS:CONFIRMED
SUMMARY:aaa
TRANSP:OPAQUE
END:VEVENT
# The recurring event were recorded every monday the 20150518.
BEGIN:VEVENT
DTSTART;TZID=Europe/Paris:20150518T100000
DTEND;TZID=Europe/Paris:20150518T110000
RRULE:FREQ=WEEKLY;BYDAY=MO
DTSTAMP:20150517T175754Z
UID:9026chuafli29ns5soshvckamc@google.com
CREATED:20150517T174404Z
DESCRIPTION:
LAST-MODIFIED:20150517T174404Z
LOCATION:
SEQUENCE:0
STATUS:CONFIRMED
SUMMARY:aaa
TRANSP:OPAQUE
END:VEVENT
Example fo recurring event, every 2 month, no end, exported by Google
BEGIN:VEVENT
DTSTART;TZID=Europe/Paris:20150519T080000
DTEND;TZID=Europe/Paris:20150519T090000
RRULE:FREQ=MONTHLY;INTERVAL=2;BYMONTHDAY=19
DTSTAMP:20150517T175754Z
UID:urkq3ih1mlaqeu4dbkpdh4i61s@google.com
CREATED:20150517T175658Z
DESCRIPTION:
LAST-MODIFIED:20150517T175658Z
LOCATION:
SEQUENCE:0
STATUS:CONFIRMED
SUMMARY:bbbbb
TRANSP:OPAQUE
END:VEVENT

View File

@ -626,6 +626,8 @@ ALTER TABLE llx_actioncomm ADD COLUMN email_sender varchar(256);
ALTER TABLE llx_actioncomm ADD COLUMN email_to varchar(256);
ALTER TABLE llx_actioncomm ADD COLUMN errors_to varchar(256);
ALTER TABLE llx_actioncomm ADD COLUMN recurid varchar(128);
ALTER TABLE llx_actioncomm ADD COLUMN recurrule varchar(128);
ALTER TABLE llx_actioncomm ADD COLUMN ecurdateend datetime;
ALTER TABLE llx_stcomm ADD COLUMN picto varchar(128);

View File

@ -61,7 +61,9 @@ create table llx_actioncomm
errors_to varchar(256), -- when event was an email, we store here the erros_to
recurid varchar(128), -- used to store event id to link all recurring event records each other
recurrule varchar(128), -- contains string with ical format recurring rule like "FREQ=MONTHLY;INTERVAL=2;BYMONTHDAY=19" or "FREQ=WEEKLY;BYDAY=MO"
recurdateend datetime,
fk_element integer DEFAULT NULL,
elementtype varchar(32) DEFAULT NULL