2 package Koha::Schema::Result::CurbsidePickupPolicy;
4 # Created by DBIx::Class::Schema::Loader
5 # DO NOT MODIFY THE FIRST PART OF THIS FILE
9 Koha::Schema::Result::CurbsidePickupPolicy
16 use base 'DBIx::Class::Core';
18 =head1 TABLE: C<curbside_pickup_policy>
22 __PACKAGE__->table("curbside_pickup_policy");
45 =head2 enable_waiting_holds_only
51 =head2 pickup_interval
57 =head2 patrons_per_interval
63 =head2 patron_scheduled_pickup
71 __PACKAGE__->add_columns(
73 { data_type => "integer", is_auto_increment => 1, is_nullable => 0 },
75 { data_type => "varchar", is_foreign_key => 1, is_nullable => 0, size => 10 },
77 { data_type => "tinyint", default_value => 0, is_nullable => 0 },
78 "enable_waiting_holds_only",
79 { data_type => "tinyint", default_value => 0, is_nullable => 0 },
81 { data_type => "integer", default_value => 0, is_nullable => 0 },
82 "patrons_per_interval",
83 { data_type => "integer", default_value => 0, is_nullable => 0 },
84 "patron_scheduled_pickup",
85 { data_type => "tinyint", default_value => 0, is_nullable => 0 },
98 __PACKAGE__->set_primary_key("id");
100 =head1 UNIQUE CONSTRAINTS
106 =item * L</branchcode>
112 __PACKAGE__->add_unique_constraint("branchcode", ["branchcode"]);
120 Related object: L<Koha::Schema::Result::Branch>
124 __PACKAGE__->belongs_to(
126 "Koha::Schema::Result::Branch",
127 { branchcode => "branchcode" },
128 { is_deferrable => 1, on_delete => "CASCADE", on_update => "CASCADE" },
131 =head2 curbside_pickup_opening_slots
135 Related object: L<Koha::Schema::Result::CurbsidePickupOpeningSlot>
139 __PACKAGE__->has_many(
140 "curbside_pickup_opening_slots",
141 "Koha::Schema::Result::CurbsidePickupOpeningSlot",
142 { "foreign.curbside_pickup_policy_id" => "self.id" },
143 { cascade_copy => 0, cascade_delete => 0 },
147 # Created by DBIx::Class::Schema::Loader v0.07049 @ 2022-06-27 11:58:44
148 # DO NOT MODIFY THIS OR ANYTHING ABOVE! md5sum:RyZGROB1+g3kb2bo6mwrUQ
150 __PACKAGE__->add_columns(
151 '+enabled' => { is_boolean => 1 },
152 '+enable_waiting_holds_only' => { is_boolean => 1 },
153 '+patron_scheduled_pickup' => { is_boolean => 1 },
156 sub koha_object_class {
157 'Koha::CurbsidePickupPolicy';
159 sub koha_objects_class {
160 'Koha::CurbsidePickupPolicies';