Bug 21395: Fix creation of PO file
[koha.git] / Koha / Schema / Result / PatronList.pm
blobf755f85585fe30301435eef88c5f251ddb1417a7
1 use utf8;
2 package Koha::Schema::Result::PatronList;
4 # Created by DBIx::Class::Schema::Loader
5 # DO NOT MODIFY THE FIRST PART OF THIS FILE
7 =head1 NAME
9 Koha::Schema::Result::PatronList
11 =cut
13 use strict;
14 use warnings;
16 use base 'DBIx::Class::Core';
18 =head1 TABLE: C<patron_lists>
20 =cut
22 __PACKAGE__->table("patron_lists");
24 =head1 ACCESSORS
26 =head2 patron_list_id
28 data_type: 'integer'
29 is_auto_increment: 1
30 is_nullable: 0
32 =head2 name
34 data_type: 'varchar'
35 is_nullable: 0
36 size: 255
38 =head2 owner
40 data_type: 'integer'
41 is_foreign_key: 1
42 is_nullable: 0
44 =head2 shared
46 data_type: 'tinyint'
47 default_value: 0
48 is_nullable: 1
50 =cut
52 __PACKAGE__->add_columns(
53 "patron_list_id",
54 { data_type => "integer", is_auto_increment => 1, is_nullable => 0 },
55 "name",
56 { data_type => "varchar", is_nullable => 0, size => 255 },
57 "owner",
58 { data_type => "integer", is_foreign_key => 1, is_nullable => 0 },
59 "shared",
60 { data_type => "tinyint", default_value => 0, is_nullable => 1 },
63 =head1 PRIMARY KEY
65 =over 4
67 =item * L</patron_list_id>
69 =back
71 =cut
73 __PACKAGE__->set_primary_key("patron_list_id");
75 =head1 RELATIONS
77 =head2 owner
79 Type: belongs_to
81 Related object: L<Koha::Schema::Result::Borrower>
83 =cut
85 __PACKAGE__->belongs_to(
86 "owner",
87 "Koha::Schema::Result::Borrower",
88 { borrowernumber => "owner" },
89 { is_deferrable => 1, on_delete => "CASCADE", on_update => "CASCADE" },
92 =head2 patron_list_patrons
94 Type: has_many
96 Related object: L<Koha::Schema::Result::PatronListPatron>
98 =cut
100 __PACKAGE__->has_many(
101 "patron_list_patrons",
102 "Koha::Schema::Result::PatronListPatron",
103 { "foreign.patron_list_id" => "self.patron_list_id" },
104 { cascade_copy => 0, cascade_delete => 0 },
108 # Created by DBIx::Class::Schema::Loader v0.07042 @ 2018-07-18 16:54:33
109 # DO NOT MODIFY THIS OR ANYTHING ABOVE! md5sum:ulv0BHLlcWdeLgD6qPxmUQ
112 # You can replace this text with custom content, and it will be preserved on regeneration