|
Line 0
Link Here
|
| 0 |
- |
1 |
use utf8; |
|
|
2 |
package Koha::Schema::Result::MailDomainLimit; |
| 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::MailDomainLimit |
| 10 |
|
| 11 |
=cut |
| 12 |
|
| 13 |
use strict; |
| 14 |
use warnings; |
| 15 |
|
| 16 |
use base 'DBIx::Class::Core'; |
| 17 |
|
| 18 |
=head1 TABLE: C<mail_domain_limits> |
| 19 |
|
| 20 |
=cut |
| 21 |
|
| 22 |
__PACKAGE__->table("mail_domain_limits"); |
| 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 domain_name |
| 33 |
|
| 34 |
data_type: 'tinytext' |
| 35 |
is_nullable: 0 |
| 36 |
|
| 37 |
=head2 domain_limit |
| 38 |
|
| 39 |
data_type: 'integer' |
| 40 |
is_nullable: 1 |
| 41 |
|
| 42 |
=head2 units |
| 43 |
|
| 44 |
data_type: 'integer' |
| 45 |
is_nullable: 1 |
| 46 |
|
| 47 |
=head2 unit_type |
| 48 |
|
| 49 |
data_type: 'enum' |
| 50 |
extra: {list => ["minutes","hours","days"]} |
| 51 |
is_nullable: 1 |
| 52 |
|
| 53 |
=head2 belongs_to |
| 54 |
|
| 55 |
accessor: undef |
| 56 |
data_type: 'integer' |
| 57 |
is_foreign_key: 1 |
| 58 |
is_nullable: 1 |
| 59 |
|
| 60 |
=cut |
| 61 |
|
| 62 |
__PACKAGE__->add_columns( |
| 63 |
"id", |
| 64 |
{ data_type => "integer", is_auto_increment => 1, is_nullable => 0 }, |
| 65 |
"domain_name", |
| 66 |
{ data_type => "tinytext", is_nullable => 0 }, |
| 67 |
"domain_limit", |
| 68 |
{ data_type => "integer", is_nullable => 1 }, |
| 69 |
"units", |
| 70 |
{ data_type => "integer", is_nullable => 1 }, |
| 71 |
"unit_type", |
| 72 |
{ |
| 73 |
data_type => "enum", |
| 74 |
extra => { list => ["minutes", "hours", "days"] }, |
| 75 |
is_nullable => 1, |
| 76 |
}, |
| 77 |
"belongs_to", |
| 78 |
{ |
| 79 |
accessor => undef, |
| 80 |
data_type => "integer", |
| 81 |
is_foreign_key => 1, |
| 82 |
is_nullable => 1, |
| 83 |
}, |
| 84 |
); |
| 85 |
|
| 86 |
=head1 PRIMARY KEY |
| 87 |
|
| 88 |
=over 4 |
| 89 |
|
| 90 |
=item * L</id> |
| 91 |
|
| 92 |
=back |
| 93 |
|
| 94 |
=cut |
| 95 |
|
| 96 |
__PACKAGE__->set_primary_key("id"); |
| 97 |
|
| 98 |
=head1 UNIQUE CONSTRAINTS |
| 99 |
|
| 100 |
=head2 C<mail_domain_limits_uniq1> |
| 101 |
|
| 102 |
=over 4 |
| 103 |
|
| 104 |
=item * L</domain_name> |
| 105 |
|
| 106 |
=back |
| 107 |
|
| 108 |
=cut |
| 109 |
|
| 110 |
__PACKAGE__->add_unique_constraint("mail_domain_limits_uniq1", ["domain_name"]); |
| 111 |
|
| 112 |
=head1 RELATIONS |
| 113 |
|
| 114 |
=head2 belongs_to_rel |
| 115 |
|
| 116 |
Type: belongs_to |
| 117 |
|
| 118 |
Related object: L<Koha::Schema::Result::MailDomainLimit> |
| 119 |
|
| 120 |
=cut |
| 121 |
|
| 122 |
__PACKAGE__->belongs_to( |
| 123 |
"belongs_to_rel", |
| 124 |
"Koha::Schema::Result::MailDomainLimit", |
| 125 |
{ id => "belongs_to" }, |
| 126 |
{ |
| 127 |
is_deferrable => 1, |
| 128 |
join_type => "LEFT", |
| 129 |
on_delete => "CASCADE", |
| 130 |
on_update => "CASCADE", |
| 131 |
}, |
| 132 |
); |
| 133 |
|
| 134 |
=head2 mail_domain_limits |
| 135 |
|
| 136 |
Type: has_many |
| 137 |
|
| 138 |
Related object: L<Koha::Schema::Result::MailDomainLimit> |
| 139 |
|
| 140 |
=cut |
| 141 |
|
| 142 |
__PACKAGE__->has_many( |
| 143 |
"mail_domain_limits", |
| 144 |
"Koha::Schema::Result::MailDomainLimit", |
| 145 |
{ "foreign.belongs_to" => "self.id" }, |
| 146 |
{ cascade_copy => 0, cascade_delete => 0 }, |
| 147 |
); |
| 148 |
|
| 149 |
|
| 150 |
# Created by DBIx::Class::Schema::Loader v0.07049 @ 2023-07-03 08:44:06 |
| 151 |
# DO NOT MODIFY THIS OR ANYTHING ABOVE! md5sum:ua1qQTtFvrZGtMMBvsCaHg |
| 152 |
|
| 153 |
|
| 154 |
# You can replace this text with custom code or comments, and it will be preserved on regeneration |
| 155 |
1; |