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

(-)a/installer/data/mysql/atomicupdate/bug_10796_pwd_change_by_category.perl (+14 lines)
Line 0 Link Here
1
$DBversion = 'XXX';
2
if( CheckVersion( $DBversion ) ) {
3
4
    if ( !column_exists( 'categories', 'change_password' ) ) {
5
        $dbh->do(q{
6
            ALTER TABLE categories
7
                ADD COLUMN change_password TINYINT(1) NULL DEFAULT NULL
8
                AFTER reset_password
9
        });
10
    }
11
12
    SetVersion( $DBversion );
13
    print "Upgrade to $DBversion done (Bug 10796 - Patron password change by category)\n";
14
}
(-)a/installer/data/mysql/kohastructure.sql (-2 / +2 lines)
Lines 318-324 CREATE TABLE `categories` ( -- this table shows information related to Koha patr Link Here
318
  `BlockExpiredPatronOpacActions` tinyint(1) NOT NULL default '-1', -- wheither or not a patron of this category can renew books or place holds once their card has expired. 0 means they can, 1 means they cannot, -1 means use syspref BlockExpiredPatronOpacActions
318
  `BlockExpiredPatronOpacActions` tinyint(1) NOT NULL default '-1', -- wheither or not a patron of this category can renew books or place holds once their card has expired. 0 means they can, 1 means they cannot, -1 means use syspref BlockExpiredPatronOpacActions
319
  `default_privacy` ENUM( 'default', 'never', 'forever' ) NOT NULL DEFAULT 'default', -- Default privacy setting for this patron category
319
  `default_privacy` ENUM( 'default', 'never', 'forever' ) NOT NULL DEFAULT 'default', -- Default privacy setting for this patron category
320
  `checkprevcheckout` varchar(7) NOT NULL default 'inherit', -- produce a warning for this patron category if this item has previously been checked out to this patron if 'yes', not if 'no', defer to syspref setting if 'inherit'.
320
  `checkprevcheckout` varchar(7) NOT NULL default 'inherit', -- produce a warning for this patron category if this item has previously been checked out to this patron if 'yes', not if 'no', defer to syspref setting if 'inherit'.
321
  `reset_password` TINYINT(1) NULL DEFAULT NULL, -- if patrons of this category can do the password reset flow
321
  `reset_password` TINYINT(1) NULL DEFAULT NULL, -- if patrons of this category can do the password reset flow,
322
  `change_password` TINYINT(1) NULL DEFAULT NULL, -- if patrons of this category can change their passwords in the OAPC
322
  PRIMARY KEY  (`categorycode`),
323
  PRIMARY KEY  (`categorycode`),
323
  UNIQUE KEY `categorycode` (`categorycode`)
324
  UNIQUE KEY `categorycode` (`categorycode`)
324
) ENGINE=InnoDB DEFAULT CHARSET=utf8mb4 COLLATE=utf8mb4_unicode_ci;
325
) ENGINE=InnoDB DEFAULT CHARSET=utf8mb4 COLLATE=utf8mb4_unicode_ci;
325
- 

Return to bug 10796