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

(-)a/installer/data/mysql/atomicupdate/bug_37054_add_branchcolor.pl (+23 lines)
Line 0 Link Here
1
use Modern::Perl;
2
use Koha::Installer::Output qw(say_warning say_failure say_success say_info);
3
4
return {
5
    bug_number  => "37054",
6
    description => "Add branches.branchcolor",
7
    up          => sub {
8
        my ($args) = @_;
9
        my ( $dbh, $out ) = @$args{qw(dbh out)};
10
11
        if ( !column_exists( 'branches', 'branchcolor' ) ) {
12
            $dbh->do(
13
                q{
14
                ALTER TABLE branches
15
                ADD COLUMN `branchcolor` varchar(16) DEFAULT 0 COMMENT 'defines the branch color'
16
                AFTER `opacusercss`
17
            }
18
            );
19
        }
20
        say $out "Added column 'branch.branchcolor'";
21
22
    },
23
};
(-)a/installer/data/mysql/kohastructure.sql (-1 / +1 lines)
Lines 1666-1671 CREATE TABLE `branches` ( Link Here
1666
  `public` tinyint(1) NOT NULL DEFAULT 1 COMMENT 'whether this library should show in the opac',
1666
  `public` tinyint(1) NOT NULL DEFAULT 1 COMMENT 'whether this library should show in the opac',
1667
  `opacuserjs` longtext DEFAULT NULL COMMENT 'branch specific javascript for the OPAC',
1667
  `opacuserjs` longtext DEFAULT NULL COMMENT 'branch specific javascript for the OPAC',
1668
  `opacusercss` longtext DEFAULT NULL COMMENT 'branch specific css for the OPAC',
1668
  `opacusercss` longtext DEFAULT NULL COMMENT 'branch specific css for the OPAC',
1669
  `branchcolor` varchar(16) DEFAULT NULL COMMENT 'branch specific color',
1669
  PRIMARY KEY (`branchcode`)
1670
  PRIMARY KEY (`branchcode`)
1670
) ENGINE=InnoDB DEFAULT CHARSET=utf8mb4 COLLATE=utf8mb4_unicode_ci;
1671
) ENGINE=InnoDB DEFAULT CHARSET=utf8mb4 COLLATE=utf8mb4_unicode_ci;
1671
/*!40101 SET character_set_client = @saved_cs_client */;
1672
/*!40101 SET character_set_client = @saved_cs_client */;
1672
- 

Return to bug 37054