]> git.donarmstrong.com Git - debbugs.git/blob - Debbugs/DB/Result/Severity.pm
update result classes for new relationships
[debbugs.git] / Debbugs / DB / Result / Severity.pm
1 use utf8;
2 package Debbugs::DB::Result::Severity;
3
4 # Created by DBIx::Class::Schema::Loader
5 # DO NOT MODIFY THE FIRST PART OF THIS FILE
6
7 =head1 NAME
8
9 Debbugs::DB::Result::Severity - Bug severity
10
11 =cut
12
13 use strict;
14 use warnings;
15
16 use base 'DBIx::Class::Core';
17
18 =head1 COMPONENTS LOADED
19
20 =over 4
21
22 =item * L<DBIx::Class::InflateColumn::DateTime>
23
24 =back
25
26 =cut
27
28 __PACKAGE__->load_components("InflateColumn::DateTime");
29
30 =head1 TABLE: C<severity>
31
32 =cut
33
34 __PACKAGE__->table("severity");
35
36 =head1 ACCESSORS
37
38 =head2 id
39
40   data_type: 'integer'
41   is_auto_increment: 1
42   is_nullable: 0
43   sequence: 'severity_id_seq'
44
45 Severity id
46
47 =head2 severity
48
49   data_type: 'text'
50   is_nullable: 0
51
52 Severity name
53
54 =head2 ordering
55
56   data_type: 'integer'
57   default_value: 5
58   is_nullable: 0
59
60 Severity ordering (more severe severities have higher numbers)
61
62 =head2 strong
63
64   data_type: 'boolean'
65   default_value: false
66   is_nullable: 1
67
68 True if severity is a strong severity
69
70 =head2 obsolete
71
72   data_type: 'boolean'
73   default_value: false
74   is_nullable: 1
75
76 Whether a severity level is obsolete (should not be set on new bugs)
77
78 =cut
79
80 __PACKAGE__->add_columns(
81   "id",
82   {
83     data_type         => "integer",
84     is_auto_increment => 1,
85     is_nullable       => 0,
86     sequence          => "severity_id_seq",
87   },
88   "severity",
89   { data_type => "text", is_nullable => 0 },
90   "ordering",
91   { data_type => "integer", default_value => 5, is_nullable => 0 },
92   "strong",
93   { data_type => "boolean", default_value => \"false", is_nullable => 1 },
94   "obsolete",
95   { data_type => "boolean", default_value => \"false", is_nullable => 1 },
96 );
97
98 =head1 PRIMARY KEY
99
100 =over 4
101
102 =item * L</id>
103
104 =back
105
106 =cut
107
108 __PACKAGE__->set_primary_key("id");
109
110 =head1 UNIQUE CONSTRAINTS
111
112 =head2 C<severity_severity_key>
113
114 =over 4
115
116 =item * L</severity>
117
118 =back
119
120 =cut
121
122 __PACKAGE__->add_unique_constraint("severity_severity_key", ["severity"]);
123
124 =head1 RELATIONS
125
126 =head2 bugs
127
128 Type: has_many
129
130 Related object: L<Debbugs::DB::Result::Bug>
131
132 =cut
133
134 __PACKAGE__->has_many(
135   "bugs",
136   "Debbugs::DB::Result::Bug",
137   { "foreign.severity" => "self.id" },
138   { cascade_copy => 0, cascade_delete => 0 },
139 );
140
141
142 # Created by DBIx::Class::Schema::Loader v0.07025 @ 2013-03-27 19:35:10
143 # DO NOT MODIFY THIS OR ANYTHING ABOVE! md5sum:SVJ20W+hu/tjDthRG38xtA
144
145
146 # You can replace this text with custom code or comments, and it will be preserved on regeneration
147 1;