]> git.koha-community.org Git - koha.git/blob - Koha/Schema/Result/SpecialHoliday.pm
Bug 12446: (QA follow-up) Minor kohastructure.sql fix
[koha.git] / Koha / Schema / Result / SpecialHoliday.pm
1 use utf8;
2 package Koha::Schema::Result::SpecialHoliday;
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::SpecialHoliday
10
11 =cut
12
13 use strict;
14 use warnings;
15
16 use base 'DBIx::Class::Core';
17
18 =head1 TABLE: C<special_holidays>
19
20 =cut
21
22 __PACKAGE__->table("special_holidays");
23
24 =head1 ACCESSORS
25
26 =head2 id
27
28   data_type: 'integer'
29   is_auto_increment: 1
30   is_nullable: 0
31
32 unique identifier assigned by Koha
33
34 =head2 branchcode
35
36   data_type: 'varchar'
37   is_foreign_key: 1
38   is_nullable: 0
39   size: 10
40
41 foreign key from the branches table, defines which branch this closing is for
42
43 =head2 day
44
45   data_type: 'smallint'
46   default_value: 0
47   is_nullable: 0
48
49 day of the month this closing is on
50
51 =head2 month
52
53   data_type: 'smallint'
54   default_value: 0
55   is_nullable: 0
56
57 month this closing is in
58
59 =head2 year
60
61   data_type: 'smallint'
62   default_value: 0
63   is_nullable: 0
64
65 year this closing is in
66
67 =head2 isexception
68
69   data_type: 'smallint'
70   default_value: 1
71   is_nullable: 0
72
73 is this a holiday exception to a repeatable holiday (1 for yes, 0 for no)
74
75 =head2 title
76
77   data_type: 'varchar'
78   default_value: (empty string)
79   is_nullable: 0
80   size: 50
81
82 title for this closing
83
84 =head2 description
85
86   data_type: 'mediumtext'
87   is_nullable: 0
88
89 description of this closing
90
91 =cut
92
93 __PACKAGE__->add_columns(
94   "id",
95   { data_type => "integer", is_auto_increment => 1, is_nullable => 0 },
96   "branchcode",
97   { data_type => "varchar", is_foreign_key => 1, is_nullable => 0, size => 10 },
98   "day",
99   { data_type => "smallint", default_value => 0, is_nullable => 0 },
100   "month",
101   { data_type => "smallint", default_value => 0, is_nullable => 0 },
102   "year",
103   { data_type => "smallint", default_value => 0, is_nullable => 0 },
104   "isexception",
105   { data_type => "smallint", default_value => 1, is_nullable => 0 },
106   "title",
107   { data_type => "varchar", default_value => "", is_nullable => 0, size => 50 },
108   "description",
109   { data_type => "mediumtext", is_nullable => 0 },
110 );
111
112 =head1 PRIMARY KEY
113
114 =over 4
115
116 =item * L</id>
117
118 =back
119
120 =cut
121
122 __PACKAGE__->set_primary_key("id");
123
124 =head1 RELATIONS
125
126 =head2 branchcode
127
128 Type: belongs_to
129
130 Related object: L<Koha::Schema::Result::Branch>
131
132 =cut
133
134 __PACKAGE__->belongs_to(
135   "branchcode",
136   "Koha::Schema::Result::Branch",
137   { branchcode => "branchcode" },
138   { is_deferrable => 1, on_delete => "CASCADE", on_update => "CASCADE" },
139 );
140
141
142 # Created by DBIx::Class::Schema::Loader v0.07049 @ 2021-01-21 13:39:29
143 # DO NOT MODIFY THIS OR ANYTHING ABOVE! md5sum:H3PUa5HiJKKfdndKXbmJ6A
144
145
146 # You can replace this text with custom content, and it will be preserved on regeneration
147 1;