From 0257380c08c1a16992ed1319fa1777a8719bd93f Mon Sep 17 00:00:00 2001 From: Tomas Cohen Arazi Date: Wed, 24 Jan 2024 16:18:32 -0300 Subject: [PATCH] Bug 32607: DBIC schema [DO NOT PUSH] --- Koha/Schema/Result/BiblioMetadata.pm | 34 +++++++++++++++++++-- Koha/Schema/Result/DeletedbiblioMetadata.pm | 34 +++++++++++++++++++-- 2 files changed, 64 insertions(+), 4 deletions(-) diff --git a/Koha/Schema/Result/BiblioMetadata.pm b/Koha/Schema/Result/BiblioMetadata.pm index aa1a7b25ee2..607ff676670 100644 --- a/Koha/Schema/Result/BiblioMetadata.pm +++ b/Koha/Schema/Result/BiblioMetadata.pm @@ -59,6 +59,14 @@ __PACKAGE__->table("biblio_metadata"); default_value: current_timestamp is_nullable: 0 +=head2 record_source_id + + data_type: 'integer' + is_foreign_key: 1 + is_nullable: 1 + +The record source for the metadata + =cut __PACKAGE__->add_columns( @@ -79,6 +87,8 @@ __PACKAGE__->add_columns( default_value => \"current_timestamp", is_nullable => 0, }, + "record_source_id", + { data_type => "integer", is_foreign_key => 1, is_nullable => 1 }, ); =head1 PRIMARY KEY @@ -131,9 +141,29 @@ __PACKAGE__->belongs_to( { is_deferrable => 1, on_delete => "CASCADE", on_update => "CASCADE" }, ); +=head2 record_source + +Type: belongs_to + +Related object: L + +=cut + +__PACKAGE__->belongs_to( + "record_source", + "Koha::Schema::Result::RecordSource", + { record_source_id => "record_source_id" }, + { + is_deferrable => 1, + join_type => "LEFT", + on_delete => "CASCADE", + on_update => "CASCADE", + }, +); + -# Created by DBIx::Class::Schema::Loader v0.07046 @ 2019-01-30 11:34:16 -# DO NOT MODIFY THIS OR ANYTHING ABOVE! md5sum:FJk/YOw8Y/QRmmPPL3G5qQ +# Created by DBIx::Class::Schema::Loader v0.07049 @ 2024-01-24 17:16:20 +# DO NOT MODIFY THIS OR ANYTHING ABOVE! md5sum:L0Yv0wrahJGyOiiBRBjonQ sub koha_object_class { 'Koha::Biblio::Metadata'; diff --git a/Koha/Schema/Result/DeletedbiblioMetadata.pm b/Koha/Schema/Result/DeletedbiblioMetadata.pm index 17406b9ca48..930184ab2c3 100644 --- a/Koha/Schema/Result/DeletedbiblioMetadata.pm +++ b/Koha/Schema/Result/DeletedbiblioMetadata.pm @@ -59,6 +59,14 @@ __PACKAGE__->table("deletedbiblio_metadata"); default_value: current_timestamp is_nullable: 0 +=head2 record_source_id + + data_type: 'integer' + is_foreign_key: 1 + is_nullable: 1 + +The record source for the metadata + =cut __PACKAGE__->add_columns( @@ -79,6 +87,8 @@ __PACKAGE__->add_columns( default_value => \"current_timestamp", is_nullable => 0, }, + "record_source_id", + { data_type => "integer", is_foreign_key => 1, is_nullable => 1 }, ); =head1 PRIMARY KEY @@ -131,9 +141,29 @@ __PACKAGE__->belongs_to( { is_deferrable => 1, on_delete => "CASCADE", on_update => "CASCADE" }, ); +=head2 record_source + +Type: belongs_to + +Related object: L + +=cut + +__PACKAGE__->belongs_to( + "record_source", + "Koha::Schema::Result::RecordSource", + { record_source_id => "record_source_id" }, + { + is_deferrable => 1, + join_type => "LEFT", + on_delete => "CASCADE", + on_update => "CASCADE", + }, +); + -# Created by DBIx::Class::Schema::Loader v0.07046 @ 2019-01-30 11:34:16 -# DO NOT MODIFY THIS OR ANYTHING ABOVE! md5sum:JCOh+FSSTgPlC8lMJOdOOA +# Created by DBIx::Class::Schema::Loader v0.07049 @ 2024-01-24 18:05:50 +# DO NOT MODIFY THIS OR ANYTHING ABOVE! md5sum:jEM0aYYjTiiNiolqlshXJA # You can replace this text with custom code or comments, and it will be preserved on regeneration -- 2.43.0