Author: jfthomps Date: Wed Mar 21 20:02:17 2012 New Revision: 1303546 URL: http://svn.apache.org/viewvc?rev=1303546&view=rev Log: VCL-527 Allow users to reinstall newer revisions
requests.php: modified AJshowReinstall - had a bug with a ')' in the wrong place which was causing a prompt for which revision to use even if there was only 1 revision requests.js: modified hideReinstallResDlg - removed dijit.byId('reinstalldlg').hide which was causing hideReinstallResDlg to get called in a loop Modified: incubator/vcl/trunk/web/.ht-inc/requests.php incubator/vcl/trunk/web/js/requests.js Modified: incubator/vcl/trunk/web/.ht-inc/requests.php URL: http://svn.apache.org/viewvc/incubator/vcl/trunk/web/.ht-inc/requests.php?rev=1303546&r1=1303545&r2=1303546&view=diff ============================================================================== --- incubator/vcl/trunk/web/.ht-inc/requests.php (original) +++ incubator/vcl/trunk/web/.ht-inc/requests.php Wed Mar 21 20:02:17 2012 @@ -3011,7 +3011,7 @@ function AJrebootRequest() { /// /// \fn AJshowReinstallRequest() /// -/// \brief +/// \brief generates text for prompting user about reinstalling reservation /// //////////////////////////////////////////////////////////////////////////////// function AJshowReinstallRequest() { @@ -3030,7 +3030,7 @@ function AJshowReinstallRequest() { if(count($reqdata['reservations']) == 1 && ($imgdata[$imageid]['ownerid'] == $user['id'] || checkUserHasPerm('View Debug Information')) && - count($imgdata[$imageid]['imagerevision'] > 1)) { + count($imgdata[$imageid]['imagerevision']) > 1) { # prompt for which revision to use for reinstall $t .= "This will cause the reserved machine to be reinstalled. "; $t .= "You may select which version<br>of the environment you would "; @@ -3068,8 +3068,8 @@ function AJshowReinstallRequest() { else { # prompt for reinstall confirmation $t .= "This will cause the reserved machine to be reinstalled. Any<br>"; - $t .= "data saved only to the reserved machine will be lost. Are<br>"; - $t .= "you sure you want to continue?<br><br>"; + $t .= "data saved only to the reserved machine <strong>will be lost"; + $t .= "</strong>. Are<br>you sure you want to continue?<br><br>"; } sendJSON(array('status' => 'success', 'txt' => $t, 'cont' => $cont)); } Modified: incubator/vcl/trunk/web/js/requests.js URL: http://svn.apache.org/viewvc/incubator/vcl/trunk/web/js/requests.js?rev=1303546&r1=1303545&r2=1303546&view=diff ============================================================================== --- incubator/vcl/trunk/web/js/requests.js (original) +++ incubator/vcl/trunk/web/js/requests.js Wed Mar 21 20:02:17 2012 @@ -637,7 +637,6 @@ function submitRebootReservation() { } function hideReinstallResDlg() { - dijit.byId('reinstalldlg').hide(); dojo.addClass('reinstallbtns', 'hidden'); dojo.byId('reinstallResDlgContent').innerHTML = ''; dojo.byId('reinstallResDlgErrMsg').innerHTML = '';