Bug 16829: DBIx update
[koha.git] / Koha / Schema / Result / VendorEdiAccount.pm
blob9a60720b946b826a014c6e7f5323c8369f4c2024
1 use utf8;
2 package Koha::Schema::Result::VendorEdiAccount;
4 # Created by DBIx::Class::Schema::Loader
5 # DO NOT MODIFY THE FIRST PART OF THIS FILE
7 =head1 NAME
9 Koha::Schema::Result::VendorEdiAccount
11 =cut
13 use strict;
14 use warnings;
16 use base 'DBIx::Class::Core';
18 =head1 TABLE: C<vendor_edi_accounts>
20 =cut
22 __PACKAGE__->table("vendor_edi_accounts");
24 =head1 ACCESSORS
26 =head2 id
28 data_type: 'integer'
29 is_auto_increment: 1
30 is_nullable: 0
32 =head2 description
34 data_type: 'text'
35 is_nullable: 0
37 =head2 host
39 data_type: 'varchar'
40 is_nullable: 1
41 size: 40
43 =head2 username
45 data_type: 'varchar'
46 is_nullable: 1
47 size: 40
49 =head2 password
51 data_type: 'varchar'
52 is_nullable: 1
53 size: 40
55 =head2 last_activity
57 data_type: 'date'
58 datetime_undef_if_invalid: 1
59 is_nullable: 1
61 =head2 vendor_id
63 data_type: 'integer'
64 is_foreign_key: 1
65 is_nullable: 1
67 =head2 download_directory
69 data_type: 'text'
70 is_nullable: 1
72 =head2 upload_directory
74 data_type: 'text'
75 is_nullable: 1
77 =head2 san
79 data_type: 'varchar'
80 is_nullable: 1
81 size: 20
83 =head2 id_code_qualifier
85 data_type: 'varchar'
86 default_value: 14
87 is_nullable: 1
88 size: 3
90 =head2 transport
92 data_type: 'varchar'
93 default_value: 'FTP'
94 is_nullable: 1
95 size: 6
97 =head2 quotes_enabled
99 data_type: 'tinyint'
100 default_value: 0
101 is_nullable: 0
103 =head2 invoices_enabled
105 data_type: 'tinyint'
106 default_value: 0
107 is_nullable: 0
109 =head2 orders_enabled
111 data_type: 'tinyint'
112 default_value: 0
113 is_nullable: 0
115 =head2 responses_enabled
117 data_type: 'tinyint'
118 default_value: 0
119 is_nullable: 0
121 =head2 auto_orders
123 data_type: 'tinyint'
124 default_value: 0
125 is_nullable: 0
127 =head2 shipment_budget
129 data_type: 'integer'
130 is_foreign_key: 1
131 is_nullable: 1
133 =head2 plugin
135 data_type: 'varchar'
136 default_value: (empty string)
137 is_nullable: 0
138 size: 256
140 =cut
142 __PACKAGE__->add_columns(
143 "id",
144 { data_type => "integer", is_auto_increment => 1, is_nullable => 0 },
145 "description",
146 { data_type => "text", is_nullable => 0 },
147 "host",
148 { data_type => "varchar", is_nullable => 1, size => 40 },
149 "username",
150 { data_type => "varchar", is_nullable => 1, size => 40 },
151 "password",
152 { data_type => "varchar", is_nullable => 1, size => 40 },
153 "last_activity",
154 { data_type => "date", datetime_undef_if_invalid => 1, is_nullable => 1 },
155 "vendor_id",
156 { data_type => "integer", is_foreign_key => 1, is_nullable => 1 },
157 "download_directory",
158 { data_type => "text", is_nullable => 1 },
159 "upload_directory",
160 { data_type => "text", is_nullable => 1 },
161 "san",
162 { data_type => "varchar", is_nullable => 1, size => 20 },
163 "id_code_qualifier",
164 { data_type => "varchar", default_value => 14, is_nullable => 1, size => 3 },
165 "transport",
166 { data_type => "varchar", default_value => "FTP", is_nullable => 1, size => 6 },
167 "quotes_enabled",
168 { data_type => "tinyint", default_value => 0, is_nullable => 0 },
169 "invoices_enabled",
170 { data_type => "tinyint", default_value => 0, is_nullable => 0 },
171 "orders_enabled",
172 { data_type => "tinyint", default_value => 0, is_nullable => 0 },
173 "responses_enabled",
174 { data_type => "tinyint", default_value => 0, is_nullable => 0 },
175 "auto_orders",
176 { data_type => "tinyint", default_value => 0, is_nullable => 0 },
177 "shipment_budget",
178 { data_type => "integer", is_foreign_key => 1, is_nullable => 1 },
179 "plugin",
180 { data_type => "varchar", default_value => "", is_nullable => 0, size => 256 },
183 =head1 PRIMARY KEY
185 =over 4
187 =item * L</id>
189 =back
191 =cut
193 __PACKAGE__->set_primary_key("id");
195 =head1 RELATIONS
197 =head2 edifact_messages
199 Type: has_many
201 Related object: L<Koha::Schema::Result::EdifactMessage>
203 =cut
205 __PACKAGE__->has_many(
206 "edifact_messages",
207 "Koha::Schema::Result::EdifactMessage",
208 { "foreign.edi_acct" => "self.id" },
209 { cascade_copy => 0, cascade_delete => 0 },
212 =head2 shipment_budget
214 Type: belongs_to
216 Related object: L<Koha::Schema::Result::Aqbudget>
218 =cut
220 __PACKAGE__->belongs_to(
221 "shipment_budget",
222 "Koha::Schema::Result::Aqbudget",
223 { budget_id => "shipment_budget" },
225 is_deferrable => 1,
226 join_type => "LEFT",
227 on_delete => "RESTRICT",
228 on_update => "RESTRICT",
232 =head2 vendor
234 Type: belongs_to
236 Related object: L<Koha::Schema::Result::Aqbookseller>
238 =cut
240 __PACKAGE__->belongs_to(
241 "vendor",
242 "Koha::Schema::Result::Aqbookseller",
243 { id => "vendor_id" },
245 is_deferrable => 1,
246 join_type => "LEFT",
247 on_delete => "RESTRICT",
248 on_update => "RESTRICT",
253 # Created by DBIx::Class::Schema::Loader v0.07042 @ 2016-04-01 21:58:03
254 # DO NOT MODIFY THIS OR ANYTHING ABOVE! md5sum:rsSTteR7nV22B/kxr33BBA
257 # You can replace this text with custom code or comments, and it will be preserved on regeneration