]> git.donarmstrong.com Git - debbugs.git/blob - Debbugs/DB/Result/BugVer.pm
add bug message bits to sql
[debbugs.git] / Debbugs / DB / Result / BugVer.pm
1 use utf8;
2 package Debbugs::DB::Result::BugVer;
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::BugVer
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<bug_ver>
31
32 =cut
33
34 __PACKAGE__->table("bug_ver");
35
36 =head1 ACCESSORS
37
38 =head2 bug_id
39
40   data_type: 'integer'
41   is_foreign_key: 1
42   is_nullable: 0
43
44 =head2 ver_string
45
46   data_type: 'text'
47   is_nullable: 1
48
49 =head2 src_pkg_id
50
51   data_type: 'integer'
52   is_foreign_key: 1
53   is_nullable: 1
54
55 =head2 src_ver_id
56
57   data_type: 'integer'
58   is_foreign_key: 1
59   is_nullable: 1
60
61 =head2 found
62
63   data_type: 'boolean'
64   default_value: true
65   is_nullable: 0
66
67 =head2 creation
68
69   data_type: 'timestamp with time zone'
70   default_value: current_timestamp
71   is_nullable: 0
72   original: {default_value => \"now()"}
73
74 =head2 last_modified
75
76   data_type: 'timestamp with time zone'
77   default_value: current_timestamp
78   is_nullable: 0
79   original: {default_value => \"now()"}
80
81 =cut
82
83 __PACKAGE__->add_columns(
84   "bug_id",
85   { data_type => "integer", is_foreign_key => 1, is_nullable => 0 },
86   "ver_string",
87   { data_type => "text", is_nullable => 1 },
88   "src_pkg_id",
89   { data_type => "integer", is_foreign_key => 1, is_nullable => 1 },
90   "src_ver_id",
91   { data_type => "integer", is_foreign_key => 1, is_nullable => 1 },
92   "found",
93   { data_type => "boolean", default_value => \"true", is_nullable => 0 },
94   "creation",
95   {
96     data_type     => "timestamp with time zone",
97     default_value => \"current_timestamp",
98     is_nullable   => 0,
99     original      => { default_value => \"now()" },
100   },
101   "last_modified",
102   {
103     data_type     => "timestamp with time zone",
104     default_value => \"current_timestamp",
105     is_nullable   => 0,
106     original      => { default_value => \"now()" },
107   },
108 );
109
110 =head1 UNIQUE CONSTRAINTS
111
112 =head2 C<bug_ver_bug_id_ver_string_found_idx>
113
114 =over 4
115
116 =item * L</bug_id>
117
118 =item * L</ver_string>
119
120 =item * L</found>
121
122 =back
123
124 =cut
125
126 __PACKAGE__->add_unique_constraint(
127   "bug_ver_bug_id_ver_string_found_idx",
128   ["bug_id", "ver_string", "found"],
129 );
130
131 =head1 RELATIONS
132
133 =head2 bug
134
135 Type: belongs_to
136
137 Related object: L<Debbugs::DB::Result::Bug>
138
139 =cut
140
141 __PACKAGE__->belongs_to(
142   "bug",
143   "Debbugs::DB::Result::Bug",
144   { id => "bug_id" },
145   { is_deferrable => 1, on_delete => "CASCADE", on_update => "CASCADE" },
146 );
147
148 =head2 src_pkg
149
150 Type: belongs_to
151
152 Related object: L<Debbugs::DB::Result::SrcPkg>
153
154 =cut
155
156 __PACKAGE__->belongs_to(
157   "src_pkg",
158   "Debbugs::DB::Result::SrcPkg",
159   { id => "src_pkg_id" },
160   {
161     is_deferrable => 1,
162     join_type     => "LEFT",
163     on_delete     => "CASCADE",
164     on_update     => "CASCADE",
165   },
166 );
167
168 =head2 src_ver
169
170 Type: belongs_to
171
172 Related object: L<Debbugs::DB::Result::SrcVer>
173
174 =cut
175
176 __PACKAGE__->belongs_to(
177   "src_ver",
178   "Debbugs::DB::Result::SrcVer",
179   { id => "src_ver_id" },
180   {
181     is_deferrable => 1,
182     join_type     => "LEFT",
183     on_delete     => "CASCADE",
184     on_update     => "CASCADE",
185   },
186 );
187
188
189 # Created by DBIx::Class::Schema::Loader v0.07025 @ 2012-11-23 17:41:43
190 # DO NOT MODIFY THIS OR ANYTHING ABOVE! md5sum:JMDsn7GGxoQ001KYUOyyTw
191
192
193 # You can replace this text with custom code or comments, and it will be preserved on regeneration
194 1;