2 package Koha
::Schema
::Result
::Subscription
;
4 # Created by DBIx::Class::Schema::Loader
5 # DO NOT MODIFY THE FIRST PART OF THIS FILE
9 Koha::Schema::Result::Subscription
16 use base
'DBIx::Class::Core';
18 =head1 TABLE: C<subscription>
22 __PACKAGE__
->table("subscription");
41 default_value: (empty string)
48 datetime_undef_if_invalid: 1
93 =head2 countissuesperunit
101 data_type: 'longtext'
107 default_value: (empty string)
144 =head2 firstacquidate
147 datetime_undef_if_invalid: 1
158 data_type: 'mediumtext'
161 =head2 skip_serialseq
187 data_type: 'mediumtext'
192 data_type: 'longtext'
197 data_type: 'mediumtext'
203 default_value: (empty string)
210 default_value: (empty string)
220 =head2 serialsadditems
226 =head2 staffdisplaycount
232 =head2 opacdisplaycount
247 datetime_undef_if_invalid: 1
259 datetime_undef_if_invalid: 1
268 =head2 previousitemtype
281 __PACKAGE__
->add_columns(
283 { data_type
=> "integer", default_value
=> 0, is_nullable
=> 0 },
285 { data_type
=> "integer", is_auto_increment
=> 1, is_nullable
=> 0 },
287 { data_type
=> "varchar", default_value
=> "", is_nullable
=> 1, size
=> 100 },
289 { data_type
=> "date", datetime_undef_if_invalid
=> 1, is_nullable
=> 1 },
291 { data_type
=> "integer", default_value
=> 0, is_nullable
=> 1 },
293 { data_type
=> "integer", default_value
=> 0, is_nullable
=> 1 },
295 { data_type
=> "integer", default_value
=> 0, is_nullable
=> 1 },
297 { data_type
=> "integer", default_value
=> 0, is_nullable
=> 1 },
299 { data_type
=> "integer", default_value
=> 0, is_nullable
=> 1 },
301 { data_type
=> "integer", default_value
=> 0, is_nullable
=> 1 },
303 { data_type
=> "integer", is_foreign_key
=> 1, is_nullable
=> 1 },
304 "countissuesperunit",
305 { data_type
=> "integer", default_value
=> 1, is_nullable
=> 0 },
307 { data_type
=> "longtext", is_nullable
=> 1 },
309 { data_type
=> "varchar", default_value
=> "", is_nullable
=> 0, size
=> 100 },
311 { data_type
=> "integer", is_nullable
=> 1 },
313 { data_type
=> "integer", default_value
=> 0, is_nullable
=> 1 },
315 { data_type
=> "integer", is_nullable
=> 1 },
317 { data_type
=> "integer", default_value
=> 0, is_nullable
=> 1 },
319 { data_type
=> "integer", is_nullable
=> 1 },
321 { data_type
=> "integer", default_value
=> 0, is_nullable
=> 1 },
323 { data_type
=> "date", datetime_undef_if_invalid
=> 1, is_nullable
=> 1 },
325 { data_type
=> "tinyint", default_value
=> 0, is_nullable
=> 0 },
327 { data_type
=> "mediumtext", is_nullable
=> 1 },
329 { data_type
=> "tinyint", default_value
=> 0, is_nullable
=> 0 },
331 { data_type
=> "varchar", is_nullable
=> 1, size
=> 20 },
333 { data_type
=> "integer", is_foreign_key
=> 1, is_nullable
=> 1 },
335 { data_type
=> "varchar", is_nullable
=> 1, size
=> 80 },
337 { data_type
=> "mediumtext", is_nullable
=> 1 },
339 { data_type
=> "longtext", is_nullable
=> 1 },
341 { data_type
=> "mediumtext", is_nullable
=> 1 },
343 { data_type
=> "varchar", default_value
=> "", is_nullable
=> 1, size
=> 80 },
345 { data_type
=> "varchar", default_value
=> "", is_nullable
=> 0, size
=> 10 },
347 { data_type
=> "varchar", is_nullable
=> 1, size
=> 10 },
349 { data_type
=> "tinyint", default_value
=> 0, is_nullable
=> 0 },
351 { data_type
=> "varchar", is_nullable
=> 1, size
=> 10 },
353 { data_type
=> "varchar", is_nullable
=> 1, size
=> 10 },
355 { data_type
=> "integer", default_value
=> 0, is_nullable
=> 0 },
357 { data_type
=> "date", datetime_undef_if_invalid
=> 1, is_nullable
=> 1 },
359 { data_type
=> "integer", default_value
=> 0, is_nullable
=> 0 },
361 { data_type
=> "date", datetime_undef_if_invalid
=> 1, is_nullable
=> 1 },
363 { data_type
=> "varchar", is_nullable
=> 1, size
=> 10 },
365 { data_type
=> "varchar", is_nullable
=> 1, size
=> 10 },
367 { data_type
=> "integer", is_nullable
=> 1 },
374 =item * L</subscriptionid>
380 __PACKAGE__
->set_primary_key("subscriptionid");
388 Related object: L<Koha::Schema::Result::Aqorder>
392 __PACKAGE__
->has_many(
394 "Koha::Schema::Result::Aqorder",
395 { "foreign.subscriptionid" => "self.subscriptionid" },
396 { cascade_copy
=> 0, cascade_delete
=> 0 },
403 Related object: L<Koha::Schema::Result::SubscriptionNumberpattern>
407 __PACKAGE__
->belongs_to(
409 "Koha::Schema::Result::SubscriptionNumberpattern",
410 { id
=> "numberpattern" },
414 on_delete
=> "SET NULL",
415 on_update
=> "CASCADE",
423 Related object: L<Koha::Schema::Result::SubscriptionFrequency>
427 __PACKAGE__
->belongs_to(
429 "Koha::Schema::Result::SubscriptionFrequency",
430 { id
=> "periodicity" },
434 on_delete
=> "SET NULL",
435 on_update
=> "CASCADE",
439 =head2 subscriptionroutinglists
443 Related object: L<Koha::Schema::Result::Subscriptionroutinglist>
447 __PACKAGE__
->has_many(
448 "subscriptionroutinglists",
449 "Koha::Schema::Result::Subscriptionroutinglist",
450 { "foreign.subscriptionid" => "self.subscriptionid" },
451 { cascade_copy
=> 0, cascade_delete
=> 0 },
455 # Created by DBIx::Class::Schema::Loader v0.07046 @ 2019-01-23 12:56:39
456 # DO NOT MODIFY THIS OR ANYTHING ABOVE! md5sum:dTb/JOO3KQ3NZGypFbRiEw
458 __PACKAGE__
->has_many(
459 "additional_field_values",
460 "Koha::Schema::Result::AdditionalFieldValue",
465 "$args->{foreign_alias}.record_id" => { -ident
=> "$args->{self_alias}.subscriptionid" },
467 "$args->{foreign_alias}.field_id" =>
468 { -in => \'(SELECT id FROM additional_fields WHERE tablename
= "subscription")' },
471 { cascade_copy => 0, cascade_delete => 0 },
474 # You can replace this text with custom content, and it will be preserved on regeneration