Bug 26922: Regression tests
[koha.git] / Koha / Schema / Result / MatchpointComponent.pm
blobe3b2a65a09f45236914b3712798bb5234f531a74
1 use utf8;
2 package Koha::Schema::Result::MatchpointComponent;
4 # Created by DBIx::Class::Schema::Loader
5 # DO NOT MODIFY THE FIRST PART OF THIS FILE
7 =head1 NAME
9 Koha::Schema::Result::MatchpointComponent
11 =cut
13 use strict;
14 use warnings;
16 use base 'DBIx::Class::Core';
18 =head1 TABLE: C<matchpoint_components>
20 =cut
22 __PACKAGE__->table("matchpoint_components");
24 =head1 ACCESSORS
26 =head2 matchpoint_id
28 data_type: 'integer'
29 is_foreign_key: 1
30 is_nullable: 0
32 =head2 matchpoint_component_id
34 data_type: 'integer'
35 is_auto_increment: 1
36 is_nullable: 0
38 =head2 sequence
40 accessor: undef
41 data_type: 'integer'
42 default_value: 0
43 is_nullable: 0
45 =head2 tag
47 data_type: 'varchar'
48 default_value: (empty string)
49 is_nullable: 0
50 size: 3
52 =head2 subfields
54 data_type: 'varchar'
55 default_value: (empty string)
56 is_nullable: 0
57 size: 40
59 =head2 offset
61 data_type: 'integer'
62 default_value: 0
63 is_nullable: 0
65 =head2 length
67 data_type: 'integer'
68 default_value: 0
69 is_nullable: 0
71 =cut
73 __PACKAGE__->add_columns(
74 "matchpoint_id",
75 { data_type => "integer", is_foreign_key => 1, is_nullable => 0 },
76 "matchpoint_component_id",
77 { data_type => "integer", is_auto_increment => 1, is_nullable => 0 },
78 "sequence",
80 accessor => undef,
81 data_type => "integer",
82 default_value => 0,
83 is_nullable => 0,
85 "tag",
86 { data_type => "varchar", default_value => "", is_nullable => 0, size => 3 },
87 "subfields",
88 { data_type => "varchar", default_value => "", is_nullable => 0, size => 40 },
89 "offset",
90 { data_type => "integer", default_value => 0, is_nullable => 0 },
91 "length",
92 { data_type => "integer", default_value => 0, is_nullable => 0 },
95 =head1 PRIMARY KEY
97 =over 4
99 =item * L</matchpoint_component_id>
101 =back
103 =cut
105 __PACKAGE__->set_primary_key("matchpoint_component_id");
107 =head1 RELATIONS
109 =head2 matchpoint
111 Type: belongs_to
113 Related object: L<Koha::Schema::Result::Matchpoint>
115 =cut
117 __PACKAGE__->belongs_to(
118 "matchpoint",
119 "Koha::Schema::Result::Matchpoint",
120 { matchpoint_id => "matchpoint_id" },
121 { is_deferrable => 1, on_delete => "CASCADE", on_update => "CASCADE" },
124 =head2 matchpoint_component_norms
126 Type: has_many
128 Related object: L<Koha::Schema::Result::MatchpointComponentNorm>
130 =cut
132 __PACKAGE__->has_many(
133 "matchpoint_component_norms",
134 "Koha::Schema::Result::MatchpointComponentNorm",
136 "foreign.matchpoint_component_id" => "self.matchpoint_component_id",
138 { cascade_copy => 0, cascade_delete => 0 },
142 # Created by DBIx::Class::Schema::Loader v0.07025 @ 2013-10-14 20:56:21
143 # DO NOT MODIFY THIS OR ANYTHING ABOVE! md5sum:R9niKe/wGJXD+ZVkIP5Wpg
146 # You can replace this text with custom content, and it will be preserved on regeneration