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

(-)a/installer/data/mysql/atomicupdate/bug_18936.perl (-7 / +7 lines)
Lines 6-11 if( CheckVersion( $DBversion ) ) { Link Here
6
        fine
6
        fine
7
        finedays
7
        finedays
8
        maxsuspensiondays
8
        maxsuspensiondays
9
        suspension_chargeperiod
9
        firstremind
10
        firstremind
10
        chargeperiod
11
        chargeperiod
11
        chargeperiod_charge_at
12
        chargeperiod_charge_at
Lines 22-45 if( CheckVersion( $DBversion ) ) { Link Here
22
        no_auto_renewal_after_hard_limit
23
        no_auto_renewal_after_hard_limit
23
        reservesallowed
24
        reservesallowed
24
        holds_per_record
25
        holds_per_record
25
        overduefinescap
26
        holds_per_day
26
        cap_fine_to_replacement_price
27
        onshelfholds
27
        onshelfholds
28
        opacitemholds
28
        opacitemholds
29
        overduefinescap
30
        cap_fine_to_replacement_price
29
        article_requests
31
        article_requests
30
        maxissueqty
32
        note
31
        maxonsiteissueqty
32
    );
33
    );
33
34
34
    if ( column_exists( 'issuingrules', 'categorycode' ) ) {
35
    if ( column_exists( 'issuingrules', 'categorycode' ) ) {
35
        foreach my $column ( @columns ) {
36
        foreach my $column ( @columns ) {
36
            $dbh->do("
37
            $dbh->do("
37
                INSERT INTO circulation_rules ( categorycode, branchcode, itemtype, rule_name, rule_value )
38
                INSERT INTO circulation_rules ( categorycode, branchcode, itemtype, rule_name, rule_value )
38
                SELECT categorycode, branchcode, itemtype, \'$column\', COALESCE( $column, '' )
39
                SELECT IF(categorycode='*', NULL, categorycode), IF(branchcode='*', NULL, branchcode), IF(itemtype='*', NULL, itemtype), \'$column\', COALESCE( $column, '' )
39
                FROM issuingrules
40
                FROM issuingrules
40
            ");
41
            ");
41
        }
42
        }
42
        $dbh->do("DROP TABLE issuingrules");
43
        #$dbh->do("DROP TABLE issuingrules");
43
    }
44
    }
44
45
45
    SetVersion( $DBversion );
46
    SetVersion( $DBversion );
46
- 

Return to bug 18936