Commit 47260f80 authored by Mike Hibler's avatar Mike Hibler

Add 'failed' as a state for project_leases.

parent 4416d540
......@@ -4333,7 +4333,7 @@ CREATE TABLE `project_leases` (
`lease_end` timestamp NOT NULL default '2037-01-19 03:14:07',
`last_used` timestamp NOT NULL default '0000-00-00 00:00:00',
`last_checked` timestamp NOT NULL default '0000-00-00 00:00:00',
`state` enum('valid','unapproved','grace','locked','expired') NOT NULL default 'unapproved',
`state` enum('valid','unapproved','grace','locked','expired','failed') NOT NULL default 'unapproved',
`statestamp` timestamp NOT NULL default '0000-00-00 00:00:00',
`renewals` int(10) unsigned NOT NULL default '0',
`locked` datetime default NULL,
......
use strict;
use libdb;
sub DoUpdate($$$)
{
my ($dbhandle, $dbname, $version) = @_;
my $type = DBSlotType("project_leases", "state");
if (!$type) {
Fatal("Could not get type for 'state' in 'project_leases'");
}
if (! ($type =~ /failed/)) {
DBQueryFatal("alter table project_leases modify `state` ".
" enum('valid','unapproved','grace','locked',".
" 'expired','failed')".
" NOT NULL default 'unapproved'");
}
return 0;
}
1;
# Local Variables:
# mode:perl
# End:
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment