diff --git a/docs/changelog/7.x.x.txt b/docs/changelog/7.x.x.txt index 01c303ae5..de301f7f3 100644 --- a/docs/changelog/7.x.x.txt +++ b/docs/changelog/7.x.x.txt @@ -21,6 +21,7 @@ - fixed #9315: Password Recovery - fixed #9298: Inconsistent date formats - fixed #9296: Thingy View template not recognising field_isVisible (SDH Consulting Group) + - fixed #4196: update button doesn't work in IE 7.6.6 - fixed #8792: Image Preview gives ERROR in Collateral Manager diff --git a/lib/WebGUI/Operation/VersionTag.pm b/lib/WebGUI/Operation/VersionTag.pm index b89f9686d..cad2bd6a5 100644 --- a/lib/WebGUI/Operation/VersionTag.pm +++ b/lib/WebGUI/Operation/VersionTag.pm @@ -642,7 +642,8 @@ sub www_manageRevisionsInTag { $ac->addSubmenuItem($session->url->page('op=manageVersions'), $i18n->get("manage versions")); # Process any actions - if ( $session->form->get('action') eq "purge" ) { + my $action = lc $session->form->get('action'); + if ( $action eq "purge" ) { # Purge these revisions my @assetInfo = $session->form->get('assetInfo'); for my $assetInfo ( @assetInfo ) { @@ -657,7 +658,7 @@ sub www_manageRevisionsInTag { return www_manageVersions( $session ); } } - elsif ( $session->form->get('action') eq "move" ) { + elsif ( $action eq "move to:" ) { # Get the new version tag my $moveToTagId = $session->form->get('moveToTagId'); my $moveToTag; @@ -685,7 +686,7 @@ sub www_manageRevisionsInTag { return www_manageVersions( $session ); } } - elsif ( $session->form->get('action') eq "update" ) { + elsif ( $action eq "update version tag" ) { my $startTime = WebGUI::DateTime->new($session,$session->form->process("startTime","dateTime"))->toDatabase; my $endTime = WebGUI::DateTime->new($session,$session->form->process("endTime","dateTime"))->toDatabase; @@ -746,6 +747,10 @@ sub www_manageRevisionsInTag { ( getVersionTagOptions( $session ) ), ); + ##Setup valid times for the datetime range form + my $filterStartTime = defined $tag->get('startTime') ? $tag->get('startTime') : '1970-01-17 05:00:00'; + my $filterEndTime = defined $tag->get('endTime') ? $tag->get('endTime') : time(); + # Output the revisions ### FIXME: Users who only pass canApproveVersionTag() and not canViewVersionTag() should # probably not be allowed to see the Actions or modify the Start and End dates @@ -759,23 +764,23 @@ sub www_manageRevisionsInTag { . $i18n->get('startTime label').': ' . WebGUI::Form::dateTime($session, { name =>"startTime", - value => WebGUI::DateTime->new($session,$tag->get("startTime"))->epoch, + value => WebGUI::DateTime->new($session,$filterStartTime)->epoch, }) . '
'.$i18n->get('endTime label').': ' . WebGUI::Form::dateTime($session,{ name =>"endTime", - value => WebGUI::DateTime->new($session,$tag->get("endTime"))->epoch, + value => WebGUI::DateTime->new($session,$filterEndTime)->epoch, }) . '
' - . '' + . '' . '' . '' . ' ' . '' . '' . $i18n->get("manageRevisionsInTag with selected") - . '' - . '' + . '' + . '' . WebGUI::Form::SelectBox( $session, { name => 'moveToTagId', options => \%moveToTagOptions, diff --git a/lib/WebGUI/i18n/English/VersionTag.pm b/lib/WebGUI/i18n/English/VersionTag.pm index 9e0e568bf..bcb05ba71 100644 --- a/lib/WebGUI/i18n/English/VersionTag.pm +++ b/lib/WebGUI/i18n/English/VersionTag.pm @@ -374,7 +374,7 @@ our $I18N = { }, 'manageRevisionsInTag update' => { - message => q{Update}, + message => q{Update Version Tag}, lastUpdated => 0, context => q{Label for button to update revisions}, }, @@ -476,6 +476,7 @@ our $I18N = { lastUpdated => 0, context => q{Explanation of Permission Denied message}, }, + }; 1;