From c9e5034d3d116ca2c29903efdd56def52a9fe8d4 Mon Sep 17 00:00:00 2001 From: "Cameron E. Tidd" Date: Sun, 6 Jul 2025 17:05:41 +0000 Subject: [PATCH 04/16] Add ReportsBranch.pm --- .../devel/Koha/Schema/Result/ReportsBranch.pm | 85 +++++++++++++++++++ 1 file changed, 85 insertions(+) create mode 100644 misc/devel/Koha/Schema/Result/ReportsBranch.pm diff --git a/misc/devel/Koha/Schema/Result/ReportsBranch.pm b/misc/devel/Koha/Schema/Result/ReportsBranch.pm new file mode 100644 index 0000000000..970c25eabc --- /dev/null +++ b/misc/devel/Koha/Schema/Result/ReportsBranch.pm @@ -0,0 +1,85 @@ +use utf8; + +package Koha::Schema::Result::ReportsBranch; + +# Created by DBIx::Class::Schema::Loader +# DO NOT MODIFY THE FIRST PART OF THIS FILE + +=head1 NAME + +Koha::Schema::Result::ReportsBranch + +=cut + +use strict; +use warnings; + +use base 'DBIx::Class::Core'; + +=head1 TABLE: C + +=cut + +__PACKAGE__->table("reports_branches"); + +=head1 ACCESSORS + +=head2 report_id + + data_type: 'integer' + is_foreign_key: 1 + is_nullable: 0 + +=head2 branchcode + + data_type: 'varchar' + is_foreign_key: 1 + is_nullable: 0 + size: 10 + +=cut + +__PACKAGE__->add_columns( + "report_id", + { data_type => "integer", is_foreign_key => 1, is_nullable => 0 }, + "branchcode", + { data_type => "varchar", is_foreign_key => 1, is_nullable => 0, size => 10 }, +); + +=head1 RELATIONS + +=head2 branchcode + +Type: belongs_to + +Related object: L + +=cut + +__PACKAGE__->belongs_to( + "branchcode", + "Koha::Schema::Result::Branch", + { branchcode => "branchcode" }, + { is_deferrable => 1, on_delete => "CASCADE", on_update => "RESTRICT" }, +); + +=head2 report + +Type: belongs_to + +Related object: L + +=cut + +__PACKAGE__->belongs_to( + "report", + "Koha::Schema::Result::SavedSql", + { id => "report_id" }, + { is_deferrable => 1, on_delete => "CASCADE", on_update => "RESTRICT" }, +); + +# Created by DBIx::Class::Schema::Loader v0.07051 @ 2025-07-06 17:02:11 +# DO NOT MODIFY THIS OR ANYTHING ABOVE! md5sum:SJqUxMgLJHAjbX3GJlpB+A + +# You can replace this text with custom code or comments, and it will be preserved on regeneration +1; -- 2.39.5