From 9f71c6b53f6977a331812851572a4abdf0a794b5 Mon Sep 17 00:00:00 2001 From: Matt Blenkinsop Date: Wed, 21 Jan 2026 09:36:41 +0000 Subject: [PATCH] Bug 26355: DBIC files --- Koha/Schema/Result/BorrowerAttributeType.pm | 15 +++++- Koha/Schema/Result/Category.pm | 52 ++++++++++++++++++++- 2 files changed, 63 insertions(+), 4 deletions(-) diff --git a/Koha/Schema/Result/BorrowerAttributeType.pm b/Koha/Schema/Result/BorrowerAttributeType.pm index 36bf42d4c91..fd088e9389d 100644 --- a/Koha/Schema/Result/BorrowerAttributeType.pm +++ b/Koha/Schema/Result/BorrowerAttributeType.pm @@ -153,6 +153,14 @@ defines if the attribute is mandatory or not in the staff interface defines if the attribute is mandatory or not in the OPAC +=head2 self_renewal_verification_check + + data_type: 'tinyint' + default_value: 0 + is_nullable: 0 + +use this attribute as a verification step for patron self-renewal + =cut __PACKAGE__->add_columns( @@ -188,6 +196,8 @@ __PACKAGE__->add_columns( { data_type => "tinyint", default_value => 0, is_nullable => 0 }, "opac_mandatory", { data_type => "tinyint", default_value => 0, is_nullable => 0 }, + "self_renewal_verification_check", + { data_type => "tinyint", default_value => 0, is_nullable => 0 }, ); =head1 PRIMARY KEY @@ -255,8 +265,8 @@ __PACKAGE__->belongs_to( ); -# Created by DBIx::Class::Schema::Loader v0.07051 @ 2025-08-20 19:38:04 -# DO NOT MODIFY THIS OR ANYTHING ABOVE! md5sum:H/UZDZR19JQd/N/Tzb1+2A +# Created by DBIx::Class::Schema::Loader v0.07051 @ 2025-12-23 11:29:27 +# DO NOT MODIFY THIS OR ANYTHING ABOVE! md5sum:npxCmMqePzDHyZNNL+2IKg __PACKAGE__->add_columns( '+display_checkout' => { is_boolean => 1 }, @@ -270,6 +280,7 @@ __PACKAGE__->add_columns( '+searched_by_default' => { is_boolean => 1 }, '+staff_searchable' => { is_boolean => 1 }, '+unique_id' => { is_boolean => 1 }, + '+self_renewal_verification_check' => { is_boolean => 1 }, ); =head2 koha_object_class diff --git a/Koha/Schema/Result/Category.pm b/Koha/Schema/Result/Category.pm index 9cb9622295a..7bfef2c51d6 100644 --- a/Koha/Schema/Result/Category.pm +++ b/Koha/Schema/Result/Category.pm @@ -230,6 +230,43 @@ define maximum amount that the guarantors with guarantees of a patron in this ca enforce the patron expiry notice for this category +=head2 self_renewal_enabled + + data_type: 'tinyint' + default_value: 0 + is_nullable: 0 + +allow self renewal for this category + +=head2 self_renewal_availability_start + + data_type: 'smallint' + is_nullable: 1 + +how long before the patron expiry date self-renewal should be made available (overrides system default of NotifyBorrowerDeparture) + +=head2 self_renewal_fines_block + + data_type: 'integer' + is_nullable: 1 + +the amount owed in fines before self renewal is blocked (overrides system default of noissuescharge) + +=head2 self_renewal_if_expired + + data_type: 'smallint' + default_value: 0 + is_nullable: 1 + +how long after expiry a patron can self renew their account + +=head2 self_renewal_failure_message + + data_type: 'mediumtext' + is_nullable: 1 + +the message to display if self renewal is not successful + =cut __PACKAGE__->add_columns( @@ -303,6 +340,16 @@ __PACKAGE__->add_columns( { data_type => "integer", is_nullable => 1 }, "enforce_expiry_notice", { data_type => "tinyint", default_value => 0, is_nullable => 0 }, + "self_renewal_enabled", + { data_type => "tinyint", default_value => 0, is_nullable => 0 }, + "self_renewal_availability_start", + { data_type => "smallint", is_nullable => 1 }, + "self_renewal_fines_block", + { data_type => "integer", is_nullable => 1 }, + "self_renewal_if_expired", + { data_type => "smallint", default_value => 0, is_nullable => 1 }, + "self_renewal_failure_message", + { data_type => "mediumtext", is_nullable => 1 }, ); =head1 PRIMARY KEY @@ -410,8 +457,8 @@ __PACKAGE__->has_many( ); -# Created by DBIx::Class::Schema::Loader v0.07051 @ 2025-07-10 07:11:31 -# DO NOT MODIFY THIS OR ANYTHING ABOVE! md5sum:ADt+iDjteg9Jb81L2FMIvg +# Created by DBIx::Class::Schema::Loader v0.07051 @ 2025-12-23 11:29:27 +# DO NOT MODIFY THIS OR ANYTHING ABOVE! md5sum:f5UYRD69eLKwhq/YXdVxKg # You can replace this text with custom code or comments, and it will be preserved on regeneration @@ -447,6 +494,7 @@ __PACKAGE__->add_columns( '+require_strong_password' => { is_boolean => 1 }, '+reset_password' => { is_boolean => 1 }, '+enforce_expiry_notice' => { is_boolean => 1 }, + '+self_renewal_enabled' => { is_boolean => 1 }, ); 1; -- 2.39.5