Bug 15774: (follow-up) Address QA issues
[koha.git] / Koha / Schema / Result / EdifactEan.pm
1 use utf8;
2 package Koha::Schema::Result::EdifactEan;
3
4 # Created by DBIx::Class::Schema::Loader
5 # DO NOT MODIFY THE FIRST PART OF THIS FILE
6
7 =head1 NAME
8
9 Koha::Schema::Result::EdifactEan
10
11 =cut
12
13 use strict;
14 use warnings;
15
16 use base 'DBIx::Class::Core';
17
18 =head1 TABLE: C<edifact_ean>
19
20 =cut
21
22 __PACKAGE__->table("edifact_ean");
23
24 =head1 ACCESSORS
25
26 =head2 ee_id
27
28   data_type: 'integer'
29   is_auto_increment: 1
30   is_nullable: 0
31
32 =head2 description
33
34   data_type: 'varchar'
35   is_nullable: 1
36   size: 128
37
38 =head2 branchcode
39
40   data_type: 'varchar'
41   is_foreign_key: 1
42   is_nullable: 1
43   size: 10
44
45 =head2 ean
46
47   data_type: 'varchar'
48   is_nullable: 0
49   size: 15
50
51 =head2 id_code_qualifier
52
53   data_type: 'varchar'
54   default_value: 14
55   is_nullable: 0
56   size: 3
57
58 =cut
59
60 __PACKAGE__->add_columns(
61   "ee_id",
62   { data_type => "integer", is_auto_increment => 1, is_nullable => 0 },
63   "description",
64   { data_type => "varchar", is_nullable => 1, size => 128 },
65   "branchcode",
66   { data_type => "varchar", is_foreign_key => 1, is_nullable => 1, size => 10 },
67   "ean",
68   { data_type => "varchar", is_nullable => 0, size => 15 },
69   "id_code_qualifier",
70   { data_type => "varchar", default_value => 14, is_nullable => 0, size => 3 },
71 );
72
73 =head1 PRIMARY KEY
74
75 =over 4
76
77 =item * L</ee_id>
78
79 =back
80
81 =cut
82
83 __PACKAGE__->set_primary_key("ee_id");
84
85 =head1 RELATIONS
86
87 =head2 branchcode
88
89 Type: belongs_to
90
91 Related object: L<Koha::Schema::Result::Branch>
92
93 =cut
94
95 __PACKAGE__->belongs_to(
96   "branchcode",
97   "Koha::Schema::Result::Branch",
98   { branchcode => "branchcode" },
99   {
100     is_deferrable => 1,
101     join_type     => "LEFT",
102     on_delete     => "RESTRICT",
103     on_update     => "RESTRICT",
104   },
105 );
106
107
108 # Created by DBIx::Class::Schema::Loader v0.07042 @ 2018-10-09 11:29:27
109 # DO NOT MODIFY THIS OR ANYTHING ABOVE! md5sum:9CSEvOmfmy52+QAYAgrybA
110
111
112 # You can replace this text with custom code or comments, and it will be preserved on regeneration
113 __PACKAGE__->belongs_to('branch',
114     "Koha::Schema::Result::Branch",
115     { 'branchcode' => 'branchcode' },
116     {
117         is_deferrable => 1,
118         join_type => 'LEFT',
119         on_delete => 'CASCADE',
120         on_update => 'CASCADE',
121     },
122 );
123
124 1;