hydra/src/lib/Hydra/Schema/Jobs.pm

84 lines
1.8 KiB
Perl
Raw Normal View History

2009-03-13 14:49:25 +00:00
package Hydra::Schema::Jobs;
use strict;
use warnings;
use base 'DBIx::Class';
__PACKAGE__->load_components("Core");
__PACKAGE__->table("Jobs");
__PACKAGE__->add_columns(
"project",
{
data_type => "text",
default_value => undef,
is_foreign_key => 1,
is_nullable => 0,
size => undef,
},
2009-03-13 14:49:25 +00:00
"jobset",
{
data_type => "text",
default_value => undef,
is_foreign_key => 1,
is_nullable => 0,
size => undef,
},
2009-03-13 14:49:25 +00:00
"name",
{
data_type => "text",
default_value => undef,
is_nullable => 0,
size => undef,
},
2009-03-13 14:49:25 +00:00
"active",
{ data_type => "integer", default_value => 1, is_nullable => 0, size => undef },
2009-03-13 14:49:25 +00:00
"errormsg",
{
data_type => "text",
default_value => undef,
is_nullable => 1,
size => undef,
},
2009-03-13 14:49:25 +00:00
"firstevaltime",
{
data_type => "integer",
default_value => undef,
is_nullable => 1,
size => undef,
},
2009-03-13 14:49:25 +00:00
"lastevaltime",
{
data_type => "integer",
default_value => undef,
is_nullable => 1,
size => undef,
},
"disabled",
{ data_type => "integer", default_value => 0, is_nullable => 0, size => undef },
2009-03-13 14:49:25 +00:00
);
__PACKAGE__->set_primary_key("project", "jobset", "name");
__PACKAGE__->has_many(
"builds",
"Hydra::Schema::Builds",
{
"foreign.job" => "self.name",
"foreign.jobset" => "self.jobset",
"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
2009-03-13 14:49:25 +00:00
# You can replace this text with custom content, and it will be preserved on regeneration
1;