Bug 30755: Remove auto_too_soon from error count
[koha.git] / Koha / Schema / Result / ImportBatchProfile.pm
1 use utf8;
2 package Koha::Schema::Result::ImportBatchProfile;
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::ImportBatchProfile
10
11 =cut
12
13 use strict;
14 use warnings;
15
16 use base 'DBIx::Class::Core';
17
18 =head1 TABLE: C<import_batch_profiles>
19
20 =cut
21
22 __PACKAGE__->table("import_batch_profiles");
23
24 =head1 ACCESSORS
25
26 =head2 id
27
28   data_type: 'integer'
29   is_auto_increment: 1
30   is_nullable: 0
31
32 unique identifier and primary key
33
34 =head2 name
35
36   data_type: 'varchar'
37   is_nullable: 0
38   size: 100
39
40 name of this profile
41
42 =head2 matcher_id
43
44   data_type: 'integer'
45   is_nullable: 1
46
47 the id of the match rule used (matchpoints.matcher_id)
48
49 =head2 template_id
50
51   data_type: 'integer'
52   is_nullable: 1
53
54 the id of the marc modification template
55
56 =head2 overlay_action
57
58   data_type: 'varchar'
59   is_nullable: 1
60   size: 50
61
62 how to handle duplicate records
63
64 =head2 nomatch_action
65
66   data_type: 'varchar'
67   is_nullable: 1
68   size: 50
69
70 how to handle records where no match is found
71
72 =head2 item_action
73
74   data_type: 'varchar'
75   is_nullable: 1
76   size: 50
77
78 what to do with item records
79
80 =head2 parse_items
81
82   data_type: 'tinyint'
83   is_nullable: 1
84
85 should items be parsed
86
87 =head2 record_type
88
89   data_type: 'varchar'
90   is_nullable: 1
91   size: 50
92
93 type of record in the batch
94
95 =head2 encoding
96
97   data_type: 'varchar'
98   is_nullable: 1
99   size: 50
100
101 file encoding
102
103 =head2 format
104
105   data_type: 'varchar'
106   is_nullable: 1
107   size: 50
108
109 marc format
110
111 =head2 comments
112
113   data_type: 'longtext'
114   is_nullable: 1
115
116 any comments added when the file was uploaded
117
118 =cut
119
120 __PACKAGE__->add_columns(
121   "id",
122   { data_type => "integer", is_auto_increment => 1, is_nullable => 0 },
123   "name",
124   { data_type => "varchar", is_nullable => 0, size => 100 },
125   "matcher_id",
126   { data_type => "integer", is_nullable => 1 },
127   "template_id",
128   { data_type => "integer", is_nullable => 1 },
129   "overlay_action",
130   { data_type => "varchar", is_nullable => 1, size => 50 },
131   "nomatch_action",
132   { data_type => "varchar", is_nullable => 1, size => 50 },
133   "item_action",
134   { data_type => "varchar", is_nullable => 1, size => 50 },
135   "parse_items",
136   { data_type => "tinyint", is_nullable => 1 },
137   "record_type",
138   { data_type => "varchar", is_nullable => 1, size => 50 },
139   "encoding",
140   { data_type => "varchar", is_nullable => 1, size => 50 },
141   "format",
142   { data_type => "varchar", is_nullable => 1, size => 50 },
143   "comments",
144   { data_type => "longtext", is_nullable => 1 },
145 );
146
147 =head1 PRIMARY KEY
148
149 =over 4
150
151 =item * L</id>
152
153 =back
154
155 =cut
156
157 __PACKAGE__->set_primary_key("id");
158
159 =head1 UNIQUE CONSTRAINTS
160
161 =head2 C<u_import_batch_profiles__name>
162
163 =over 4
164
165 =item * L</name>
166
167 =back
168
169 =cut
170
171 __PACKAGE__->add_unique_constraint("u_import_batch_profiles__name", ["name"]);
172
173 =head1 RELATIONS
174
175 =head2 import_batches
176
177 Type: has_many
178
179 Related object: L<Koha::Schema::Result::ImportBatch>
180
181 =cut
182
183 __PACKAGE__->has_many(
184   "import_batches",
185   "Koha::Schema::Result::ImportBatch",
186   { "foreign.profile_id" => "self.id" },
187   { cascade_copy => 0, cascade_delete => 0 },
188 );
189
190
191 # Created by DBIx::Class::Schema::Loader v0.07049 @ 2021-01-21 13:39:29
192 # DO NOT MODIFY THIS OR ANYTHING ABOVE! md5sum:RmvuwPN8RT+tBsxR+Q7unA
193
194
195 # You can replace this text with custom code or comments, and it will be preserved on regeneration
196
197 __PACKAGE__->add_columns(
198   '+parse_items' => { is_boolean => 1 },
199 );
200
201 =head2 koha_object_class
202
203   Koha Object class
204
205 =cut
206
207 sub koha_object_class {
208     'Koha::ImportBatchProfile';
209 }
210
211 =head2 koha_objects_class
212
213   Koha Objects class
214
215 =cut
216
217 sub koha_objects_class {
218     'Koha::ImportBatchProfiles';
219 }
220
221 1;