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

(-)a/installer/data/mysql/kohastructure.sql (-1 / +1 lines)
Lines 287-293 CREATE TABLE `borrower_attribute_types` ( -- definitions for custom patron field Link Here
287
  `staff_searchable` tinyint(1) NOT NULL default 0, -- defines if this field is searchable via the patron search in the staff client (1 for yes, 0 for no)
287
  `staff_searchable` tinyint(1) NOT NULL default 0, -- defines if this field is searchable via the patron search in the staff client (1 for yes, 0 for no)
288
  `authorised_value_category` varchar(10) default NULL, -- foreign key from authorised_values that links this custom field to an authorized value category
288
  `authorised_value_category` varchar(10) default NULL, -- foreign key from authorised_values that links this custom field to an authorized value category
289
  `display_checkout` tinyint(1) NOT NULL default 0,-- defines if this field displays in checkout screens
289
  `display_checkout` tinyint(1) NOT NULL default 0,-- defines if this field displays in checkout screens
290
  `category_code` VARCHAR(1) NULL DEFAULT NULL,-- defines a category for an attribute_type
290
  `category_code` VARCHAR(10) NULL DEFAULT NULL,-- defines a category for an attribute_type
291
  `class` VARCHAR(255) NOT NULL DEFAULT '',-- defines a class for an attribute_type
291
  `class` VARCHAR(255) NOT NULL DEFAULT '',-- defines a class for an attribute_type
292
  PRIMARY KEY  (`code`),
292
  PRIMARY KEY  (`code`),
293
  KEY `auth_val_cat_idx` (`authorised_value_category`)
293
  KEY `auth_val_cat_idx` (`authorised_value_category`)
(-)a/installer/data/mysql/updatedatabase.pl (-1 / +7 lines)
Lines 5684-5689 if ( C4::Context->preference("Version") < TransformToNum($DBversion) ) { Link Here
5684
    SetVersion($DBversion);
5684
    SetVersion($DBversion);
5685
}
5685
}
5686
5686
5687
$DBversion = "3.09.00.XXX";
5688
if ( C4::Context->preference("Version") < TransformToNum($DBversion) ) {
5689
    $dbh->do("ALTER TABLE borrower_attribute_types MODIFY category_code VARCHAR( 10 ) NULL DEFAULT NULL");
5690
    print "Upgrade to $DBversion done. (Bug 8002: Update patron attribute types table from varchar(1) to varchar(10) category_code)\n";
5691
    SetVersion($DBversion);
5692
}
5693
5687
=head1 FUNCTIONS
5694
=head1 FUNCTIONS
5688
5695
5689
=head2 TableExists($table)
5696
=head2 TableExists($table)
5690
- 

Return to bug 8002