Commit 43e53bc3 authored by Leigh B Stoller's avatar Leigh B Stoller
Browse files

Add new slots to apt extension info table for recording auto approval info.

parent 72fa735e
......@@ -224,6 +224,9 @@ CREATE TABLE `apt_instance_extension_info` (
`wanted` smallint(5) unsigned NOT NULL default '0',
`granted` smallint(5) unsigned default NULL,
`needapproval` tinyint(1) NOT NULL default '0',
`autoapproved` tinyint(1) NOT NULL default '0',
`autoapproved_reason` tinytext,
`autoapproved_metrics` mediumtext,
`admin` tinyint(1) NOT NULL default '0',
`reason` mediumtext,
`message` mediumtext,
......
use strict;
use libdb;
sub DoUpdate($$$)
{
my ($dbhandle, $dbname, $version) = @_;
if (!DBSlotExists("apt_instance_extension_info", "autoapproved")) {
DBQueryFatal("alter table apt_instance_extension_info add " .
" `autoapproved` tinyint(1) NOT NULL default '0' ".
" after needapproval");
}
if (!DBSlotExists("apt_instance_extension_info", "autoapproved_reason")) {
DBQueryFatal("alter table apt_instance_extension_info add " .
" `autoapproved_reason` tinytext after autoapproved");
}
if (!DBSlotExists("apt_instance_extension_info", "autoapproved_metrics")) {
DBQueryFatal("alter table apt_instance_extension_info add " .
" `autoapproved_metrics` mediumtext ".
" after autoapproved_reason");
}
return 0;
}
# 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