Commit 07773e6d authored by Leigh B Stoller's avatar Leigh B Stoller
Browse files

Finish up adding nodelete flag to apt_profiles.

parent e6e76ced
......@@ -444,6 +444,7 @@ CREATE TABLE `apt_profiles` (
`topdog` tinyint(1) NOT NULL default '0',
`no_image_versions` tinyint(1) NOT NULL default '0',
`disabled` tinyint(1) NOT NULL default '0',
`nodelete` tinyint(1) NOT NULL default '0',
`locked` datetime default NULL,
`locker_pid` int(11) default '0',
PRIMARY KEY (`profileid`),
......
......@@ -1332,6 +1332,7 @@ REPLACE INTO table_regex VALUES ('apt_profiles','listed','int','redirect','defau
REPLACE INTO table_regex VALUES ('apt_profiles','shared','int','redirect','default:boolean',0,0,NULL);
REPLACE INTO table_regex VALUES ('apt_profiles','topdog','int','redirect','default:boolean',0,0,NULL);
REPLACE INTO table_regex VALUES ('apt_profiles','disabled','int','redirect','default:boolean',0,0,NULL);
REPLACE INTO table_regex VALUES ('apt_profiles','nodelete','int','redirect','default:boolean',0,0,NULL);
REPLACE INTO table_regex VALUES ('apt_profiles','description','text','redirect','default:html_fulltext',0,512,NULL);
REPLACE INTO table_regex VALUES ('apt_profiles','rspec','text','redirect','default:html_fulltext',0,262143,NULL);
REPLACE INTO table_regex VALUES ('apt_profiles','script','text','redirect','default:html_fulltext',0,65535,NULL);
......
use strict;
use libdb;
sub DoUpdate($$$)
{
my ($dbhandle, $dbname, $version) = @_;
if (!DBSlotExists("apt_profiles", "nodelete")) {
DBQueryFatal("alter table apt_profiles add ".
" `nodelete` tinyint(1) NOT NULL default '0' ".
" after disabled");
}
DBQueryFatal("REPLACE INTO table_regex VALUES ".
" ('apt_profiles','nodelete','int','redirect',".
" 'default:boolean',0,0,NULL)");
return 0;
}
# Local Variables:
# mode:perl
# End:
Supports Markdown
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