From 91978a2b5440962d6a832a955d472bad13e84f03 Mon Sep 17 00:00:00 2001 From: Martin Renvoize Date: Fri, 27 Mar 2020 08:18:05 +0000 Subject: [PATCH] Bug 24412: Schema file DO NOT PUSH! --- Koha/Schema/Result/Desk.pm | 19 +++++++++++++++++-- Koha/Schema/Result/OldReserve.pm | 11 +++++++++-- Koha/Schema/Result/Reserve.pm | 32 ++++++++++++++++++++++++++++++-- 3 files changed, 56 insertions(+), 6 deletions(-) diff --git a/Koha/Schema/Result/Desk.pm b/Koha/Schema/Result/Desk.pm index a72be1b21f..036343b6f8 100644 --- a/Koha/Schema/Result/Desk.pm +++ b/Koha/Schema/Result/Desk.pm @@ -83,9 +83,24 @@ __PACKAGE__->belongs_to( { is_deferrable => 1, on_delete => "CASCADE", on_update => "CASCADE" }, ); +=head2 reserves -# Created by DBIx::Class::Schema::Loader v0.07042 @ 2019-10-02 13:43:57 -# DO NOT MODIFY THIS OR ANYTHING ABOVE! md5sum:IklOycKlChqv9Tftm8rjqA +Type: has_many + +Related object: L + +=cut + +__PACKAGE__->has_many( + "reserves", + "Koha::Schema::Result::Reserve", + { "foreign.desk_id" => "self.desk_id" }, + { cascade_copy => 0, cascade_delete => 0 }, +); + + +# Created by DBIx::Class::Schema::Loader v0.07046 @ 2020-03-27 08:17:36 +# DO NOT MODIFY THIS OR ANYTHING ABOVE! md5sum:BMxtD/20uxE62iGrtFa7cw # You can replace this text with custom code or comments, and it will be preserved on regeneration diff --git a/Koha/Schema/Result/OldReserve.pm b/Koha/Schema/Result/OldReserve.pm index 85e604d288..6276612a79 100644 --- a/Koha/Schema/Result/OldReserve.pm +++ b/Koha/Schema/Result/OldReserve.pm @@ -52,6 +52,11 @@ __PACKAGE__->table("old_reserves"); is_nullable: 1 size: 10 +=head2 desk_id + + data_type: 'integer' + is_nullable: 1 + =head2 notificationdate data_type: 'date' @@ -157,6 +162,8 @@ __PACKAGE__->add_columns( { data_type => "integer", is_foreign_key => 1, is_nullable => 1 }, "branchcode", { data_type => "varchar", is_nullable => 1, size => 10 }, + "desk_id", + { data_type => "integer", is_nullable => 1 }, "notificationdate", { data_type => "date", datetime_undef_if_invalid => 1, is_nullable => 1 }, "reminderdate", @@ -298,8 +305,8 @@ __PACKAGE__->belongs_to( ); -# Created by DBIx::Class::Schema::Loader v0.07046 @ 2020-03-18 12:43:15 -# DO NOT MODIFY THIS OR ANYTHING ABOVE! md5sum:4vMUC/1kSr3vgQ7n0Pmuug +# Created by DBIx::Class::Schema::Loader v0.07046 @ 2020-03-27 08:17:36 +# DO NOT MODIFY THIS OR ANYTHING ABOVE! md5sum:2VnRdZGunbXreGDSE1/k9A sub koha_object_class { 'Koha::Old::Hold'; diff --git a/Koha/Schema/Result/Reserve.pm b/Koha/Schema/Result/Reserve.pm index c5460e34da..abc25c30db 100644 --- a/Koha/Schema/Result/Reserve.pm +++ b/Koha/Schema/Result/Reserve.pm @@ -56,6 +56,12 @@ __PACKAGE__->table("reserves"); is_nullable: 1 size: 10 +=head2 desk_id + + data_type: 'integer' + is_foreign_key: 1 + is_nullable: 1 + =head2 notificationdate data_type: 'date' @@ -171,6 +177,8 @@ __PACKAGE__->add_columns( }, "branchcode", { data_type => "varchar", is_foreign_key => 1, is_nullable => 1, size => 10 }, + "desk_id", + { data_type => "integer", is_foreign_key => 1, is_nullable => 1 }, "notificationdate", { data_type => "date", datetime_undef_if_invalid => 1, is_nullable => 1 }, "reminderdate", @@ -296,6 +304,26 @@ __PACKAGE__->has_many( { cascade_copy => 0, cascade_delete => 0 }, ); +=head2 desk + +Type: belongs_to + +Related object: L + +=cut + +__PACKAGE__->belongs_to( + "desk", + "Koha::Schema::Result::Desk", + { desk_id => "desk_id" }, + { + is_deferrable => 1, + join_type => "LEFT", + on_delete => "CASCADE", + on_update => "CASCADE", + }, +); + =head2 itemnumber Type: belongs_to @@ -337,8 +365,8 @@ __PACKAGE__->belongs_to( ); -# Created by DBIx::Class::Schema::Loader v0.07046 @ 2020-03-18 12:43:15 -# DO NOT MODIFY THIS OR ANYTHING ABOVE! md5sum:VH7h5kYo9WhlGobXb3N3Jg +# Created by DBIx::Class::Schema::Loader v0.07046 @ 2020-03-27 08:17:36 +# DO NOT MODIFY THIS OR ANYTHING ABOVE! md5sum:wpxuofiQqASW+S/5+8daMQ __PACKAGE__->belongs_to( "item", -- 2.20.1