View | Details | Raw Unified | Return to bug 14522
Collapse All | Expand All

(-)a/Koha/Calendar.pm (-17 / +7 lines)
Lines 95-117 sub single_holidays { Link Here
95
    my $cache           = Koha::Cache->get_instance();
95
    my $cache           = Koha::Cache->get_instance();
96
    my $single_holidays = $cache->get_from_cache('single_holidays');
96
    my $single_holidays = $cache->get_from_cache('single_holidays');
97
97
98
=for
98
    # $single_holidays looks like:
99
$single_holidays looks like this..
99
    # {
100
100
    #   CPL =>  [
101
\ {
101
    #        [0] 20131122,
102
   CPL   [
102
    #         ...
103
        [0] 20131122,
103
    #    ],
104
        [1] 20131123,
104
    # }
105
        [2] 20131124
106
    ],
107
   MPL   [
108
        [0] 20131122,
109
        [1] 20131123,
110
        [2] 20131124
111
    ]
112
}
113
114
=cut
115
105
116
    unless ($single_holidays) {
106
    unless ($single_holidays) {
117
        my $dbh = C4::Context->dbh;
107
        my $dbh = C4::Context->dbh;
(-)a/t/db_dependent/Holidays.t (-1 / +3 lines)
Lines 97-102 is( $koha_calendar->is_holiday($monday), 0, 'Monday is not a closed day' ); Link Here
97
is( $koha_calendar->is_holiday($christmas), 1, 'Christmas is a closed day' );
97
is( $koha_calendar->is_holiday($christmas), 1, 'Christmas is a closed day' );
98
is( $koha_calendar->is_holiday($newyear),   1, 'New Years day is a closed day' );
98
is( $koha_calendar->is_holiday($newyear),   1, 'New Years day is a closed day' );
99
99
100
$dbh->do("DELETE FROM repeatable_holidays");
101
$dbh->do("DELETE FROM special_holidays");
102
100
my $custom_holiday = DateTime->new(
103
my $custom_holiday = DateTime->new(
101
    year  => 2013,
104
    year  => 2013,
102
    month => 11,
105
    month => 11,
103
- 

Return to bug 14522