Home | News | Projects | Releases
Bugs | RFE | Repositories | Help
Added RRULE property for saving data from a CalendarTaskObject.
authorSteve Brokenshire <sbrokenshire@xestia.co.uk>
Mon, 6 Jun 2016 21:49:40 +0000 (22:49 +0100)
committerSteve Brokenshire <sbrokenshire@xestia.co.uk>
Mon, 6 Jun 2016 21:49:40 +0000 (22:49 +0100)
Added the code and unit tests for the RRULE property.

source/objects/calendartask/CalendarTask-Save.cpp
source/tests/xestiacalendar_icaltasksave.h

index 5563801..d311cd3 100644 (file)
@@ -611,6 +611,32 @@ void CalendarTaskObject::SaveObjectData(string *SaveData){
                
        }
        
+       // Process the RRULE value.
+       
+       if (RecurranceRuleData.size() > 0){
+               
+               DataLine += "RRULE";
+
+               if (RecurranceRuleDataTokens.size() > 0){
+               
+                       DataLine += ";";
+                       DataLine += RecurranceRuleDataTokens;
+                       
+               }
+               
+               DataLine += ":";
+               DataLine += RecurranceRuleData;
+               DataLine += "\n";
+               
+               DataLineProcessed = OutputText(&DataLine);
+               
+               *SaveData += DataLineProcessed;
+
+               DataLine.clear();
+               DataLineProcessed.clear();
+               
+       }
+       
        *SaveData += "END:VTODO\n";
        
 }
\ No newline at end of file
index d267c46..0b6eba2 100644 (file)
@@ -80,6 +80,7 @@ TEST(iCalendarSaveTask, SaveTaskTests){
        "SUMMARY;ALTREP=\"null:nodata\";LANGUAGE=kw;FAVOURITE=TOFU;NOTLIKE=NONE:A summar\n"
        " y of the todo.\n"
        "URL;EXTERNAL=YES:http://www.example.com/\n"
+       "RRULE;TEST=DATA:FREQ=DAILY;COUNT=10\n"
        "END:VTODO\n"
        "END:VCALENDAR";
        
Xestia Software Development
Yn Maystri
© 2006 - 2019 Xestia Software Development
Software

Xestia Address Book
Xestia Calendar
Development

Xestia Gelforn
Everything else

About
News
Privacy Policy