diff --git a/installer/data/mysql/atomicupdate/bug_42112.pl b/installer/data/mysql/atomicupdate/bug_42112.pl new file mode 100755 index 0000000000..584feb2930 --- /dev/null +++ b/installer/data/mysql/atomicupdate/bug_42112.pl @@ -0,0 +1,27 @@ +use Modern::Perl; +use Koha::Installer::Output qw(say_warning say_success say_info); + +return { + bug_number => "42112", + description => "Add UpdateExpiryDateOnCategoryChange and UpdateMessagingPrefsOnCategoryChange", + up => sub { + my ($args) = @_; + my ( $dbh, $out ) = @$args{qw(dbh out)}; + + $dbh->do( + q{ + INSERT IGNORE INTO systempreferences (`variable`,`value`) + VALUES ('UpdateExpiryDateOnCategoryChange', 'softyes') + } + ); + $dbh->do( + q{ + INSERT IGNORE INTO systempreferences (`variable`,`value`) + VALUES ('UpdateMessagingPrefsOnCategoryChange', 'softyes') + } + ); + + say_success( $out, "System preference UpdateExpiryDateOnCategoryChange added." ); + say_success( $out, "System preference UpdateMessagingPrefsOnCategoryChange added." ); + }, +}; diff --git a/installer/data/mysql/mandatory/sysprefs.sql b/installer/data/mysql/mandatory/sysprefs.sql index 671dd1898b..a825996c88 100644 --- a/installer/data/mysql/mandatory/sysprefs.sql +++ b/installer/data/mysql/mandatory/sysprefs.sql @@ -868,11 +868,13 @@ INSERT INTO systempreferences ( `variable`, `value` ) VALUES ('UniqueItemFields','barcode'), ('UnseenRenewals','0'), ('UnsubscribeReflectionDelay',''), +('UpdateExpiryDateOnCategoryChange', 'softyes'), ('UpdateItemLocationOnCheckin', ''), ('UpdateItemLocationOnCheckout', ''), ('UpdateItemLostStatusWhenPaid', '0'), ('UpdateItemLostStatusWhenWriteoff', '0'), ('UpdateItemWhenLostFromHoldList',''), +('UpdateMessagingPrefsOnCategoryChange','softyes'), ('UpdateNotForLoanStatusOnCheckin', ''), ('UpdateNotForLoanStatusOnCheckout', ''), ('UpdateTotalIssuesOnCirc','0'), diff --git a/koha-tmpl/intranet-tmpl/prog/en/modules/admin/preferences/patrons.pref b/koha-tmpl/intranet-tmpl/prog/en/modules/admin/preferences/patrons.pref index e7fdda20a0..43a705700f 100644 --- a/koha-tmpl/intranet-tmpl/prog/en/modules/admin/preferences/patrons.pref +++ b/koha-tmpl/intranet-tmpl/prog/en/modules/admin/preferences/patrons.pref @@ -99,6 +99,22 @@ Patrons: 1: Do 0: "Don't" - charge a fee when a patron changes to a category with an enrollment fee. + - + - pref: UpdateExpiryDateOnCategoryChange + choices: + yes: "Always update without asking" + softyes: "Ask before updating, default to yes" + softno: "Ask before updating, default to no" + no: "Never update" + - the date expiry when changing an existing patron to a new category. + - + - pref: UpdateMessagingPrefsOnCategoryChange + choices: + yes: "Always update without asking" + softyes: "Ask before updating, default to yes" + softno: "Ask before updating, default to no" + no: "Never update" + - messaging preferences when changing an existing patron to a new category. - - Select which patron activities should be tracked to signify patron activity. Each time that one of these activities occurs, borrowers.lastseen will update with the current date and time. - pref: TrackLastPatronActivityTriggers diff --git a/koha-tmpl/intranet-tmpl/prog/en/modules/members/memberentrygen.tt b/koha-tmpl/intranet-tmpl/prog/en/modules/members/memberentrygen.tt index e6c055a81d..d103c29a4e 100644 --- a/koha-tmpl/intranet-tmpl/prog/en/modules/members/memberentrygen.tt +++ b/koha-tmpl/intranet-tmpl/prog/en/modules/members/memberentrygen.tt @@ -1598,7 +1598,6 @@ -