Bugzilla – Attachment 187801 Details for
Bug 40517
Allow grouping existing holds
Home
|
New
|
Browse
|
Search
|
[?]
|
Reports
|
Help
|
New Account
|
Log In
[x]
|
Forgot Password
Login:
[x]
[patch]
Bug 40517: dbic
Bug-40517-dbic.patch (text/plain), 3.05 KB, created by
Pedro Amorim
on 2025-10-13 08:43:57 UTC
(
hide
)
Description:
Bug 40517: dbic
Filename:
MIME Type:
Creator:
Pedro Amorim
Created:
2025-10-13 08:43:57 UTC
Size:
3.05 KB
patch
obsolete
>From e47e7727f0d603282ce02256f6a7d7398bb75efa Mon Sep 17 00:00:00 2001 >From: Pedro Amorim <pedro.amorim@openfifth.co.uk> >Date: Mon, 13 Oct 2025 08:38:00 +0000 >Subject: [PATCH] Bug 40517: dbic > >--- > Koha/Schema/Result/Borrower.pm | 19 ++++++++++++++++-- > Koha/Schema/Result/HoldGroup.pm | 34 +++++++++++++++++++++++++++++++-- > 2 files changed, 49 insertions(+), 4 deletions(-) > >diff --git a/Koha/Schema/Result/Borrower.pm b/Koha/Schema/Result/Borrower.pm >index 1e1fa11cd42..4ea0800ab83 100644 >--- a/Koha/Schema/Result/Borrower.pm >+++ b/Koha/Schema/Result/Borrower.pm >@@ -1391,6 +1391,21 @@ __PACKAGE__->has_many( > { cascade_copy => 0, cascade_delete => 0 }, > ); > >+=head2 hold_groups >+ >+Type: has_many >+ >+Related object: L<Koha::Schema::Result::HoldGroup> >+ >+=cut >+ >+__PACKAGE__->has_many( >+ "hold_groups", >+ "Koha::Schema::Result::HoldGroup", >+ { "foreign.borrowernumber" => "self.borrowernumber" }, >+ { cascade_copy => 0, cascade_delete => 0 }, >+); >+ > =head2 housebound_profile > > Type: might_have >@@ -2197,8 +2212,8 @@ Composing rels: L</user_permissions> -> permission > __PACKAGE__->many_to_many("permissions", "user_permissions", "permission"); > > >-# Created by DBIx::Class::Schema::Loader v0.07051 @ 2025-07-10 07:11:31 >-# DO NOT MODIFY THIS OR ANYTHING ABOVE! md5sum:XFOe2X4k2DUziaNS5pWd/Q >+# Created by DBIx::Class::Schema::Loader v0.07051 @ 2025-07-16 10:57:50 >+# DO NOT MODIFY THIS OR ANYTHING ABOVE! md5sum:1mCQb2VuHB10JWtlJXTBWw > > __PACKAGE__->belongs_to( > "library", >diff --git a/Koha/Schema/Result/HoldGroup.pm b/Koha/Schema/Result/HoldGroup.pm >index ee15da9c5d0..ac2c9ffdbbf 100644 >--- a/Koha/Schema/Result/HoldGroup.pm >+++ b/Koha/Schema/Result/HoldGroup.pm >@@ -30,6 +30,14 @@ __PACKAGE__->table("hold_groups"); > is_auto_increment: 1 > is_nullable: 0 > >+=head2 borrowernumber >+ >+ data_type: 'integer' >+ is_foreign_key: 1 >+ is_nullable: 1 >+ >+foreign key, linking this to the borrowers table >+ > =cut > > __PACKAGE__->add_columns( >@@ -40,6 +48,8 @@ __PACKAGE__->add_columns( > is_auto_increment => 1, > is_nullable => 0, > }, >+ "borrowernumber", >+ { data_type => "integer", is_foreign_key => 1, is_nullable => 1 }, > ); > > =head1 PRIMARY KEY >@@ -56,6 +66,26 @@ __PACKAGE__->set_primary_key("hold_group_id"); > > =head1 RELATIONS > >+=head2 borrowernumber >+ >+Type: belongs_to >+ >+Related object: L<Koha::Schema::Result::Borrower> >+ >+=cut >+ >+__PACKAGE__->belongs_to( >+ "borrowernumber", >+ "Koha::Schema::Result::Borrower", >+ { borrowernumber => "borrowernumber" }, >+ { >+ is_deferrable => 1, >+ join_type => "LEFT", >+ on_delete => "CASCADE", >+ on_update => "RESTRICT", >+ }, >+); >+ > =head2 old_reserves > > Type: has_many >@@ -87,8 +117,8 @@ __PACKAGE__->has_many( > ); > > >-# Created by DBIx::Class::Schema::Loader v0.07051 @ 2025-09-03 17:08:22 >-# DO NOT MODIFY THIS OR ANYTHING ABOVE! md5sum:m3/7K38O11278k5glHlXAA >+# Created by DBIx::Class::Schema::Loader v0.07051 @ 2025-07-16 10:57:50 >+# DO NOT MODIFY THIS OR ANYTHING ABOVE! md5sum:Y1eP6naEI2vi94gTHqtubw > > > # You can replace this text with custom code or comments, and it will be preserved on regeneration >-- >2.39.5
You cannot view the attachment while viewing its details because your browser does not support IFRAMEs.
View the attachment on a separate page
.
View Attachment As Diff
View Attachment As Raw
Actions:
View
|
Diff
|
Splinter Review
Attachments on
bug 40517
:
184640
|
184641
|
184642
|
184643
|
184644
|
184645
|
184646
|
184729
|
184732
|
184733
|
184734
|
184735
|
184736
|
184737
|
184738
|
184739
|
185217
|
186672
|
186673
|
186674
|
186675
|
186676
|
186677
|
186678
|
186679
|
186680
|
186745
|
186746
|
186747
|
186748
|
186749
|
186750
|
186751
|
186752
|
186753
|
187789
|
187790
|
187791
|
187792
|
187793
|
187794
|
187795
|
187796
|
187797
|
187801
|
187802
|
187803
|
187804
|
187805
|
187806
|
187807
|
187808
|
187809
|
187810
|
187811
|
187812
|
187965
|
187966
|
187967
|
187968
|
187969
|
187970
|
187971
|
187972
|
187973
|
187974
|
187975
|
187976
|
188293
|
188294
|
188343
|
188422