From: Don Armstrong Date: Wed, 8 Mar 2017 03:04:13 +0000 (-0800) Subject: update to new schema which includes many_to_many relationships X-Git-Url: https://git.donarmstrong.com/?a=commitdiff_plain;h=37d92d86880e6336186b4638695ef690f562bb8a;p=debbugs.git update to new schema which includes many_to_many relationships --- diff --git a/Debbugs/DB.pm b/Debbugs/DB.pm index ed6c46a..656ff00 100644 --- a/Debbugs/DB.pm +++ b/Debbugs/DB.pm @@ -17,7 +17,7 @@ __PACKAGE__->load_namespaces; # This version must be incremented any time the schema changes so that # DBIx::Class::DeploymentHandler can do its work -our $VERSION=4; +our $VERSION=5; # You can replace this text with custom code or comments, and it will be preserved on regeneration diff --git a/Debbugs/DB/Result/BinaryVersion.pm b/Debbugs/DB/Result/BinaryVersion.pm index 57f6b5f..426b725 100644 --- a/Debbugs/DB/Result/BinaryVersion.pm +++ b/Debbugs/DB/Result/BinaryVersion.pm @@ -35,6 +35,7 @@ __PACKAGE__->table_class("DBIx::Class::ResultSource::View"); =cut __PACKAGE__->table("binary_versions"); +__PACKAGE__->result_source_instance->view_definition(" SELECT sp.pkg AS src_pkg,\n sv.ver AS src_ver,\n bp.pkg AS bin_pkg,\n a.arch,\n b.ver AS bin_ver,\n svb.ver AS src_ver_based_on,\n spb.pkg AS src_pkg_based_on\n FROM ((((((bin_ver b\n JOIN arch a ON ((b.arch = a.id)))\n JOIN bin_pkg bp ON ((b.bin_pkg = bp.id)))\n JOIN src_ver sv ON ((b.src_ver = sv.id)))\n JOIN src_pkg sp ON ((sv.src_pkg = sp.id)))\n LEFT JOIN src_ver svb ON ((sv.based_on = svb.id)))\n LEFT JOIN src_pkg spb ON ((spb.id = svb.src_pkg)))"); =head1 ACCESSORS @@ -93,8 +94,8 @@ __PACKAGE__->add_columns( ); -# Created by DBIx::Class::Schema::Loader v0.07042 @ 2014-11-30 21:56:51 -# DO NOT MODIFY THIS OR ANYTHING ABOVE! md5sum:fH11OTb1r9SS1Ps9tM6WPQ +# Created by DBIx::Class::Schema::Loader v0.07046 @ 2017-03-04 10:59:03 +# DO NOT MODIFY THIS OR ANYTHING ABOVE! md5sum:0MeJnGxBc8gdEoPE6Sn6Sw __PACKAGE__->result_source_instance->view_definition(<belongs_to( # Created by DBIx::Class::Schema::Loader v0.07045 @ 2016-09-24 14:51:07 # DO NOT MODIFY THIS OR ANYTHING ABOVE! md5sum:iaipVETTaokcFNrICfIEAw +__PACKAGE__->many_to_many(tags => 'bug_tags','tag'); +__PACKAGE__->many_to_many(user_tags => 'bug_user_tags','user_tag'); +__PACKAGE__->many_to_many(srcpackages => 'bug_srcpackages','src_pkg'); +__PACKAGE__->many_to_many(binpackages => 'bug_binpackages','bin_pkg'); +__PACKAGE__->many_to_many(affects_binpackages => 'bug_affects_binpackages','bin_pkg'); +__PACKAGE__->many_to_many(affects_srcpackages => 'bug_affects_srcpackages','src_pkg'); +__PACKAGE__->many_to_many(messages => 'bug_messages','message'); + # You can replace this text with custom code or comments, and it will be preserved on regeneration 1; diff --git a/Debbugs/DB/Result/BugAffectsBinpackage.pm b/Debbugs/DB/Result/BugAffectsBinpackage.pm index 7b22909..ce4b57e 100644 --- a/Debbugs/DB/Result/BugAffectsBinpackage.pm +++ b/Debbugs/DB/Result/BugAffectsBinpackage.pm @@ -37,13 +37,6 @@ __PACKAGE__->table("bug_affects_binpackage"); =head1 ACCESSORS -=head2 id - - data_type: 'integer' - is_auto_increment: 1 - is_nullable: 0 - sequence: 'bug_affects_binpackage_id_seq' - =head2 bug data_type: 'integer' @@ -63,31 +56,12 @@ Binary package id (matches bin_pkg) =cut __PACKAGE__->add_columns( - "id", - { - data_type => "integer", - is_auto_increment => 1, - is_nullable => 0, - sequence => "bug_affects_binpackage_id_seq", - }, "bug", { data_type => "integer", is_foreign_key => 1, is_nullable => 0 }, "bin_pkg", { data_type => "integer", is_foreign_key => 1, is_nullable => 0 }, ); -=head1 PRIMARY KEY - -=over 4 - -=item * L - -=back - -=cut - -__PACKAGE__->set_primary_key("id"); - =head1 UNIQUE CONSTRAINTS =head2 C @@ -137,8 +111,8 @@ __PACKAGE__->belongs_to( ); -# Created by DBIx::Class::Schema::Loader v0.07042 @ 2014-11-30 21:56:51 -# DO NOT MODIFY THIS OR ANYTHING ABOVE! md5sum:YMVeFNjGPxjuvU6ufDtRVg +# Created by DBIx::Class::Schema::Loader v0.07046 @ 2017-03-04 10:59:03 +# DO NOT MODIFY THIS OR ANYTHING ABOVE! md5sum:qPJSly5VwC8Fl9hchBtB1Q # You can replace this text with custom code or comments, and it will be preserved on regeneration diff --git a/Debbugs/DB/Result/BugAffectsSrcpackage.pm b/Debbugs/DB/Result/BugAffectsSrcpackage.pm index 0c86c75..e25fa60 100644 --- a/Debbugs/DB/Result/BugAffectsSrcpackage.pm +++ b/Debbugs/DB/Result/BugAffectsSrcpackage.pm @@ -37,13 +37,6 @@ __PACKAGE__->table("bug_affects_srcpackage"); =head1 ACCESSORS -=head2 id - - data_type: 'integer' - is_auto_increment: 1 - is_nullable: 0 - sequence: 'bug_affects_srcpackage_id_seq' - =head2 bug data_type: 'integer' @@ -63,31 +56,12 @@ Source package id (matches src_pkg) =cut __PACKAGE__->add_columns( - "id", - { - data_type => "integer", - is_auto_increment => 1, - is_nullable => 0, - sequence => "bug_affects_srcpackage_id_seq", - }, "bug", { data_type => "integer", is_foreign_key => 1, is_nullable => 0 }, "src_pkg", { data_type => "integer", is_foreign_key => 1, is_nullable => 0 }, ); -=head1 PRIMARY KEY - -=over 4 - -=item * L - -=back - -=cut - -__PACKAGE__->set_primary_key("id"); - =head1 UNIQUE CONSTRAINTS =head2 C @@ -137,8 +111,8 @@ __PACKAGE__->belongs_to( ); -# Created by DBIx::Class::Schema::Loader v0.07042 @ 2014-11-30 21:56:51 -# DO NOT MODIFY THIS OR ANYTHING ABOVE! md5sum:BjS8+RV2k7wjqyLqmCZ+2w +# Created by DBIx::Class::Schema::Loader v0.07046 @ 2017-03-04 10:59:03 +# DO NOT MODIFY THIS OR ANYTHING ABOVE! md5sum:1TkTacVNBhXOnzV1ttCF2A # You can replace this text with custom code or comments, and it will be preserved on regeneration diff --git a/Debbugs/DB/Result/BugBinpackage.pm b/Debbugs/DB/Result/BugBinpackage.pm index 63223df..869ce26 100644 --- a/Debbugs/DB/Result/BugBinpackage.pm +++ b/Debbugs/DB/Result/BugBinpackage.pm @@ -37,13 +37,6 @@ __PACKAGE__->table("bug_binpackage"); =head1 ACCESSORS -=head2 id - - data_type: 'integer' - is_auto_increment: 1 - is_nullable: 0 - sequence: 'bug_binpackage_id_seq' - =head2 bug data_type: 'integer' @@ -63,31 +56,12 @@ Binary package id (matches bin_pkg) =cut __PACKAGE__->add_columns( - "id", - { - data_type => "integer", - is_auto_increment => 1, - is_nullable => 0, - sequence => "bug_binpackage_id_seq", - }, "bug", { data_type => "integer", is_foreign_key => 1, is_nullable => 0 }, "bin_pkg", { data_type => "integer", is_foreign_key => 1, is_nullable => 0 }, ); -=head1 PRIMARY KEY - -=over 4 - -=item * L - -=back - -=cut - -__PACKAGE__->set_primary_key("id"); - =head1 UNIQUE CONSTRAINTS =head2 C @@ -137,8 +111,8 @@ __PACKAGE__->belongs_to( ); -# Created by DBIx::Class::Schema::Loader v0.07042 @ 2014-11-30 21:56:51 -# DO NOT MODIFY THIS OR ANYTHING ABOVE! md5sum:FZAi6kX8ICe/ZJI0JEqZLg +# Created by DBIx::Class::Schema::Loader v0.07046 @ 2017-03-04 10:59:03 +# DO NOT MODIFY THIS OR ANYTHING ABOVE! md5sum:wL+pwSCfWe/mMQOjziKSeg # You can replace this text with custom code or comments, and it will be preserved on regeneration diff --git a/Debbugs/DB/Result/BugMessage.pm b/Debbugs/DB/Result/BugMessage.pm index b2aa87c..cf5b193 100644 --- a/Debbugs/DB/Result/BugMessage.pm +++ b/Debbugs/DB/Result/BugMessage.pm @@ -37,13 +37,6 @@ __PACKAGE__->table("bug_message"); =head1 ACCESSORS -=head2 id - - data_type: 'integer' - is_auto_increment: 1 - is_nullable: 0 - sequence: 'bug_message_id_seq' - =head2 bug data_type: 'integer' @@ -84,13 +77,6 @@ Time offset was valid =cut __PACKAGE__->add_columns( - "id", - { - data_type => "integer", - is_auto_increment => 1, - is_nullable => 0, - sequence => "bug_message_id_seq", - }, "bug", { data_type => "integer", is_foreign_key => 1, is_nullable => 0 }, "message", @@ -103,18 +89,6 @@ __PACKAGE__->add_columns( { data_type => "timestamp with time zone", is_nullable => 1 }, ); -=head1 PRIMARY KEY - -=over 4 - -=item * L - -=back - -=cut - -__PACKAGE__->set_primary_key("id"); - =head1 UNIQUE CONSTRAINTS =head2 C @@ -164,8 +138,8 @@ __PACKAGE__->belongs_to( ); -# Created by DBIx::Class::Schema::Loader v0.07042 @ 2014-11-30 21:56:51 -# DO NOT MODIFY THIS OR ANYTHING ABOVE! md5sum:gof8IcnKupbpDmbU39kx6A +# Created by DBIx::Class::Schema::Loader v0.07046 @ 2017-03-04 10:59:03 +# DO NOT MODIFY THIS OR ANYTHING ABOVE! md5sum:BRbN9C6P/wvWWmSmjNGjLA # You can replace this text with custom code or comments, and it will be preserved on regeneration diff --git a/Debbugs/DB/Result/BugPackage.pm b/Debbugs/DB/Result/BugPackage.pm index b3d40b8..9019fca 100644 --- a/Debbugs/DB/Result/BugPackage.pm +++ b/Debbugs/DB/Result/BugPackage.pm @@ -35,6 +35,7 @@ __PACKAGE__->table_class("DBIx::Class::ResultSource::View"); =cut __PACKAGE__->table("bug_package"); +__PACKAGE__->result_source_instance->view_definition(" SELECT b.bug,\n b.bin_pkg AS pkg_id,\n 'binary'::text AS pkg_type,\n bp.pkg AS package\n FROM (bug_binpackage b\n JOIN bin_pkg bp ON ((bp.id = b.bin_pkg)))\nUNION\n SELECT s.bug,\n s.src_pkg AS pkg_id,\n 'source'::text AS pkg_type,\n sp.pkg AS package\n FROM (bug_srcpackage s\n JOIN src_pkg sp ON ((sp.id = s.src_pkg)))"); =head1 ACCESSORS @@ -72,8 +73,8 @@ __PACKAGE__->add_columns( ); -# Created by DBIx::Class::Schema::Loader v0.07042 @ 2014-11-30 21:56:51 -# DO NOT MODIFY THIS OR ANYTHING ABOVE! md5sum:Ok2J+mjxvBcgdiqigiCBQA +# Created by DBIx::Class::Schema::Loader v0.07046 @ 2017-03-04 10:59:03 +# DO NOT MODIFY THIS OR ANYTHING ABOVE! md5sum:+zeVIVZOYSZjTkD+1N2sdw __PACKAGE__->result_source_instance->view_definition(<table("bug_srcpackage"); =head1 ACCESSORS -=head2 id - - data_type: 'integer' - is_auto_increment: 1 - is_nullable: 0 - sequence: 'bug_srcpackage_id_seq' - =head2 bug data_type: 'integer' @@ -63,31 +56,12 @@ Source package id (matches src_pkg) =cut __PACKAGE__->add_columns( - "id", - { - data_type => "integer", - is_auto_increment => 1, - is_nullable => 0, - sequence => "bug_srcpackage_id_seq", - }, "bug", { data_type => "integer", is_foreign_key => 1, is_nullable => 0 }, "src_pkg", { data_type => "integer", is_foreign_key => 1, is_nullable => 0 }, ); -=head1 PRIMARY KEY - -=over 4 - -=item * L - -=back - -=cut - -__PACKAGE__->set_primary_key("id"); - =head1 UNIQUE CONSTRAINTS =head2 C @@ -137,8 +111,8 @@ __PACKAGE__->belongs_to( ); -# Created by DBIx::Class::Schema::Loader v0.07042 @ 2014-11-30 21:56:51 -# DO NOT MODIFY THIS OR ANYTHING ABOVE! md5sum:rkrGE3oLGWe28oXEFt4UFg +# Created by DBIx::Class::Schema::Loader v0.07046 @ 2017-03-04 10:59:03 +# DO NOT MODIFY THIS OR ANYTHING ABOVE! md5sum:5SduyMaGHABDrX19Cxg4fg # You can replace this text with custom code or comments, and it will be preserved on regeneration diff --git a/Debbugs/DB/Result/BugStatusCache.pm b/Debbugs/DB/Result/BugStatusCache.pm index 7aea543..3d2dcc9 100644 --- a/Debbugs/DB/Result/BugStatusCache.pm +++ b/Debbugs/DB/Result/BugStatusCache.pm @@ -37,15 +37,6 @@ __PACKAGE__->table("bug_status_cache"); =head1 ACCESSORS -=head2 id - - data_type: 'integer' - is_auto_increment: 1 - is_nullable: 0 - sequence: 'bug_status_cache_id_seq' - -Bug status cache entry id - =head2 bug data_type: 'integer' @@ -99,13 +90,6 @@ Time that this status was last calculated =cut __PACKAGE__->add_columns( - "id", - { - data_type => "integer", - is_auto_increment => 1, - is_nullable => 0, - sequence => "bug_status_cache_id_seq", - }, "bug", { data_type => "integer", is_foreign_key => 1, is_nullable => 0 }, "suite", @@ -144,18 +128,6 @@ __PACKAGE__->add_columns( }, ); -=head1 PRIMARY KEY - -=over 4 - -=item * L - -=back - -=cut - -__PACKAGE__->set_primary_key("id"); - =head1 UNIQUE CONSTRAINTS =head2 C @@ -235,8 +207,8 @@ __PACKAGE__->belongs_to( ); -# Created by DBIx::Class::Schema::Loader v0.07045 @ 2016-09-24 14:51:07 -# DO NOT MODIFY THIS OR ANYTHING ABOVE! md5sum:jrPFpLs6vLgKWMSLyJAkxA +# Created by DBIx::Class::Schema::Loader v0.07046 @ 2017-03-04 10:59:03 +# DO NOT MODIFY THIS OR ANYTHING ABOVE! md5sum:dgaCogdpUWo99BQhdH68Mg # You can replace this text with custom code or comments, and it will be preserved on regeneration diff --git a/Debbugs/DB/Result/BugTag.pm b/Debbugs/DB/Result/BugTag.pm index 625f445..15e5c3a 100644 --- a/Debbugs/DB/Result/BugTag.pm +++ b/Debbugs/DB/Result/BugTag.pm @@ -37,13 +37,6 @@ __PACKAGE__->table("bug_tag"); =head1 ACCESSORS -=head2 id - - data_type: 'integer' - is_auto_increment: 1 - is_nullable: 0 - sequence: 'bug_tag_id_seq' - =head2 bug data_type: 'integer' @@ -63,31 +56,12 @@ Tag id (matches tag) =cut __PACKAGE__->add_columns( - "id", - { - data_type => "integer", - is_auto_increment => 1, - is_nullable => 0, - sequence => "bug_tag_id_seq", - }, "bug", { data_type => "integer", is_foreign_key => 1, is_nullable => 0 }, "tag", { data_type => "integer", is_foreign_key => 1, is_nullable => 0 }, ); -=head1 PRIMARY KEY - -=over 4 - -=item * L - -=back - -=cut - -__PACKAGE__->set_primary_key("id"); - =head1 UNIQUE CONSTRAINTS =head2 C @@ -137,8 +111,8 @@ __PACKAGE__->belongs_to( ); -# Created by DBIx::Class::Schema::Loader v0.07042 @ 2014-11-30 21:56:51 -# DO NOT MODIFY THIS OR ANYTHING ABOVE! md5sum:g7sgOcROAtOdRa9vrI5gQg +# Created by DBIx::Class::Schema::Loader v0.07046 @ 2017-03-04 10:59:03 +# DO NOT MODIFY THIS OR ANYTHING ABOVE! md5sum:yyHP5f8zAxn/AdjOCr8WAg # You can replace this text with custom code or comments, and it will be preserved on regeneration diff --git a/Debbugs/DB/Result/BugUserTag.pm b/Debbugs/DB/Result/BugUserTag.pm index 3363b62..113a36a 100644 --- a/Debbugs/DB/Result/BugUserTag.pm +++ b/Debbugs/DB/Result/BugUserTag.pm @@ -37,13 +37,6 @@ __PACKAGE__->table("bug_user_tag"); =head1 ACCESSORS -=head2 id - - data_type: 'integer' - is_auto_increment: 1 - is_nullable: 0 - sequence: 'bug_user_tag_id_seq' - =head2 bug data_type: 'integer' @@ -61,31 +54,12 @@ Bug id (matches bug) =cut __PACKAGE__->add_columns( - "id", - { - data_type => "integer", - is_auto_increment => 1, - is_nullable => 0, - sequence => "bug_user_tag_id_seq", - }, "bug", { data_type => "integer", is_foreign_key => 1, is_nullable => 0 }, "user_tag", { data_type => "integer", is_foreign_key => 1, is_nullable => 0 }, ); -=head1 PRIMARY KEY - -=over 4 - -=item * L - -=back - -=cut - -__PACKAGE__->set_primary_key("id"); - =head1 UNIQUE CONSTRAINTS =head2 C @@ -135,8 +109,8 @@ __PACKAGE__->belongs_to( ); -# Created by DBIx::Class::Schema::Loader v0.07045 @ 2016-09-24 14:51:07 -# DO NOT MODIFY THIS OR ANYTHING ABOVE! md5sum:bczKcbFkWt98BDvXLdhpcg +# Created by DBIx::Class::Schema::Loader v0.07046 @ 2017-03-04 10:59:03 +# DO NOT MODIFY THIS OR ANYTHING ABOVE! md5sum:jZngUCQ1eBBcfXd/jWCKGA # You can replace this text with custom code or comments, and it will be preserved on regeneration diff --git a/Debbugs/DB/Result/CorrespondentFullName.pm b/Debbugs/DB/Result/CorrespondentFullName.pm index d4f73b0..107e10b 100644 --- a/Debbugs/DB/Result/CorrespondentFullName.pm +++ b/Debbugs/DB/Result/CorrespondentFullName.pm @@ -37,21 +37,14 @@ __PACKAGE__->table("correspondent_full_name"); =head1 ACCESSORS -=head2 id - - data_type: 'integer' - is_auto_increment: 1 - is_nullable: 0 - sequence: 'correspondent_full_name_id_seq' - -Correspondent full name id - =head2 correspondent data_type: 'integer' is_foreign_key: 1 is_nullable: 0 +Correspondent ID (matches correspondent) + =head2 full_name data_type: 'text' @@ -69,13 +62,6 @@ Correspondent full name (includes e-mail address) =cut __PACKAGE__->add_columns( - "id", - { - data_type => "integer", - is_auto_increment => 1, - is_nullable => 0, - sequence => "correspondent_full_name_id_seq", - }, "correspondent", { data_type => "integer", is_foreign_key => 1, is_nullable => 0 }, "full_name", @@ -89,18 +75,6 @@ __PACKAGE__->add_columns( }, ); -=head1 PRIMARY KEY - -=over 4 - -=item * L - -=back - -=cut - -__PACKAGE__->set_primary_key("id"); - =head1 UNIQUE CONSTRAINTS =head2 C @@ -138,8 +112,8 @@ __PACKAGE__->belongs_to( ); -# Created by DBIx::Class::Schema::Loader v0.07042 @ 2014-11-30 21:56:51 -# DO NOT MODIFY THIS OR ANYTHING ABOVE! md5sum:rXiBbe/rMz4dOMgW5ZovWw +# Created by DBIx::Class::Schema::Loader v0.07046 @ 2017-03-04 10:59:03 +# DO NOT MODIFY THIS OR ANYTHING ABOVE! md5sum:2Ac8mrDV2IsE/11YsYoqQQ # You can replace this text with custom code or comments, and it will be preserved on regeneration diff --git a/Debbugs/DB/Result/Message.pm b/Debbugs/DB/Result/Message.pm index bc493f1..0ac17aa 100644 --- a/Debbugs/DB/Result/Message.pm +++ b/Debbugs/DB/Result/Message.pm @@ -62,14 +62,6 @@ Message id header Complete from header of message -=head2 from_addr - - data_type: 'text' - default_value: (empty string) - is_nullable: 0 - -Address(es) of From: headers - =head2 to_complete data_type: 'text' @@ -78,14 +70,6 @@ Address(es) of From: headers Complete to header of message -=head2 to_addr - - data_type: 'text' - default_value: (empty string) - is_nullable: 0 - -Address(es) of To: header - =head2 subject data_type: 'text' @@ -139,12 +123,8 @@ __PACKAGE__->add_columns( { data_type => "text", default_value => "", is_nullable => 0 }, "from_complete", { data_type => "text", default_value => "", is_nullable => 0 }, - "from_addr", - { data_type => "text", default_value => "", is_nullable => 0 }, "to_complete", { data_type => "text", default_value => "", is_nullable => 0 }, - "to_addr", - { data_type => "text", default_value => "", is_nullable => 0 }, "subject", { data_type => "text", default_value => "", is_nullable => 0 }, "sent_date", @@ -255,9 +235,13 @@ __PACKAGE__->has_many( ); -# Created by DBIx::Class::Schema::Loader v0.07042 @ 2014-11-30 21:56:51 -# DO NOT MODIFY THIS OR ANYTHING ABOVE! md5sum:Dow6t1MS7ldAy6KBMtBWRQ +# Created by DBIx::Class::Schema::Loader v0.07046 @ 2017-03-07 19:03:32 +# DO NOT MODIFY THIS OR ANYTHING ABOVE! md5sum:n8U0vD9R8M5wFoeoLlIWeQ +__PACKAGE__->many_to_many(bugs => 'bug_messages','bug'); +__PACKAGE__->many_to_many(correspondents => 'message_correspondents','correspondent'); +__PACKAGE__->many_to_many(references => 'message_refs_message','message'); +__PACKAGE__->many_to_many(referenced_by => 'message_refs_refs','message'); # You can replace this text with custom code or comments, and it will be preserved on regeneration 1; diff --git a/Debbugs/DB/Result/MessageCorrespondent.pm b/Debbugs/DB/Result/MessageCorrespondent.pm index 4820e3f..16550aa 100644 --- a/Debbugs/DB/Result/MessageCorrespondent.pm +++ b/Debbugs/DB/Result/MessageCorrespondent.pm @@ -37,13 +37,6 @@ __PACKAGE__->table("message_correspondent"); =head1 ACCESSORS -=head2 id - - data_type: 'integer' - is_auto_increment: 1 - is_nullable: 0 - sequence: 'message_correspondent_id_seq' - =head2 message data_type: 'integer' @@ -64,7 +57,7 @@ Correspondent (matches correspondent) data_type: 'enum' default_value: 'to' - extra: {custom_type_name => "message_correspondent_type",list => ["to","from","envfrom","cc"]} + extra: {custom_type_name => "message_correspondent_type",list => ["to","from","envfrom","cc","recv"]} is_nullable: 0 Type of correspondent (to, from, envfrom, cc, etc.) @@ -72,13 +65,6 @@ Type of correspondent (to, from, envfrom, cc, etc.) =cut __PACKAGE__->add_columns( - "id", - { - data_type => "integer", - is_auto_increment => 1, - is_nullable => 0, - sequence => "message_correspondent_id_seq", - }, "message", { data_type => "integer", is_foreign_key => 1, is_nullable => 0 }, "correspondent", @@ -89,24 +75,12 @@ __PACKAGE__->add_columns( default_value => "to", extra => { custom_type_name => "message_correspondent_type", - list => ["to", "from", "envfrom", "cc"], + list => ["to", "from", "envfrom", "cc", "recv"], }, is_nullable => 0, }, ); -=head1 PRIMARY KEY - -=over 4 - -=item * L - -=back - -=cut - -__PACKAGE__->set_primary_key("id"); - =head1 UNIQUE CONSTRAINTS =head2 C @@ -161,8 +135,8 @@ __PACKAGE__->belongs_to( ); -# Created by DBIx::Class::Schema::Loader v0.07042 @ 2014-11-30 21:56:51 -# DO NOT MODIFY THIS OR ANYTHING ABOVE! md5sum:HiQOa7XliOu8PNC8DxQPnQ +# Created by DBIx::Class::Schema::Loader v0.07046 @ 2017-03-07 19:03:32 +# DO NOT MODIFY THIS OR ANYTHING ABOVE! md5sum:kIhya7skj4ZNM3DkC+gAPw # You can replace this text with custom code or comments, and it will be preserved on regeneration diff --git a/Debbugs/DB/Result/MessageRef.pm b/Debbugs/DB/Result/MessageRef.pm index eb42652..8d695b7 100644 --- a/Debbugs/DB/Result/MessageRef.pm +++ b/Debbugs/DB/Result/MessageRef.pm @@ -37,13 +37,6 @@ __PACKAGE__->table("message_refs"); =head1 ACCESSORS -=head2 id - - data_type: 'integer' - is_auto_increment: 1 - is_nullable: 0 - sequence: 'message_refs_id_seq' - =head2 message data_type: 'integer' @@ -79,13 +72,6 @@ TRUE if this message->ref came from In-Reply-To: or similar. =cut __PACKAGE__->add_columns( - "id", - { - data_type => "integer", - is_auto_increment => 1, - is_nullable => 0, - sequence => "message_refs_id_seq", - }, "message", { data_type => "integer", is_foreign_key => 1, is_nullable => 0 }, "refs", @@ -96,18 +82,6 @@ __PACKAGE__->add_columns( { data_type => "boolean", default_value => \"false", is_nullable => 1 }, ); -=head1 PRIMARY KEY - -=over 4 - -=item * L - -=back - -=cut - -__PACKAGE__->set_primary_key("id"); - =head1 UNIQUE CONSTRAINTS =head2 C @@ -157,8 +131,8 @@ __PACKAGE__->belongs_to( ); -# Created by DBIx::Class::Schema::Loader v0.07042 @ 2014-11-30 21:56:51 -# DO NOT MODIFY THIS OR ANYTHING ABOVE! md5sum:AYCyNKkqOAjoWVelU0HKrA +# Created by DBIx::Class::Schema::Loader v0.07046 @ 2017-03-04 10:59:03 +# DO NOT MODIFY THIS OR ANYTHING ABOVE! md5sum:0YaAP/sB5N2Xr2rAFNK1lg # You can replace this text with custom code or comments, and it will be preserved on regeneration diff --git a/Debbugs/DB/Result/SrcPkg.pm b/Debbugs/DB/Result/SrcPkg.pm index b9e8022..10266fa 100644 --- a/Debbugs/DB/Result/SrcPkg.pm +++ b/Debbugs/DB/Result/SrcPkg.pm @@ -57,7 +57,7 @@ Source package name data_type: 'boolean' default_value: false - is_nullable: 1 + is_nullable: 0 =head2 alias_of @@ -71,26 +71,27 @@ Source package id which this source package is an alias of data_type: 'timestamp with time zone' default_value: current_timestamp - is_nullable: 1 + is_nullable: 0 original: {default_value => \"now()"} =head2 disabled data_type: 'timestamp with time zone' - is_nullable: 1 + default_value: infinity + is_nullable: 0 =head2 last_modified data_type: 'timestamp with time zone' default_value: current_timestamp - is_nullable: 1 + is_nullable: 0 original: {default_value => \"now()"} =head2 obsolete data_type: 'boolean' default_value: false - is_nullable: 1 + is_nullable: 0 =cut @@ -105,27 +106,31 @@ __PACKAGE__->add_columns( "pkg", { data_type => "text", is_nullable => 0 }, "pseduopkg", - { data_type => "boolean", default_value => \"false", is_nullable => 1 }, + { data_type => "boolean", default_value => \"false", is_nullable => 0 }, "alias_of", { data_type => "integer", is_foreign_key => 1, is_nullable => 1 }, "creation", { data_type => "timestamp with time zone", default_value => \"current_timestamp", - is_nullable => 1, + is_nullable => 0, original => { default_value => \"now()" }, }, "disabled", - { data_type => "timestamp with time zone", is_nullable => 1 }, + { + data_type => "timestamp with time zone", + default_value => "infinity", + is_nullable => 0, + }, "last_modified", { data_type => "timestamp with time zone", default_value => \"current_timestamp", - is_nullable => 1, + is_nullable => 0, original => { default_value => \"now()" }, }, "obsolete", - { data_type => "boolean", default_value => \"false", is_nullable => 1 }, + { data_type => "boolean", default_value => \"false", is_nullable => 0 }, ); =head1 PRIMARY KEY @@ -254,8 +259,8 @@ __PACKAGE__->has_many( ); -# Created by DBIx::Class::Schema::Loader v0.07042 @ 2014-11-30 21:56:51 -# DO NOT MODIFY THIS OR ANYTHING ABOVE! md5sum:qJt8Dn/9gBxJKauPUCFS7w +# Created by DBIx::Class::Schema::Loader v0.07046 @ 2017-03-04 10:59:03 +# DO NOT MODIFY THIS OR ANYTHING ABOVE! md5sum:j8LGu4eUfNUNxM/jkHUG2A # You can replace this text with custom code or comments, and it will be preserved on regeneration