@@ -, +, @@ --- Koha/Account.pm | 4 ++-- installer/data/mysql/account_debit_types.sql | 2 +- installer/data/mysql/atomicupdate/bug_23049_debit.perl | 9 ++++++++- .../data/mysql/en/mandatory/account_debit_types.sql | 2 +- koha-tmpl/intranet-tmpl/prog/en/includes/accounts.inc | 2 +- .../opac-tmpl/bootstrap/en/includes/account-table.inc | 2 +- 6 files changed, 14 insertions(+), 7 deletions(-) --- a/Koha/Account.pm +++ a/Koha/Account.pm @@ -449,7 +449,7 @@ $debit_type can be any of: - RESERVE_EXPIRED - LOST - sundry - - new_card + - NEW_CARD - OVERDUE - PROCESSING - RENT @@ -742,7 +742,7 @@ our $account_type_debit = { 'ACCOUNT_RENEW' => 'ACCOUNT_RENEW', 'RESERVE_EXPIRED' => 'RESERVE_EXPIRED', 'LOST_ITEM' => 'LOST', - 'new_card' => 'N', + 'NEW_CARD' => 'NEW_CARD', 'OVERDUE' => 'OVERDUE', 'PROCESSING' => 'PROCESSING', 'RENT' => 'RENT', --- a/installer/data/mysql/account_debit_types.sql +++ a/installer/data/mysql/account_debit_types.sql @@ -3,7 +3,7 @@ INSERT INTO account_debit_types ( code, description, can_be_added_manually, defa ('ACCOUNT_RENEW', 'Account renewal fee', 0, NULL, 1), ('LOST', 'Lost item', 1, NULL, 1), ('M', 'Manual fee', 1, NULL, 0), -('N', 'New card fee', 1, NULL, 1), +('NEW_CARD', 'New card fee', 1, NULL, 1), ('OVERDUE', 'Overdue fine', 0, NULL, 1), ('PROCESSING', 'Lost item processing fee', 0, NULL, 1), ('RENT', 'Rental fee', 0, NULL, 1), --- a/installer/data/mysql/atomicupdate/bug_23049_debit.perl +++ a/installer/data/mysql/atomicupdate/bug_23049_debit.perl @@ -43,7 +43,7 @@ if ( CheckVersion($DBversion) ) { ('RESERVE_EXPIRED', 'Hold waiting too long', 0, NULL, 1), ('LOST', 'Lost item', 1, NULL, 1), ('M', 'Manual fee', 1, NULL, 0), - ('N', 'New card fee', 1, NULL, 1), + ('NEW_CARD', 'New card fee', 1, NULL, 1), ('OVERDUE', 'Overdue fine', 0, NULL, 1), ('PROCESSING', 'Lost item processing fee', 0, NULL, 1), ('RENT', 'Rental fee', 0, NULL, 1), @@ -75,6 +75,13 @@ if ( CheckVersion($DBversion) ) { } ); + # Update accountype 'N' to 'NEW_CARD' + $dbh->do( + qq{ + UPDATE accountlines SET accounttype = 'NEW_CARD' WHERE accounttype = 'N' + } + ); + # Moving MANUAL_INV to account_debit_types $dbh->do( qq{ --- a/installer/data/mysql/en/mandatory/account_debit_types.sql +++ a/installer/data/mysql/en/mandatory/account_debit_types.sql @@ -3,7 +3,7 @@ INSERT INTO account_debit_types ( code, description, can_be_added_manually, defa ('ACCOUNT_RENEW', 'Account renewal fee', 0, NULL, 1), ('LOST', 'Lost item', 1, NULL, 1), ('M', 'Manual fee', 1, NULL, 0), -('N', 'New card fee', 1, NULL, 1), +('NEW_CARD', 'New card fee', 1, NULL, 1), ('OVERDUE', 'Overdue fine', 0, NULL, 1), ('PROCESSING', 'Lost item processing fee', 0, NULL, 1), ('RENT', 'Rental fee', 0, NULL, 1), --- a/koha-tmpl/intranet-tmpl/prog/en/includes/accounts.inc +++ a/koha-tmpl/intranet-tmpl/prog/en/includes/accounts.inc @@ -17,7 +17,7 @@ [%- CASE 'ACCOUNT_RENEW' -%]Account renewal fee [%- CASE 'LOST' -%]Lost item [%- CASE 'M' -%]Sundry - [%- CASE 'N' -%]New card + [%- CASE 'NEW_CARD' -%]New card [%- CASE 'OVERDUE' -%]Fine [%- CASE 'PROCESSING' -%]Lost item processing fee [%- CASE 'RENT' -%]Rental fee --- a/koha-tmpl/opac-tmpl/bootstrap/en/includes/account-table.inc +++ a/koha-tmpl/opac-tmpl/bootstrap/en/includes/account-table.inc @@ -188,7 +188,7 @@ [%- CASE 'ACCOUNT_RENEW' -%]Account renewal fee [%- CASE 'LOST' -%]Lost item [%- CASE 'M' -%]Sundry - [%- CASE 'N' -%]New card + [%- CASE 'NEW_CARD' -%]New card [%- CASE 'OVERDUE' -%]Fine [%- CASE 'PROCESSING' -%]Lost item processing fee [%- CASE 'RENT' -%]Rental fee --