Bug 35353: DBIC specific

Signed-off-by: Matt Blenkinsop <matt.blenkinsop@ptfs-europe.com>
Signed-off-by: Nick Clemens <nick@bywatersolutions.com>
Signed-off-by: Katrin Fischer <katrin.fischer@bsz-bw.de>
(cherry picked from commit 6fb82fd6e3)
Signed-off-by: Fridolin Somers <fridolin.somers@biblibre.com>
This commit is contained in:
Jonathan Druart 2023-12-20 11:23:52 +01:00 committed by Fridolin Somers
parent 7e834c095a
commit 50742ec62d
2 changed files with 19 additions and 0 deletions

View file

@ -467,6 +467,18 @@ __PACKAGE__->belongs_to(
},
);
__PACKAGE__->belongs_to(
"pickup_library",
"Koha::Schema::Result::Branch",
{ branchcode => "branchcode" },
{
is_deferrable => 1,
join_type => "LEFT",
on_delete => "SET NULL",
on_update => "CASCADE",
},
);
__PACKAGE__->add_columns(
'+item_level_hold' => { is_boolean => 1 },
'+lowestPriority' => { is_boolean => 1 },

View file

@ -523,4 +523,11 @@ __PACKAGE__->has_many(
{ cascade_copy => 0, cascade_delete => 0 },
);
__PACKAGE__->belongs_to(
"pickup_library",
"Koha::Schema::Result::Branch",
{ "foreign.branchcode" => "self.branchcode" },
{ is_deferrable => 1, on_delete => "CASCADE", on_update => "CASCADE" },
);
1;