Arik Hadas has uploaded a new change for review.

Change subject: webadmin: fix pool creation
......................................................................

webadmin: fix pool creation

This patch fixes pool creation which broke by the latest changes related
to graphic devices. We tried to add a value to the values collection of
a Map instead of adding it using Map#put method.

Change-Id: Iddfeeb01835de7116d91201a1f81b40f7a63fe2e
Signed-off-by: Arik Hadas <aha...@redhat.com>
---
M 
backend/manager/modules/common/src/main/java/org/ovirt/engine/core/common/action/AddVmPoolWithVmsParameters.java
M 
frontend/webadmin/modules/uicommonweb/src/main/java/org/ovirt/engine/ui/uicommonweb/models/pools/PoolListModel.java
2 files changed, 4 insertions(+), 1 deletion(-)


  git pull ssh://gerrit.ovirt.org:29418/ovirt-engine refs/changes/56/36356/1

diff --git 
a/backend/manager/modules/common/src/main/java/org/ovirt/engine/core/common/action/AddVmPoolWithVmsParameters.java
 
b/backend/manager/modules/common/src/main/java/org/ovirt/engine/core/common/action/AddVmPoolWithVmsParameters.java
index 72a78bc..2ee6dfd 100644
--- 
a/backend/manager/modules/common/src/main/java/org/ovirt/engine/core/common/action/AddVmPoolWithVmsParameters.java
+++ 
b/backend/manager/modules/common/src/main/java/org/ovirt/engine/core/common/action/AddVmPoolWithVmsParameters.java
@@ -111,4 +111,7 @@
         return graphicsDevices.values();
     }
 
+    public void addGraphicsDevice(GraphicsDevice graphicsDevice) {
+        graphicsDevices.put(graphicsDevice.getGraphicsType(), graphicsDevice);
+    }
 }
diff --git 
a/frontend/webadmin/modules/uicommonweb/src/main/java/org/ovirt/engine/ui/uicommonweb/models/pools/PoolListModel.java
 
b/frontend/webadmin/modules/uicommonweb/src/main/java/org/ovirt/engine/ui/uicommonweb/models/pools/PoolListModel.java
index d195b36..43afffb 100644
--- 
a/frontend/webadmin/modules/uicommonweb/src/main/java/org/ovirt/engine/ui/uicommonweb/models/pools/PoolListModel.java
+++ 
b/frontend/webadmin/modules/uicommonweb/src/main/java/org/ovirt/engine/ui/uicommonweb/models/pools/PoolListModel.java
@@ -526,7 +526,7 @@
 
         for (GraphicsType graphicsType : 
model.getGraphicsType().getSelectedItem().getBackingGraphicsType()) {
             GraphicsDevice d = new 
GraphicsDevice(graphicsType.getCorrespondingDeviceType());
-            params.getGraphicsDevices().add(d);
+            params.addGraphicsDevice(d);
         }
     }
 


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

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

Reply via email to