Line 0
Link Here
|
0 |
- |
1 |
use utf8; |
|
|
2 |
package Koha::Schema::Result::PatronConsent; |
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::PatronConsent |
10 |
|
11 |
=cut |
12 |
|
13 |
use strict; |
14 |
use warnings; |
15 |
|
16 |
use base 'DBIx::Class::Core'; |
17 |
|
18 |
=head1 TABLE: C<patron_consent> |
19 |
|
20 |
=cut |
21 |
|
22 |
__PACKAGE__->table("patron_consent"); |
23 |
|
24 |
=head1 ACCESSORS |
25 |
|
26 |
=head2 id |
27 |
|
28 |
data_type: 'integer' |
29 |
is_auto_increment: 1 |
30 |
is_nullable: 0 |
31 |
|
32 |
=head2 borrowernumber |
33 |
|
34 |
data_type: 'integer' |
35 |
is_foreign_key: 1 |
36 |
is_nullable: 0 |
37 |
|
38 |
=head2 type |
39 |
|
40 |
data_type: 'enum' |
41 |
extra: {list => ["GDPR_PROCESSING"]} |
42 |
is_nullable: 1 |
43 |
|
44 |
=head2 given_on |
45 |
|
46 |
data_type: 'datetime' |
47 |
datetime_undef_if_invalid: 1 |
48 |
is_nullable: 1 |
49 |
|
50 |
=head2 refused_on |
51 |
|
52 |
data_type: 'datetime' |
53 |
datetime_undef_if_invalid: 1 |
54 |
is_nullable: 1 |
55 |
|
56 |
=cut |
57 |
|
58 |
__PACKAGE__->add_columns( |
59 |
"id", |
60 |
{ data_type => "integer", is_auto_increment => 1, is_nullable => 0 }, |
61 |
"borrowernumber", |
62 |
{ data_type => "integer", is_foreign_key => 1, is_nullable => 0 }, |
63 |
"type", |
64 |
{ |
65 |
data_type => "enum", |
66 |
extra => { list => ["GDPR_PROCESSING"] }, |
67 |
is_nullable => 1, |
68 |
}, |
69 |
"given_on", |
70 |
{ |
71 |
data_type => "datetime", |
72 |
datetime_undef_if_invalid => 1, |
73 |
is_nullable => 1, |
74 |
}, |
75 |
"refused_on", |
76 |
{ |
77 |
data_type => "datetime", |
78 |
datetime_undef_if_invalid => 1, |
79 |
is_nullable => 1, |
80 |
}, |
81 |
); |
82 |
|
83 |
=head1 PRIMARY KEY |
84 |
|
85 |
=over 4 |
86 |
|
87 |
=item * L</id> |
88 |
|
89 |
=back |
90 |
|
91 |
=cut |
92 |
|
93 |
__PACKAGE__->set_primary_key("id"); |
94 |
|
95 |
=head1 RELATIONS |
96 |
|
97 |
=head2 borrowernumber |
98 |
|
99 |
Type: belongs_to |
100 |
|
101 |
Related object: L<Koha::Schema::Result::Borrower> |
102 |
|
103 |
=cut |
104 |
|
105 |
__PACKAGE__->belongs_to( |
106 |
"borrowernumber", |
107 |
"Koha::Schema::Result::Borrower", |
108 |
{ borrowernumber => "borrowernumber" }, |
109 |
{ is_deferrable => 1, on_delete => "CASCADE", on_update => "CASCADE" }, |
110 |
); |
111 |
|
112 |
|
113 |
# Created by DBIx::Class::Schema::Loader v0.07042 @ 2018-06-04 14:17:47 |
114 |
# DO NOT MODIFY THIS OR ANYTHING ABOVE! md5sum:rCOHwL/2vlzKAUM517J+HA |
115 |
|
116 |
|
117 |
# You can replace this text with custom code or comments, and it will be preserved on regeneration |
118 |
1; |