recurr icon indicating copy to clipboard operation
recurr copied to clipboard

Some precisions : hours/minutes and merge collections

Open clem983 opened this issue 6 years ago • 0 comments

Hi,

Thank you for this great lib :)

I'm trying to use it, but I have some questions ...

• I don't understand how to set multiple hours and minutes in a day. If I want 2 time slots of 1 hour, at 10:00 and 15:00, I'm going to do :

$rule = (new Rule) ->setStartDate("2018-11-01 10:00:00") ->setEndDate("2018-11-01 11:00:00") ->setFreq('DAILY') ->setByHour(array(10, 15)) ;

But if I want 2 time slots of 1 hour, at 10:15 and 15:45, how to do it ? If I add setByMinute(array(15, 45)), it's going to generate 10:15, 10:45, 15:15 and 15:45

• If I have multiple recurrence collections, is it possible to "merge" them ? For example, if I have a day disponibilities in a collection, and user absences in an other collection, can I remove the absence periods in the day disponibilities ?

• And, finally, how to include 'startDate' and 'endDate' in the collection ?

Thanks a lot :)

clem983 avatar Nov 23 '18 22:11 clem983