+ } elsif ( $newoperation eq 'holidayrange' ) {
+ if (@holiday_list){
+ foreach my $date (@holiday_list){
+ unless ( $calendar->isHoliday( $date->{local_c}->{day}, $date->{local_c}->{month}, $date->{local_c}->{year} ) ) {
+ $calendar->insert_single_holiday(
+ day => $date->{local_c}->{day},
+ month => $date->{local_c}->{month},
+ year => $date->{local_c}->{year},
+ title => $title,
+ description => $description
+ );
+ }
+ }
+ }
+ } elsif ( $newoperation eq 'holidayrangerepeat' ) {
+ if (@holiday_list){
+ foreach my $date (@holiday_list){
+ unless ( $calendar->isHoliday( $date->{local_c}->{day}, $date->{local_c}->{month}, $date->{local_c}->{year} ) ) {
+ $calendar->insert_day_month_holiday(
+ day => $date->{local_c}->{day},
+ month => $date->{local_c}->{month},
+ title => $title,
+ description => $description
+ );
+ }
+ }
+ }
+ }
+ # we updated the single_holidays table, so wipe its cache
+ my $cache = Koha::Caches->get_instance();
+ $cache->clear_from_cache( 'single_holidays') ;