Ramesh N has uploaded a new change for review.

Change subject: webadmin: disable actions in remove brick status pop up after 
retain/commit
......................................................................

webadmin: disable actions in remove brick status pop up after retain/commit

  Disable actions in remove brick status pop up after remove
brick retain/commit is executed.

Change-Id: I2bb9350827e5a288e19e1990a60f67850ae9b290
Bug-Url: https://bugzilla.redhat.com/1029478
Signed-off-by: Ramesh Nachimuthu <rnach...@redhat.com>
---
M 
frontend/webadmin/modules/uicommonweb/src/main/java/org/ovirt/engine/ui/uicommonweb/models/gluster/VolumeBrickListModel.java
1 file changed, 14 insertions(+), 0 deletions(-)


  git pull ssh://gerrit.ovirt.org:29418/ovirt-engine refs/changes/42/21742/1

diff --git 
a/frontend/webadmin/modules/uicommonweb/src/main/java/org/ovirt/engine/ui/uicommonweb/models/gluster/VolumeBrickListModel.java
 
b/frontend/webadmin/modules/uicommonweb/src/main/java/org/ovirt/engine/ui/uicommonweb/models/gluster/VolumeBrickListModel.java
index f138088..ae7f50c 100644
--- 
a/frontend/webadmin/modules/uicommonweb/src/main/java/org/ovirt/engine/ui/uicommonweb/models/gluster/VolumeBrickListModel.java
+++ 
b/frontend/webadmin/modules/uicommonweb/src/main/java/org/ovirt/engine/ui/uicommonweb/models/gluster/VolumeBrickListModel.java
@@ -953,6 +953,9 @@
                         ConfirmationModel localModel = (ConfirmationModel) 
result.getState();
                         localModel.stopProgress();
                         setConfirmWindow(null);
+                        if (result.getReturnValue().getSucceeded()) {
+                            disableRemoveBrickStatusPopUpActions();
+                        }
                     }
                 },
                 model);
@@ -1116,11 +1119,22 @@
                         ConfirmationModel localModel = (ConfirmationModel) 
result.getState();
                         localModel.stopProgress();
                         setConfirmWindow(null);
+                        if (result.getReturnValue().getSucceeded()) {
+                            disableRemoveBrickStatusPopUpActions();
+                        }
                     }
                 },
                 model);
     }
 
+    private void disableRemoveBrickStatusPopUpActions() {
+        if (getWindow() != null && getWindow() instanceof 
RemoveBrickStatusModel) {
+            RemoveBrickStatusModel statusModel = (RemoveBrickStatusModel) 
getWindow();
+            
statusModel.getCommitRemoveBricksCommand().setIsExecutionAllowed(false);
+            statusModel.getRetainBricksCommand().setIsExecutionAllowed(false);
+            
statusModel.getStopRemoveBricksCommand().setIsExecutionAllowed(false);
+        }
+    }
     private void replaceBrick()
     {
         if (getWindow() != null)


-- 
To view, visit http://gerrit.ovirt.org/21742
To unsubscribe, visit http://gerrit.ovirt.org/settings

Gerrit-MessageType: newchange
Gerrit-Change-Id: I2bb9350827e5a288e19e1990a60f67850ae9b290
Gerrit-PatchSet: 1
Gerrit-Project: ovirt-engine
Gerrit-Branch: master
Gerrit-Owner: Ramesh N <rnach...@redhat.com>
_______________________________________________
Engine-patches mailing list
Engine-patches@ovirt.org
http://lists.ovirt.org/mailman/listinfo/engine-patches

Reply via email to