Yevgeny Zaspitsky has posted comments on this change.

Change subject: webadmin: Add managemenet network field to new/edit cluster 
dialog
......................................................................


Patch Set 24:

(2 comments)

http://gerrit.ovirt.org/#/c/37141/24/frontend/webadmin/modules/uicommonweb/src/main/java/org/ovirt/engine/ui/uicommonweb/models/clusters/ClusterModel.java
File 
frontend/webadmin/modules/uicommonweb/src/main/java/org/ovirt/engine/ui/uicommonweb/models/clusters/ClusterModel.java:

Line 1397:                 
clusterModel.getManagementNetwork().setItems(dcNetworks);
Line 1398: 
Line 1399:                 if 
(defaultManagementNetworkCache.containsKey(dataCenterId)) {
Line 1400:                     clusterModel.getManagementNetwork()
Line 1401:                             
.setSelectedItem(defaultManagementNetworkCache.get(dataCenterId));
> Here you only want to set the selected item if the default network isn't nu
Done
Line 1402:                 } else {
Line 1403:                     final AsyncQuery 
getDefaultManagementNetworkQuery =
Line 1404:                             new AsyncQuery(clusterModel, new 
INewAsyncCallback() {
Line 1405:                                 @Override


Line 1405:                                 @Override
Line 1406:                                 public void onSuccess(Object model, 
Object returnValue) {
Line 1407:                                     Network defaultManagementNetwork 
= (Network) returnValue;
Line 1408:                                     
defaultManagementNetworkCache.put(dataCenterId, defaultManagementNetwork);
Line 1409:                                     
clusterModel.getManagementNetwork().setSelectedItem(defaultManagementNetwork);
> Same here - so I would extract to a method fetching the network from the ma
Done
Line 1410:                                 }
Line 1411:                             });
Line 1412:                     AsyncDataProvider.getInstance()
Line 1413:                             
.getDefaultManagementNetwork(getDefaultManagementNetworkQuery, dataCenterId);


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

Gerrit-MessageType: comment
Gerrit-Change-Id: I055babd6037f127235c349499f1545396e38333f
Gerrit-PatchSet: 24
Gerrit-Project: ovirt-engine
Gerrit-Branch: master
Gerrit-Owner: Yevgeny Zaspitsky <[email protected]>
Gerrit-Reviewer: Lior Vernia <[email protected]>
Gerrit-Reviewer: Oved Ourfali <[email protected]>
Gerrit-Reviewer: Yevgeny Zaspitsky <[email protected]>
Gerrit-Reviewer: [email protected]
Gerrit-Reviewer: oVirt Jenkins CI Server
Gerrit-HasComments: Yes
_______________________________________________
Engine-patches mailing list
[email protected]
http://lists.ovirt.org/mailman/listinfo/engine-patches

Reply via email to