merging 7.4 changes

This commit is contained in:
Graham Knop 2008-01-23 23:48:35 +00:00
parent 5292426cc5
commit 1149fd54ed
19 changed files with 319 additions and 167 deletions

View file

@ -33,6 +33,10 @@
- fix: Mails sent from WebGUI now wrap at 78 characters, as the SMTP
RFC asks, to fix problems with some SMTP servers when lines exceed
998 characters. (The Next Phase / MedIntellibase)
- fix: Fatal Errors Kill Login Session
- fix: Calendar Event recurrence stretching over daylight savings time changes use wrong times
- fix: In IE, 'Insert WebGUI Image' loses some attributes
- fix: Collaboration System threads sometimes unable to find next/previous thread
7.4.20
- fix: Assets with no committed versions may be left as orphans when parent is purged
@ -40,10 +44,14 @@
- fix: Calendar Edit template refers to non-existant and other unneeded javascript files
7.4.19
- fix: Select all doesn't work in trash in IE or with a single item
- fix: Import Package does nothing when re-importing trashed package
- fix: CS Posts get re-ordered when copy/paste
- fix: Matrix best/worst now must have 10 or more votes
- fix: When upgrading, two revisions of same asset added in same second.
- fix: Uncommitted Snippets get cached when not in admin mode and are then served to visitors
- fix: Admin Console icons sometimes not shown in IE7
- fix: Syndicated Content asset not decoding with entities properly
7.4.18
- fix: Graph draws black triangle covering half the image
@ -60,6 +68,7 @@
7.4.17
- fix: double width characters encoded incorrectly in Collaboration RSS feed
- fix: update method in various assets changes incoming parameters
- fix: ExtrasUrl in conf http:// stripping / from URL (perlDreamer Consulting, LLC.)
http://www.plainblack.com/bugs/tracker/extrasurl-in-conf-http/-stripping-/-from-url
@ -97,8 +106,8 @@
- fix: EMS edit badge event list can display incorrectly in IE
- fix: Expired SessionScratch not deleted (thanks to Michelle Lamar)
http://www.plainblack.com/bugs/tracker/expired-sessionscratch-not-deleted
- fix: Bad import of help template variables from other topics. (perlDreamer Consulting, LLC.)
- fix: Remove old templates that used to belong to the Events Calendar (perlDreamer Consulting, LLC.)
- fix: Bad import of help template variables from other topics. (perlDreamer Consulting, LLC.)
7.4.12
- fix: extra empty/grey area at the bottom of pages

File diff suppressed because one or more lines are too long

View file

@ -0,0 +1,125 @@
#-------------------------------------------------------------------
# WebGUI is Copyright 2001-2006 Plain Black Corporation.
#-------------------------------------------------------------------
# Please read the legal notices (docs/legal.txt) and the license
# (docs/license.txt) that came with this distribution before using
# this software.
#-------------------------------------------------------------------
# http://www.plainblack.com info@plainblack.com
#-------------------------------------------------------------------
use lib "../../lib";
use strict;
use Getopt::Long;
use WebGUI::Session;
my $toVersion = '7.4.21';
my $quiet; # this line required
my $session = start(); # this line required
# upgrade functions go here
finish($session); # this line required
##-------------------------------------------------
#sub exampleFunction {
# my $session = shift;
# print "\tWe're doing some stuff here that you should know about.\n" unless ($quiet);
# # and here's our code
#}
# ---- DO NOT EDIT BELOW THIS LINE ----
#-------------------------------------------------
sub start {
my $configFile;
$|=1; #disable output buffering
GetOptions(
'configFile=s'=>\$configFile,
'quiet'=>\$quiet
);
my $session = WebGUI::Session->open("../..",$configFile);
$session->user({userId=>3});
my $versionTag = WebGUI::VersionTag->getWorking($session);
$versionTag->set({name=>"Upgrade to ".$toVersion});
$session->db->write("insert into webguiVersion values (".$session->db->quote($toVersion).",'upgrade',".$session->datetime->time().")");
updateTemplates($session);
return $session;
}
#-------------------------------------------------
sub finish {
my $session = shift;
my $versionTag = WebGUI::VersionTag->getWorking($session);
$versionTag->commit;
$session->close();
}
#-------------------------------------------------
sub updateTemplates {
my $session = shift;
return undef unless (-d "templates-".$toVersion);
print "\tUpdating templates.\n" unless ($quiet);
opendir(DIR,"templates-".$toVersion);
my @files = readdir(DIR);
closedir(DIR);
my $importNode = WebGUI::Asset->getImportNode($session);
my $newFolder = undef;
foreach my $file (@files) {
next unless ($file =~ /\.tmpl$/);
open(FILE,"<templates-".$toVersion."/".$file);
my $first = 1;
my $create = 0;
my $head = 0;
my %properties = (className=>"WebGUI::Asset::Template");
while (my $line = <FILE>) {
if ($first) {
$line =~ m/^\#(.*)$/;
$properties{id} = $1;
$first = 0;
} elsif ($line =~ m/^\#create$/) {
$create = 1;
} elsif ($line =~ m/^\#(.*):\s*(.*)$/) {
$properties{$1} = $2;
} elsif ($line =~ m/^~~~$/) {
$head = 1;
} elsif ($head) {
$properties{headBlock} .= $line;
} else {
$properties{template} .= $line;
}
}
close(FILE);
if ($create) {
$newFolder = createNewTemplatesFolder($importNode) unless (defined $newFolder);
my $template = $newFolder->addChild(\%properties, $properties{id});
} else {
my $template = WebGUI::Asset->new($session,$properties{id}, "WebGUI::Asset::Template");
if (defined $template) {
my $newRevision = $template->addRevision(\%properties);
}
}
}
}
#-------------------------------------------------
sub createNewTemplatesFolder {
my $importNode = shift;
my $newFolder = $importNode->addChild({
className=>"WebGUI::Asset::Wobject::Folder",
title => $toVersion." New Templates",
menuTitle => $toVersion." New Templates",
url=> $toVersion."_new_templates",
groupIdView=>"12"
});
return $newFolder;
}