Image Asset tests, upgrade package, and code.
RSS Limiter tests, upgrade package, and code.
This commit is contained in:
commit
4c408da55a
10 changed files with 856 additions and 13 deletions
BIN
docs/upgrades/packages-7.7.1/image3.wgpkg
Normal file
BIN
docs/upgrades/packages-7.7.1/image3.wgpkg
Normal file
Binary file not shown.
|
|
@ -31,10 +31,15 @@ my $quiet; # this line required
|
|||
my $session = start(); # this line required
|
||||
|
||||
# upgrade functions go here
|
||||
|
||||
addWelcomeMessageTemplateToSettings( $session );
|
||||
addStatisticsCacheTimeoutToMatrix( $session );
|
||||
|
||||
# image mods
|
||||
addImageAnnotation($session);
|
||||
|
||||
# rss mods
|
||||
addRssLimit($session);
|
||||
|
||||
finish($session); # this line required
|
||||
|
||||
sub addWelcomeMessageTemplateToSettings {
|
||||
|
|
@ -45,6 +50,28 @@ sub addWelcomeMessageTemplateToSettings {
|
|||
print "Done.\n" unless $quiet;
|
||||
}
|
||||
|
||||
#----------------------------------------------------------------------------
|
||||
sub addRssLimit {
|
||||
my $session = shift;
|
||||
print "\tAdding rssLimit to RSSCapable table, if needed... \n" unless $quiet;
|
||||
my $sth = $session->db->read('describe RSSCapable rssCableRssLimit');
|
||||
if (! defined $sth->hashRef) {
|
||||
$session->db->write("alter table RSSCapable add column rssCableRssLimit integer");
|
||||
}
|
||||
print "Done.\n" unless $quiet;
|
||||
}
|
||||
|
||||
#----------------------------------------------------------------------------
|
||||
sub addImageAnnotation {
|
||||
my $session = shift;
|
||||
print "\tAdding annotations to imageAsset table, if needed... \n" unless $quiet;
|
||||
my $sth = $session->db->read('describe imageAsset annotations');
|
||||
if (! defined $sth->hashRef) {
|
||||
$session->db->write("alter table imageAsset add column annotations mediumtext");
|
||||
}
|
||||
print "Done.\n" unless $quiet;
|
||||
}
|
||||
|
||||
#----------------------------------------------------------------------------
|
||||
sub addStatisticsCacheTimeoutToMatrix{
|
||||
my $session = shift;
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue