Bug 25655: DBIC schema
[srvgit] / Koha / Schema / Result / PatronListPatron.pm
1 use utf8;
2 package Koha::Schema::Result::PatronListPatron;
3
4 # Created by DBIx::Class::Schema::Loader
5 # DO NOT MODIFY THE FIRST PART OF THIS FILE
6
7 =head1 NAME
8
9 Koha::Schema::Result::PatronListPatron
10
11 =cut
12
13 use strict;
14 use warnings;
15
16 use base 'DBIx::Class::Core';
17
18 =head1 TABLE: C<patron_list_patrons>
19
20 =cut
21
22 __PACKAGE__->table("patron_list_patrons");
23
24 =head1 ACCESSORS
25
26 =head2 patron_list_patron_id
27
28   data_type: 'integer'
29   is_auto_increment: 1
30   is_nullable: 0
31
32 unique identifier
33
34 =head2 patron_list_id
35
36   data_type: 'integer'
37   is_foreign_key: 1
38   is_nullable: 0
39
40 the list this entry is part of
41
42 =head2 borrowernumber
43
44   data_type: 'integer'
45   is_foreign_key: 1
46   is_nullable: 0
47
48 the borrower that is part of this list
49
50 =cut
51
52 __PACKAGE__->add_columns(
53   "patron_list_patron_id",
54   { data_type => "integer", is_auto_increment => 1, is_nullable => 0 },
55   "patron_list_id",
56   { data_type => "integer", is_foreign_key => 1, is_nullable => 0 },
57   "borrowernumber",
58   { data_type => "integer", is_foreign_key => 1, is_nullable => 0 },
59 );
60
61 =head1 PRIMARY KEY
62
63 =over 4
64
65 =item * L</patron_list_patron_id>
66
67 =back
68
69 =cut
70
71 __PACKAGE__->set_primary_key("patron_list_patron_id");
72
73 =head1 RELATIONS
74
75 =head2 borrowernumber
76
77 Type: belongs_to
78
79 Related object: L<Koha::Schema::Result::Borrower>
80
81 =cut
82
83 __PACKAGE__->belongs_to(
84   "borrowernumber",
85   "Koha::Schema::Result::Borrower",
86   { borrowernumber => "borrowernumber" },
87   { is_deferrable => 1, on_delete => "CASCADE", on_update => "CASCADE" },
88 );
89
90 =head2 patron_list
91
92 Type: belongs_to
93
94 Related object: L<Koha::Schema::Result::PatronList>
95
96 =cut
97
98 __PACKAGE__->belongs_to(
99   "patron_list",
100   "Koha::Schema::Result::PatronList",
101   { patron_list_id => "patron_list_id" },
102   { is_deferrable => 1, on_delete => "CASCADE", on_update => "CASCADE" },
103 );
104
105
106 # Created by DBIx::Class::Schema::Loader v0.07049 @ 2021-01-21 13:39:29
107 # DO NOT MODIFY THIS OR ANYTHING ABOVE! md5sum:WEOKHfprX7+detNjQ3pV/g
108
109
110 # You can replace this text with custom content, and it will be preserved on regeneration
111 1;