Maor Lipchuk has uploaded a new change for review.

Change subject: webadmin: Validate existing storage paths per Data Center.
......................................................................

webadmin: Validate existing storage paths per Data Center.

When importing a NFS Storage Domain the GUI validate whether the path is
already exists in the DB.
The validation should be per Data Center, since for local Data Center we
can use the same path for different Data Centers.

Change-Id: I066461fdad22fc8aa7b42a5bcc508f5a7dd8d0bd
Bug-Url: https://bugzilla.redhat.com/1212397
Signed-off-by: Maor Lipchuk <mlipc...@redhat.com>
---
M 
frontend/webadmin/modules/uicommonweb/src/main/java/org/ovirt/engine/ui/uicommonweb/models/storage/StorageListModel.java
1 file changed, 7 insertions(+), 1 deletion(-)


  git pull ssh://gerrit.ovirt.org:29418/ovirt-engine refs/changes/67/39967/1

diff --git 
a/frontend/webadmin/modules/uicommonweb/src/main/java/org/ovirt/engine/ui/uicommonweb/models/storage/StorageListModel.java
 
b/frontend/webadmin/modules/uicommonweb/src/main/java/org/ovirt/engine/ui/uicommonweb/models/storage/StorageListModel.java
index 5ccd39d..3cc8b80 100644
--- 
a/frontend/webadmin/modules/uicommonweb/src/main/java/org/ovirt/engine/ui/uicommonweb/models/storage/StorageListModel.java
+++ 
b/frontend/webadmin/modules/uicommonweb/src/main/java/org/ovirt/engine/ui/uicommonweb/models/storage/StorageListModel.java
@@ -2034,6 +2034,12 @@
 
     public void importFileStoragePostInit()
     {
+        Guid storagePoolId = null;
+        StoragePool dataCenter = 
storageModel.getContainer().getDataCenter().getSelectedItem();
+        if (dataCenter != null && !dataCenter.getId().equals(Guid.Empty)) {
+            storagePoolId = dataCenter.getId();
+        }
+
         // Check storage domain existence
         AsyncDataProvider.getStorageDomainsByConnection(new AsyncQuery(this, 
new INewAsyncCallback() {
             @Override
@@ -2076,7 +2082,7 @@
                     importFileStorageConnect();
                 }
             }
-        }), null, path);
+        }), storagePoolId, path);
     }
 
     public void importFileStorageConnect() {


-- 
To view, visit https://gerrit.ovirt.org/39967
To unsubscribe, visit https://gerrit.ovirt.org/settings

Gerrit-MessageType: newchange
Gerrit-Change-Id: I066461fdad22fc8aa7b42a5bcc508f5a7dd8d0bd
Gerrit-PatchSet: 1
Gerrit-Project: ovirt-engine
Gerrit-Branch: ovirt-engine-3.5
Gerrit-Owner: Maor Lipchuk <mlipc...@redhat.com>
_______________________________________________
Engine-patches mailing list
Engine-patches@ovirt.org
http://lists.ovirt.org/mailman/listinfo/engine-patches

Reply via email to