Bug 25501: Supress warnings on installing translation
[koha.git] / Koha / Schema / Result / MessageQueue.pm
blob89d95ac8e48d20842163fdc34bde4f54696f6a35
1 use utf8;
2 package Koha::Schema::Result::MessageQueue;
4 # Created by DBIx::Class::Schema::Loader
5 # DO NOT MODIFY THE FIRST PART OF THIS FILE
7 =head1 NAME
9 Koha::Schema::Result::MessageQueue
11 =cut
13 use strict;
14 use warnings;
16 use base 'DBIx::Class::Core';
18 =head1 TABLE: C<message_queue>
20 =cut
22 __PACKAGE__->table("message_queue");
24 =head1 ACCESSORS
26 =head2 message_id
28 data_type: 'integer'
29 is_auto_increment: 1
30 is_nullable: 0
32 =head2 borrowernumber
34 data_type: 'integer'
35 is_foreign_key: 1
36 is_nullable: 1
38 =head2 subject
40 data_type: 'mediumtext'
41 is_nullable: 1
43 =head2 content
45 data_type: 'mediumtext'
46 is_nullable: 1
48 =head2 metadata
50 data_type: 'mediumtext'
51 is_nullable: 1
53 =head2 letter_code
55 data_type: 'varchar'
56 is_nullable: 1
57 size: 64
59 =head2 message_transport_type
61 data_type: 'varchar'
62 is_foreign_key: 1
63 is_nullable: 0
64 size: 20
66 =head2 status
68 data_type: 'enum'
69 default_value: 'pending'
70 extra: {list => ["sent","pending","failed","deleted"]}
71 is_nullable: 0
73 =head2 time_queued
75 data_type: 'timestamp'
76 datetime_undef_if_invalid: 1
77 is_nullable: 1
79 =head2 updated_on
81 data_type: 'timestamp'
82 datetime_undef_if_invalid: 1
83 default_value: current_timestamp
84 is_nullable: 0
86 =head2 to_address
88 data_type: 'longtext'
89 is_nullable: 1
91 =head2 from_address
93 data_type: 'longtext'
94 is_nullable: 1
96 =head2 reply_address
98 data_type: 'longtext'
99 is_nullable: 1
101 =head2 content_type
103 data_type: 'mediumtext'
104 is_nullable: 1
106 =cut
108 __PACKAGE__->add_columns(
109 "message_id",
110 { data_type => "integer", is_auto_increment => 1, is_nullable => 0 },
111 "borrowernumber",
112 { data_type => "integer", is_foreign_key => 1, is_nullable => 1 },
113 "subject",
114 { data_type => "mediumtext", is_nullable => 1 },
115 "content",
116 { data_type => "mediumtext", is_nullable => 1 },
117 "metadata",
118 { data_type => "mediumtext", is_nullable => 1 },
119 "letter_code",
120 { data_type => "varchar", is_nullable => 1, size => 64 },
121 "message_transport_type",
122 { data_type => "varchar", is_foreign_key => 1, is_nullable => 0, size => 20 },
123 "status",
125 data_type => "enum",
126 default_value => "pending",
127 extra => { list => ["sent", "pending", "failed", "deleted"] },
128 is_nullable => 0,
130 "time_queued",
132 data_type => "timestamp",
133 datetime_undef_if_invalid => 1,
134 is_nullable => 1,
136 "updated_on",
138 data_type => "timestamp",
139 datetime_undef_if_invalid => 1,
140 default_value => \"current_timestamp",
141 is_nullable => 0,
143 "to_address",
144 { data_type => "longtext", is_nullable => 1 },
145 "from_address",
146 { data_type => "longtext", is_nullable => 1 },
147 "reply_address",
148 { data_type => "longtext", is_nullable => 1 },
149 "content_type",
150 { data_type => "mediumtext", is_nullable => 1 },
153 =head1 PRIMARY KEY
155 =over 4
157 =item * L</message_id>
159 =back
161 =cut
163 __PACKAGE__->set_primary_key("message_id");
165 =head1 RELATIONS
167 =head2 borrowernumber
169 Type: belongs_to
171 Related object: L<Koha::Schema::Result::Borrower>
173 =cut
175 __PACKAGE__->belongs_to(
176 "borrowernumber",
177 "Koha::Schema::Result::Borrower",
178 { borrowernumber => "borrowernumber" },
180 is_deferrable => 1,
181 join_type => "LEFT",
182 on_delete => "CASCADE",
183 on_update => "CASCADE",
187 =head2 message_transport_type
189 Type: belongs_to
191 Related object: L<Koha::Schema::Result::MessageTransportType>
193 =cut
195 __PACKAGE__->belongs_to(
196 "message_transport_type",
197 "Koha::Schema::Result::MessageTransportType",
198 { message_transport_type => "message_transport_type" },
199 { is_deferrable => 1, on_delete => "RESTRICT", on_update => "CASCADE" },
203 # Created by DBIx::Class::Schema::Loader v0.07046 @ 2020-02-25 09:43:49
204 # DO NOT MODIFY THIS OR ANYTHING ABOVE! md5sum:9M95gvHiqvdGdahHEHaFaA
206 sub koha_object_class {
207 'Koha::Notice::Message';
209 sub koha_objects_class {
210 'Koha::Notice::Messages';