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

(-)a/installer/data/mysql/updatedatabase.pl (-6 / +7 lines)
Lines 20886-20893 if( CheckVersion( $DBversion ) ) { Link Here
20886
        $dbh->do('ALTER TABLE account_credit_types ADD COLUMN archived tinyint(1) NOT NULL DEFAULT 0 AFTER is_system');
20886
        $dbh->do('ALTER TABLE account_credit_types ADD COLUMN archived tinyint(1) NOT NULL DEFAULT 0 AFTER is_system');
20887
    }
20887
    }
20888
20888
20889
    SetVersion( $DBversion );
20889
    NewVersion( $DBversion, 17702, 'Add column account_credit_types.archived');
20890
    print "Upgrade to $DBversion done (Bug 17702 - Add column account_credit_types.archived)\n";
20891
}
20890
}
20892
20891
20893
$DBversion = '19.12.00.030';
20892
$DBversion = '19.12.00.030';
Lines 20908-20924 if( CheckVersion( $DBversion ) ) { Link Here
20908
    my ($opacheader) = $dbh->selectrow_array( q|
20907
    my ($opacheader) = $dbh->selectrow_array( q|
20909
        SELECT value FROM systempreferences WHERE variable='opacheader';
20908
        SELECT value FROM systempreferences WHERE variable='opacheader';
20910
    |);
20909
    |);
20910
20911
    my @detail;
20911
    if( $opacheader ){
20912
    if( $opacheader ){
20912
        foreach my $lang ( @langs ) {
20913
        foreach my $lang ( @langs ) {
20913
            print "Inserting opacheader contents into $lang news item...\n";
20914
            # If there is a value in the opacheader preference, insert it into opac_news
20914
            # If there is a value in the opacheader preference, insert it into opac_news
20915
            $dbh->do("INSERT INTO opac_news (branchcode, lang, title, content ) VALUES (NULL, ?, '', ?)", undef, "opacheader_$langs[0]", $opacheader);
20915
            $dbh->do("INSERT INTO opac_news (branchcode, lang, title, content ) VALUES (NULL, ?, '', ?)", undef, "opacheader_$langs[0]", $opacheader);
20916
            push @detail, "Inserted opacheader contents into $lang news item...\n";
20916
        }
20917
        }
20917
    }
20918
    }
20918
    # Remove the opacheader system preference
20919
    # Remove the opacheader system preference
20919
    $dbh->do("DELETE FROM systempreferences WHERE variable='opacheader'");
20920
    $dbh->do("DELETE FROM systempreferences WHERE variable='opacheader'");
20920
    SetVersion ($DBversion);
20921
20921
    print "Upgrade to $DBversion done (Bug 22880: Move contents of opacheader preference to Koha news system)\n";
20922
    unshift @detail, 'Move contents of opacheader preference to Koha news system';
20923
    NewVersion( $DBversion, 22880, \@detail);
20922
}
20924
}
20923
20925
20924
# SEE bug 13068
20926
# SEE bug 13068
20925
- 

Return to bug 24131