From 4e9a7cfdb9a257c42a4b9973786511c6671bfd49 Mon Sep 17 00:00:00 2001 From: xq2005 Date: Tue, 11 Jan 2011 09:22:45 +0000 Subject: [PATCH] merge start/stop into one dialogure git-svn-id: https://svn.code.sf.net/p/xcat/code/xcat-core/trunk@8602 8638fb3e-16cb-4fca-ae20-7b5d299a9bcd --- xCAT-UI/css/style.css | 6 +- xCAT-UI/js/monitor/rmcmon.js | 225 +++++++++++++++------------- xCAT-server/lib/xcat/plugins/web.pm | 10 +- 3 files changed, 126 insertions(+), 115 deletions(-) diff --git a/xCAT-UI/css/style.css b/xCAT-UI/css/style.css index 1c1aa21c9..4f0b2b587 100644 --- a/xCAT-UI/css/style.css +++ b/xCAT-UI/css/style.css @@ -633,11 +633,11 @@ table a:hover { .fspDiv2 { font-size: 12px; - height: 20px; - line-height: 20px; + height: 21px; + line-height: 21px; width: 140px; text-align: center; - background: url(../images/4ufsp.jpg); + background: url(../images/2ufsp.jpg); border-style: solid; border-width: 1px; cursor: pointer; diff --git a/xCAT-UI/js/monitor/rmcmon.js b/xCAT-UI/js/monitor/rmcmon.js index f62952933..a15c8e7b9 100644 --- a/xCAT-UI/js/monitor/rmcmon.js +++ b/xCAT-UI/js/monitor/rmcmon.js @@ -667,6 +667,7 @@ function loadRmcEvent(){ */ function getConditions(){ if ('' == globalCondition){ + $('#rmcEventStatus').empty().append('Getting predefined conditions').append(createLoader()); $.ajax({ url : 'lib/cmd.php', dataType : 'json', @@ -678,10 +679,15 @@ function getConditions(){ }, success : function(data){ + $('#rmcEventStatus').empty(); + $('#rmcEventButtons').show(); globalCondition = data.rsp[0]; } }); } + else{ + $('#rmcEventButtons').show(); + } } /** @@ -776,29 +782,26 @@ function showEventLog(data){ * */ function loadRmcEventConfig(){ + var buttons = $(''); var chCondScopeBut = createButton('Change Condition Scope'); chCondScopeBut.bind('click', function(){ chCondScopeDia(); }); - $('#rmcEventDiv').append(chCondScopeBut); + buttons.append(chCondScopeBut); var mkCondRespBut = createButton('Make/Remove Association'); mkCondRespBut.bind('click', function(){ mkCondRespDia(); }); - $('#rmcEventDiv').append(mkCondRespBut); + buttons.append(mkCondRespBut); - var startCondRespBut = createButton('Start Association'); + var startCondRespBut = createButton('Start/Stop Association'); startCondRespBut.bind('click', function(){ - startCondRespDia(); + startStopCondRespDia(); }); - $('#rmcEventDiv').append(startCondRespBut); + buttons.append(startCondRespBut); - var stopCondRespBut = createButton('Stop Association'); - stopCondRespBut.bind('click', function(){ - stopCondRespDia(); - }); - $('#rmcEventDiv').append(stopCondRespBut); + $('#rmcEventDiv').append(buttons); } /** @@ -810,24 +813,23 @@ function loadRmcEventConfig(){ * */ function mkCondRespDia(){ - var diaDiv = $('
'); - - //2 fieldset conditions, response - diaDiv.append('
Predefined Condition
'); - diaDiv.append('
ResponsePlase select condition first.
'); - diaDiv.append('