2 package Debbugs::DB::Result::SrcPkg;
4 # Created by DBIx::Class::Schema::Loader
5 # DO NOT MODIFY THE FIRST PART OF THIS FILE
9 Debbugs::DB::Result::SrcPkg - Source packages
16 use base 'DBIx::Class::Core';
18 =head1 COMPONENTS LOADED
22 =item * L<DBIx::Class::InflateColumn::DateTime>
28 __PACKAGE__->load_components("InflateColumn::DateTime");
30 =head1 TABLE: C<src_pkg>
34 __PACKAGE__->table("src_pkg");
43 sequence: 'src_pkg_id_seq'
66 Source package id which this source package is an alias of
70 data_type: 'timestamp with time zone'
71 default_value: current_timestamp
73 original: {default_value => \"now()"}
77 data_type: 'timestamp with time zone'
82 data_type: 'timestamp with time zone'
83 default_value: current_timestamp
85 original: {default_value => \"now()"}
95 __PACKAGE__->add_columns(
98 data_type => "integer",
99 is_auto_increment => 1,
101 sequence => "src_pkg_id_seq",
104 { data_type => "text", is_nullable => 0 },
106 { data_type => "boolean", default_value => \"false", is_nullable => 1 },
108 { data_type => "integer", is_foreign_key => 1, is_nullable => 1 },
111 data_type => "timestamp with time zone",
112 default_value => \"current_timestamp",
114 original => { default_value => \"now()" },
117 { data_type => "timestamp with time zone", is_nullable => 1 },
120 data_type => "timestamp with time zone",
121 default_value => \"current_timestamp",
123 original => { default_value => \"now()" },
126 { data_type => "boolean", default_value => \"false", is_nullable => 1 },
139 __PACKAGE__->set_primary_key("id");
141 =head1 UNIQUE CONSTRAINTS
143 =head2 C<src_pkg_pkg_alias>
157 __PACKAGE__->add_unique_constraint("src_pkg_pkg_alias", ["pkg", "alias_of", "obsolete"]);
159 =head2 C<src_pkg_pkg_disabled>
171 __PACKAGE__->add_unique_constraint("src_pkg_pkg_disabled", ["pkg", "disabled"]);
179 Related object: L<Debbugs::DB::Result::SrcPkg>
183 __PACKAGE__->belongs_to(
185 "Debbugs::DB::Result::SrcPkg",
186 { id => "alias_of" },
190 on_delete => "CASCADE",
191 on_update => "CASCADE",
195 =head2 bug_srcpackages
199 Related object: L<Debbugs::DB::Result::BugSrcpackage>
203 __PACKAGE__->has_many(
205 "Debbugs::DB::Result::BugSrcpackage",
206 { "foreign.src_pkg" => "self.id" },
207 { cascade_copy => 0, cascade_delete => 0 },
214 Related object: L<Debbugs::DB::Result::BugVer>
218 __PACKAGE__->has_many(
220 "Debbugs::DB::Result::BugVer",
221 { "foreign.src_pkg" => "self.id" },
222 { cascade_copy => 0, cascade_delete => 0 },
229 Related object: L<Debbugs::DB::Result::SrcPkg>
233 __PACKAGE__->has_many(
235 "Debbugs::DB::Result::SrcPkg",
236 { "foreign.alias_of" => "self.id" },
237 { cascade_copy => 0, cascade_delete => 0 },
244 Related object: L<Debbugs::DB::Result::SrcVer>
248 __PACKAGE__->has_many(
250 "Debbugs::DB::Result::SrcVer",
251 { "foreign.src_pkg" => "self.id" },
252 { cascade_copy => 0, cascade_delete => 0 },
256 # Created by DBIx::Class::Schema::Loader v0.07036 @ 2013-11-13 09:14:52
257 # DO NOT MODIFY THIS OR ANYTHING ABOVE! md5sum:3Jq0yBnJv5OW6jfXwUPUBg
260 # You can replace this text with custom code or comments, and it will be preserved on regeneration