]> git.donarmstrong.com Git - debbugs.git/blob - Debbugs/DB/Result/BugStatus.pm
Merge branch 'mouseify'
[debbugs.git] / Debbugs / DB / Result / BugStatus.pm
1 use utf8;
2 package Debbugs::DB::Result::BugStatus;
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::BugStatus
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 =item * L<DBIx::Class::TimeStamp>
25
26 =back
27
28 =cut
29
30 __PACKAGE__->load_components("InflateColumn::DateTime", "TimeStamp");
31 __PACKAGE__->table_class("DBIx::Class::ResultSource::View");
32
33 =head1 TABLE: C<bug_status>
34
35 =cut
36
37 __PACKAGE__->table("bug_status");
38 __PACKAGE__->result_source_instance->view_definition(" SELECT b.id,\n    b.id AS bug_num,\n    string_agg(t.tag, ','::text) AS tags,\n    b.subject,\n    ( SELECT s.severity\n           FROM severity s\n          WHERE (s.id = b.severity)) AS severity,\n    ( SELECT string_agg(package.package, ','::text ORDER BY package.package) AS string_agg\n           FROM ( SELECT bp.pkg AS package\n                   FROM (bug_binpackage bbp\n                     JOIN bin_pkg bp ON ((bbp.bin_pkg = bp.id)))\n                  WHERE (bbp.bug = b.id)\n                UNION\n                 SELECT concat('src:', sp.pkg) AS package\n                   FROM (bug_srcpackage bsp\n                     JOIN src_pkg sp ON ((bsp.src_pkg = sp.id)))\n                  WHERE (bsp.bug = b.id)) package) AS package,\n    ( SELECT string_agg(affects.affects, ','::text ORDER BY affects.affects) AS string_agg\n           FROM ( SELECT bp.pkg AS affects\n                   FROM (bug_affects_binpackage bbp\n                     JOIN bin_pkg bp ON ((bbp.bin_pkg = bp.id)))\n                  WHERE (bbp.bug = b.id)\n                UNION\n                 SELECT concat('src:', sp.pkg) AS affects\n                   FROM (bug_affects_srcpackage bsp\n                     JOIN src_pkg sp ON ((bsp.src_pkg = sp.id)))\n                  WHERE (bsp.bug = b.id)) affects) AS affects,\n    ( SELECT m.msgid\n           FROM (message m\n             LEFT JOIN bug_message bm ON ((bm.message = m.id)))\n          WHERE (bm.bug = b.id)\n          ORDER BY m.sent_date\n         LIMIT 1) AS message_id,\n    b.submitter_full AS originator,\n    date_part('epoch'::text, b.log_modified) AS log_modified,\n    date_part('epoch'::text, b.creation) AS date,\n    date_part('epoch'::text, b.last_modified) AS last_modified,\n    b.done_full AS done,\n    string_agg((bb.blocks)::text, ' '::text ORDER BY bb.blocks) AS blocks,\n    string_agg((bbb.bug)::text, ' '::text ORDER BY bbb.bug) AS blockedby,\n    ( SELECT string_agg((bug.bug)::text, ' '::text ORDER BY bug.bug) AS string_agg\n           FROM ( SELECT bm.merged AS bug\n                   FROM bug_merged bm\n                  WHERE (bm.bug = b.id)\n                UNION\n                 SELECT bm.bug\n                   FROM bug_merged bm\n                  WHERE (bm.merged = b.id)) bug) AS mergedwith,\n    ( SELECT string_agg(bv.ver_string, ' '::text) AS string_agg\n           FROM bug_ver bv\n          WHERE ((bv.bug = b.id) AND (bv.found IS TRUE))) AS found_versions,\n    ( SELECT string_agg(bv.ver_string, ' '::text) AS string_agg\n           FROM bug_ver bv\n          WHERE ((bv.bug = b.id) AND (bv.found IS FALSE))) AS fixed_versions\n   FROM ((((bug b\n     LEFT JOIN bug_tag bt ON ((bt.bug = b.id)))\n     LEFT JOIN tag t ON ((bt.tag = t.id)))\n     LEFT JOIN bug_blocks bb ON ((bb.bug = b.id)))\n     LEFT JOIN bug_blocks bbb ON ((bbb.blocks = b.id)))\n  GROUP BY b.id");
39
40 =head1 ACCESSORS
41
42 =head2 id
43
44   data_type: 'integer'
45   is_nullable: 1
46
47 =head2 bug_num
48
49   data_type: 'integer'
50   is_nullable: 1
51
52 =head2 tags
53
54   data_type: 'text'
55   is_nullable: 1
56
57 =head2 subject
58
59   data_type: 'text'
60   is_nullable: 1
61
62 =head2 severity
63
64   data_type: 'text'
65   is_nullable: 1
66
67 =head2 package
68
69   data_type: 'text'
70   is_nullable: 1
71
72 =head2 affects
73
74   data_type: 'text'
75   is_nullable: 1
76
77 =head2 message_id
78
79   data_type: 'text'
80   is_nullable: 1
81
82 =head2 originator
83
84   data_type: 'text'
85   is_nullable: 1
86
87 =head2 log_modified
88
89   data_type: 'double precision'
90   is_nullable: 1
91
92 =head2 date
93
94   data_type: 'double precision'
95   is_nullable: 1
96
97 =head2 last_modified
98
99   data_type: 'double precision'
100   is_nullable: 1
101
102 =head2 done
103
104   data_type: 'text'
105   is_nullable: 1
106
107 =head2 blocks
108
109   data_type: 'text'
110   is_nullable: 1
111
112 =head2 blockedby
113
114   data_type: 'text'
115   is_nullable: 1
116
117 =head2 mergedwith
118
119   data_type: 'text'
120   is_nullable: 1
121
122 =head2 found_versions
123
124   data_type: 'text'
125   is_nullable: 1
126
127 =head2 fixed_versions
128
129   data_type: 'text'
130   is_nullable: 1
131
132 =cut
133
134 __PACKAGE__->add_columns(
135   "id",
136   { data_type => "integer", is_nullable => 1 },
137   "bug_num",
138   { data_type => "integer", is_nullable => 1 },
139   "tags",
140   { data_type => "text", is_nullable => 1 },
141   "subject",
142   { data_type => "text", is_nullable => 1 },
143   "severity",
144   { data_type => "text", is_nullable => 1 },
145   "package",
146   { data_type => "text", is_nullable => 1 },
147   "affects",
148   { data_type => "text", is_nullable => 1 },
149   "message_id",
150   { data_type => "text", is_nullable => 1 },
151   "originator",
152   { data_type => "text", is_nullable => 1 },
153   "log_modified",
154   { data_type => "double precision", is_nullable => 1 },
155   "date",
156   { data_type => "double precision", is_nullable => 1 },
157   "last_modified",
158   { data_type => "double precision", is_nullable => 1 },
159   "done",
160   { data_type => "text", is_nullable => 1 },
161   "blocks",
162   { data_type => "text", is_nullable => 1 },
163   "blockedby",
164   { data_type => "text", is_nullable => 1 },
165   "mergedwith",
166   { data_type => "text", is_nullable => 1 },
167   "found_versions",
168   { data_type => "text", is_nullable => 1 },
169   "fixed_versions",
170   { data_type => "text", is_nullable => 1 },
171 );
172
173
174 # Created by DBIx::Class::Schema::Loader v0.07049 @ 2019-07-05 20:55:00
175 # DO NOT MODIFY THIS OR ANYTHING ABOVE! md5sum:xkAEshcLIPrG/6hoRbSsrw
176
177
178 # You can replace this text with custom code or comments, and it will be preserved on regeneration
179 1;