2 package Koha
::Schema
::Result
::Reserve
;
4 # Created by DBIx::Class::Schema::Loader
5 # DO NOT MODIFY THE FIRST PART OF THIS FILE
9 Koha::Schema::Result::Reserve
16 use base
'DBIx::Class::Core';
18 =head1 TABLE: C<reserves>
22 __PACKAGE__
->table("reserves");
42 datetime_undef_if_invalid: 1
59 =head2 notificationdate
62 datetime_undef_if_invalid: 1
68 datetime_undef_if_invalid: 1
71 =head2 cancellationdate
74 datetime_undef_if_invalid: 1
96 data_type: 'timestamp'
97 datetime_undef_if_invalid: 1
98 default_value: current_timestamp
110 datetime_undef_if_invalid: 1
113 =head2 expirationdate
116 datetime_undef_if_invalid: 1
119 =head2 lowestPriority
121 accessor: 'lowest_priority'
134 data_type: 'datetime'
135 datetime_undef_if_invalid: 1
145 =head2 item_level_hold
153 __PACKAGE__
->add_columns(
155 { data_type
=> "integer", is_auto_increment
=> 1, is_nullable
=> 0 },
158 data_type
=> "integer",
164 { data_type
=> "date", datetime_undef_if_invalid
=> 1, is_nullable
=> 1 },
167 data_type
=> "integer",
173 { data_type
=> "varchar", is_foreign_key
=> 1, is_nullable
=> 1, size
=> 10 },
175 { data_type
=> "date", datetime_undef_if_invalid
=> 1, is_nullable
=> 1 },
177 { data_type
=> "date", datetime_undef_if_invalid
=> 1, is_nullable
=> 1 },
179 { data_type
=> "date", datetime_undef_if_invalid
=> 1, is_nullable
=> 1 },
181 { data_type
=> "longtext", is_nullable
=> 1 },
183 { data_type
=> "smallint", default_value
=> 1, is_nullable
=> 0 },
185 { data_type
=> "varchar", is_nullable
=> 1, size
=> 1 },
188 data_type
=> "timestamp",
189 datetime_undef_if_invalid
=> 1,
190 default_value
=> \"current_timestamp
",
194 { data_type => "integer
", is_foreign_key => 1, is_nullable => 1 },
196 { data_type => "date
", datetime_undef_if_invalid => 1, is_nullable => 1 },
198 { data_type => "date
", datetime_undef_if_invalid => 1, is_nullable => 1 },
201 accessor => "lowest_priority
",
202 data_type => "tinyint
",
207 { data_type => "tinyint
", default_value => 0, is_nullable => 0 },
210 data_type => "datetime
",
211 datetime_undef_if_invalid => 1,
215 { data_type => "varchar
", is_foreign_key => 1, is_nullable => 1, size => 10 },
217 { data_type => "tinyint
", default_value => 0, is_nullable => 0 },
224 =item * L</reserve_id>
230 __PACKAGE__->set_primary_key("reserve_id
");
238 Related object: L<Koha::Schema::Result::Biblio>
242 __PACKAGE__->belongs_to(
244 "Koha
::Schema
::Result
::Biblio
",
245 { biblionumber => "biblionumber
" },
246 { is_deferrable => 1, on_delete => "CASCADE
", on_update => "CASCADE
" },
249 =head2 borrowernumber
253 Related object: L<Koha::Schema::Result::Borrower>
257 __PACKAGE__->belongs_to(
259 "Koha
::Schema
::Result
::Borrower
",
260 { borrowernumber => "borrowernumber
" },
261 { is_deferrable => 1, on_delete => "CASCADE
", on_update => "CASCADE
" },
268 Related object: L<Koha::Schema::Result::Branch>
272 __PACKAGE__->belongs_to(
274 "Koha
::Schema
::Result
::Branch
",
275 { branchcode => "branchcode
" },
279 on_delete => "CASCADE
",
280 on_update => "CASCADE
",
284 =head2 club_holds_to_patron_holds
288 Related object: L<Koha::Schema::Result::ClubHoldsToPatronHold>
292 __PACKAGE__->has_many(
293 "club_holds_to_patron_holds
",
294 "Koha
::Schema
::Result
::ClubHoldsToPatronHold
",
295 { "foreign
.hold_id
" => "self
.reserve_id
" },
296 { cascade_copy => 0, cascade_delete => 0 },
303 Related object: L<Koha::Schema::Result::Item>
307 __PACKAGE__->belongs_to(
309 "Koha
::Schema
::Result
::Item
",
310 { itemnumber => "itemnumber
" },
314 on_delete => "CASCADE
",
315 on_update => "CASCADE
",
323 Related object: L<Koha::Schema::Result::Itemtype>
327 __PACKAGE__->belongs_to(
329 "Koha
::Schema
::Result
::Itemtype
",
330 { itemtype => "itemtype
" },
334 on_delete => "CASCADE
",
335 on_update => "CASCADE
",
340 # Created by DBIx::Class::Schema::Loader v0.07046 @ 2020-03-18 12:43:15
341 # DO NOT MODIFY THIS OR ANYTHING ABOVE! md5sum:VH7h5kYo9WhlGobXb3N3Jg
343 __PACKAGE__->belongs_to(
345 "Koha
::Schema
::Result
::Item
",
346 { itemnumber => "itemnumber
" },
350 on_delete => "CASCADE
",
351 on_update => "CASCADE
",
355 __PACKAGE__->belongs_to(
357 "Koha
::Schema
::Result
::Biblio
",
358 { biblionumber => "biblionumber
" },
362 on_delete => "CASCADE
",
363 on_update => "CASCADE
",
367 __PACKAGE__->add_columns(
368 '+item_level_hold' => { is_boolean => 1 },
369 '+lowestPriority' => { is_boolean => 1 },
370 '+suspend' => { is_boolean => 1 }
373 sub koha_object_class {
376 sub koha_objects_class {