* Cleaned up the foreign key constraints.

* Generate SQLite and PostgreSQL schemas from hydra.sql.
This commit is contained in:
Eelco Dolstra
2009-10-21 12:25:43 +00:00
parent 2cf42489e2
commit 686b6271d2
24 changed files with 276 additions and 240 deletions

View File

@ -58,6 +58,12 @@ __PACKAGE__->add_columns(
{ data_type => "integer", default_value => 0, is_nullable => 0, size => undef },
);
__PACKAGE__->set_primary_key("project", "jobset", "name");
__PACKAGE__->belongs_to("project", "Hydra::Schema::Projects", { name => "project" });
__PACKAGE__->belongs_to(
"jobset",
"Hydra::Schema::Jobsets",
{ name => "jobset", project => "project" },
);
__PACKAGE__->has_many(
"builds",
"Hydra::Schema::Builds",
@ -67,16 +73,10 @@ __PACKAGE__->has_many(
"foreign.project" => "self.project",
},
);
__PACKAGE__->belongs_to("project", "Hydra::Schema::Projects", { name => "project" });
__PACKAGE__->belongs_to(
"jobset",
"Hydra::Schema::Jobsets",
{ name => "jobset", project => "project" },
);
# Created by DBIx::Class::Schema::Loader v0.04999_06 @ 2009-10-15 23:14:39
# DO NOT MODIFY THIS OR ANYTHING ABOVE! md5sum:c0OEe2zPd/E4vh0PRXm4Ag
# Created by DBIx::Class::Schema::Loader v0.04999_06 @ 2009-10-21 14:17:55
# DO NOT MODIFY THIS OR ANYTHING ABOVE! md5sum:AjrYM1rAdgYy3j0+IFFUEw
# You can replace this text with custom content, and it will be preserved on regeneration