From f317af166fe008ad4edf16228c9c49c70f034eeb Mon Sep 17 00:00:00 2001 From: Nick Clemens Date: Thu, 15 Sep 2022 12:43:23 +0000 Subject: [PATCH] Bug 31569: DO NOT PUSH Schema Updates RM: Please copy object class lines :-) --- Koha/Schema/Result/ImportBiblio.pm | 22 ++++++++++++++++++++-- Koha/Schema/Result/ImportRecord.pm | 12 ++++++------ 2 files changed, 26 insertions(+), 8 deletions(-) diff --git a/Koha/Schema/Result/ImportBiblio.pm b/Koha/Schema/Result/ImportBiblio.pm index ca4e21246a..9e0eb97b33 100644 --- a/Koha/Schema/Result/ImportBiblio.pm +++ b/Koha/Schema/Result/ImportBiblio.pm @@ -95,6 +95,18 @@ __PACKAGE__->add_columns( { data_type => "tinyint", default_value => 0, is_nullable => 0 }, ); +=head1 PRIMARY KEY + +=over 4 + +=item * L + +=back + +=cut + +__PACKAGE__->set_primary_key("import_record_id"); + =head1 RELATIONS =head2 import_record @@ -113,9 +125,15 @@ __PACKAGE__->belongs_to( ); -# Created by DBIx::Class::Schema::Loader v0.07049 @ 2020-11-03 09:53:04 -# DO NOT MODIFY THIS OR ANYTHING ABOVE! md5sum:/nOWo4fGjdch+K0T+07cSw +# Created by DBIx::Class::Schema::Loader v0.07049 @ 2022-09-15 12:20:57 +# DO NOT MODIFY THIS OR ANYTHING ABOVE! md5sum:e7NT/c8Oq2tnYl7ASkD/Vg +sub koha_object_class { + 'Koha::Import::Record::Biblio'; +} +sub koha_objects_class { + 'Koha::Import::Record::Biblios'; +} # You can replace this text with custom content, and it will be preserved on regeneration 1; diff --git a/Koha/Schema/Result/ImportRecord.pm b/Koha/Schema/Result/ImportRecord.pm index b32c9fea6a..fab8f84d1e 100644 --- a/Koha/Schema/Result/ImportRecord.pm +++ b/Koha/Schema/Result/ImportRecord.pm @@ -216,16 +216,16 @@ __PACKAGE__->belongs_to( { is_deferrable => 1, on_delete => "CASCADE", on_update => "CASCADE" }, ); -=head2 import_biblios +=head2 import_biblio -Type: has_many +Type: might_have Related object: L =cut -__PACKAGE__->has_many( - "import_biblios", +__PACKAGE__->might_have( + "import_biblio", "Koha::Schema::Result::ImportBiblio", { "foreign.import_record_id" => "self.import_record_id" }, { cascade_copy => 0, cascade_delete => 0 }, @@ -262,8 +262,8 @@ __PACKAGE__->has_many( ); -# Created by DBIx::Class::Schema::Loader v0.07046 @ 2019-04-18 10:50:48 -# DO NOT MODIFY THIS OR ANYTHING ABOVE! md5sum:bqIAQzhgioWtBWU8zFdtjw +# Created by DBIx::Class::Schema::Loader v0.07049 @ 2022-09-15 12:20:57 +# DO NOT MODIFY THIS OR ANYTHING ABOVE! md5sum:PXoyWIwcg9aOQ0223ogwxw sub koha_object_class { 'Koha::Import::Record'; -- 2.30.2