2 package Koha::Schema::Result::LibraryGroup;
4 # Created by DBIx::Class::Schema::Loader
5 # DO NOT MODIFY THE FIRST PART OF THIS FILE
9 Koha::Schema::Result::LibraryGroup
16 use base 'DBIx::Class::Core';
18 =head1 TABLE: C<library_groups>
22 __PACKAGE__->table("library_groups");
59 datetime_undef_if_invalid: 1
65 datetime_undef_if_invalid: 1
70 __PACKAGE__->add_columns(
72 { data_type => "integer", is_auto_increment => 1, is_nullable => 0 },
74 { data_type => "integer", is_foreign_key => 1, is_nullable => 1 },
76 { data_type => "varchar", is_foreign_key => 1, is_nullable => 1, size => 10 },
78 { data_type => "varchar", is_nullable => 1, size => 100 },
80 { data_type => "text", is_nullable => 1 },
83 data_type => "datetime",
84 datetime_undef_if_invalid => 1,
89 data_type => "datetime",
90 datetime_undef_if_invalid => 1,
105 __PACKAGE__->set_primary_key("id");
113 Related object: L<Koha::Schema::Result::Branch>
117 __PACKAGE__->belongs_to(
119 "Koha::Schema::Result::Branch",
120 { branchcode => "branchcode" },
124 on_delete => "CASCADE",
125 on_update => "CASCADE",
129 =head2 library_groups
133 Related object: L<Koha::Schema::Result::LibraryGroup>
137 __PACKAGE__->has_many(
139 "Koha::Schema::Result::LibraryGroup",
140 { "foreign.parent_id" => "self.id" },
141 { cascade_copy => 0, cascade_delete => 0 },
148 Related object: L<Koha::Schema::Result::LibraryGroup>
152 __PACKAGE__->belongs_to(
154 "Koha::Schema::Result::LibraryGroup",
155 { id => "parent_id" },
159 on_delete => "CASCADE",
160 on_update => "CASCADE",
165 # Created by DBIx::Class::Schema::Loader v0.07042 @ 2017-12-05 14:04:50
166 # DO NOT MODIFY THIS OR ANYTHING ABOVE! md5sum:p4hmm+ciFgPOGlAMvNB6Yw
169 # You can replace this text with custom code or comments, and it will be preserved on regeneration