more bug fixes

This commit is contained in:
JT Smith 2005-08-18 19:20:08 +00:00
parent c456b708de
commit 8664a34f1e
7 changed files with 16 additions and 9 deletions

View file

@ -22,6 +22,9 @@
- Fixed a problem with the rich editor in Internet Explorer that caused it - Fixed a problem with the rich editor in Internet Explorer that caused it
not to save new content. not to save new content.
- fix [ 1261789 ] fixed(?) can't edit collaboration (Collaboration.pm) (andreasg) - fix [ 1261789 ] fixed(?) can't edit collaboration (Collaboration.pm) (andreasg)
- fix [ 1262239 ] Error when searching discussion
- fix [ 1253545 ] moving wobjects around in a Layout doesn't spawn revisions
- fix [ 1262991 ] runHourly fails on asset.assetData
6.7.0 6.7.0

View file

@ -24,6 +24,9 @@ save you many hours of grief.
it has been split into two tables "asset" and "assetData" and it has been split into two tables "asset" and "assetData" and
your SQL reports will need to change. your SQL reports will need to change.
* The indexed search asset has been disabled until 6.8 where it will
be entirely rewritten from the ground up.
6.6.4 6.6.4
-------------------------------------------------------------------- --------------------------------------------------------------------

View file

@ -1034,7 +1034,6 @@ sub www_search {
my $sql = "select asset.assetId, asset.className, max(assetData.revisionDate) my $sql = "select asset.assetId, asset.className, max(assetData.revisionDate)
from asset from asset
left join assetData on assetData.assetId=asset.assetId left join assetData on assetData.assetId=asset.assetId
left join Thread on Thread.assetId=assetData.assetId and assetData.revisionDate = Thread.revisionDate
left join Post on Post.assetId=assetData.assetId and assetData.revisionDate = Post.revisionDate left join Post on Post.assetId=assetData.assetId and assetData.revisionDate = Post.revisionDate
where (asset.className='WebGUI::Asset::Post' or asset.className='WebGUI::Asset::Post::Thread') where (asset.className='WebGUI::Asset::Post' or asset.className='WebGUI::Asset::Post::Thread')
and asset.lineage like ".quote($self->get("lineage").'%')." and asset.lineage like ".quote($self->get("lineage").'%')."
@ -1043,7 +1042,7 @@ sub www_search {
assetData.status in ('approved','archived') assetData.status in ('approved','archived')
or assetData.tagId=".quote($session{scratch}{versionTag}); or assetData.tagId=".quote($session{scratch}{versionTag});
$sql .= " or assetData.status='pending'" if ($self->canModerate); $sql .= " or assetData.status='pending'" if ($self->canModerate);
$sql .= " or (asset.ownerUserId=".quote($session{user}{userId})." and asset.ownerUserId<>'1') $sql .= " or (assetData.ownerUserId=".quote($session{user}{userId})." and assetData.ownerUserId<>'1')
) "; ) ";
$sql .= " and ($all) " if ($all ne ""); $sql .= " and ($all) " if ($all ne "");
$sql .= " and " if ($sql ne "" && $exactPhrase ne ""); $sql .= " and " if ($sql ne "" && $exactPhrase ne "");

View file

@ -204,7 +204,7 @@ sub www_edit {
sub www_setContentPositions { sub www_setContentPositions {
my $self = shift; my $self = shift;
return WebGUI::Privilege::insufficient() unless ($self->canEdit); return WebGUI::Privilege::insufficient() unless ($self->canEdit);
$self->update({ $self->addRevision({
contentPositions=>$session{form}{map} contentPositions=>$session{form}{map}
}); });
return "Map set: ".$session{form}{map}; return "Map set: ".$session{form}{map};

View file

@ -23,12 +23,12 @@ sub process {
my $a = WebGUI::SQL->read("select asset.lineage,Collaboration.archiveAfter from Collaboration left join asset on Collaboration.assetId=asset.assetId"); my $a = WebGUI::SQL->read("select asset.lineage,Collaboration.archiveAfter from Collaboration left join asset on Collaboration.assetId=asset.assetId");
while (my ($lineage, $archiveAfter) = $a->array) { while (my ($lineage, $archiveAfter) = $a->array) {
my $archiveDate = $epoch - $archiveAfter; my $archiveDate = $epoch - $archiveAfter;
my $sql = "select * from Post left join asset on Post.assetId=asset.assetId left join Thread on Thread.assetId=Post.assetId my $sql = "select asset.assetId,asset.className, max(assetData.revisionDate) from Post left join asset on Post.assetId=asset.assetId
where Post.dateUpdated<$archiveDate and Post.status='approved' and asset.lineage like ".quote($lineage."%"); left join assetData on Post.assetId=assetData.assetId and assetData.revisionDate=Post.revisionDate
where Post.dateUpdated<$archiveDate and assetData.status='approved' and asset.lineage like ".quote($lineage."%")." group by asset.assetId";
my $b = WebGUI::SQL->read($sql); my $b = WebGUI::SQL->read($sql);
while (my $properties = $b->hashRef) { while (my ($id, $class, $version) = $b->array) {
my $post = WebGUI::Asset::Post->newByPropertyHashRef($properties); WebGUI::Asset::Post->new($id,$class,$version)->setStatusArchived;
$post->setStatusArchived;
} }
$b->finish; $b->finish;
} }

View file

@ -22,6 +22,8 @@ use WebGUI::Asset::Wobject::IndexedSearch::Search;
#------------------------------------------------------------------- #-------------------------------------------------------------------
sub process { sub process {
#disabled until 6.8
return "";
my $indexName = 'IndexedSearch_default'; my $indexName = 'IndexedSearch_default';
my $htmlFilter = 'all'; my $htmlFilter = 'all';
my $stopList = 'none'; my $stopList = 'none';

View file

@ -22,7 +22,7 @@ sub process {
if ($offset ne "") { if ($offset ne "") {
my $epoch = time()-(86400*$offset); my $epoch = time()-(86400*$offset);
my $sth = WebGUI::SQL->read("select asset.assetId,asset.className,max(assetData.revisionDate) from asset left join assetData on my $sth = WebGUI::SQL->read("select asset.assetId,asset.className,max(assetData.revisionDate) from asset left join assetData on
asset.assetId=assetData.assetId where assetData.endDate<".$epoch." and assetData.status<>'pending' group by asset.assetData"); asset.assetId=assetData.assetId where assetData.endDate<".$epoch." group by assetData.assetId");
while (my ($assetId, $class, $version) = $sth->array) { while (my ($assetId, $class, $version) = $sth->array) {
my $asset = WebGUI::Asset->new($assetId,$class,$version); my $asset = WebGUI::Asset->new($assetId,$class,$version);
$asset->trash; $asset->trash;