- Issue created by @virtualmitra
- πΊπΈUnited States virtualmitra
I answered my own question. Instead of using:
$insts = $rrule->getRuleInstances();
to get the list of all active instances from which the canceled dates have already been purge, I needed to use:
$insts = $rrule->makeRuleInstances();
to get a fresh list of all possible instances. Thus, the list of canceled dates can be created with:$rrule = SmartDateRule::load($date_field_value['rrule']); $instances = $rrule->makeRuleInstances(); $ovrds = $rrule->getRuleOverrides(); foreach($ovrds as $ind => $ovrd) { $instance = $instances[$ind]; $canceled_dates[] = $instance->getStart()->format('M j'); }