Lior Vernia has posted comments on this change. Change subject: webadmin: call validation when creating/editing Provider URL for Network Provider ......................................................................
Patch Set 3: (1 comment) http://gerrit.ovirt.org/#/c/31330/3/frontend/webadmin/modules/uicommonweb/src/main/java/org/ovirt/engine/ui/uicommonweb/models/providers/ProviderModel.java File frontend/webadmin/modules/uicommonweb/src/main/java/org/ovirt/engine/ui/uicommonweb/models/providers/ProviderModel.java: Line 302: preSave(); Line 303: } Line 304: Line 305: private void onTest() { Line 306: if (!validate()) { I wouldn't validate all UI fields, as only a subset affects the result of the test: URL, username, password and tenant. So those validations could be extracted to a private method, used by both validate() and onTest(). Also, I don't see any special reason to divide this into onTest() and doTest(), it wouldn't be less readable to have this short if... return statement at the head of the single onTest() method. Line 307: return; Line 308: } Line 309: Line 310: doTest(); -- To view, visit http://gerrit.ovirt.org/31330 To unsubscribe, visit http://gerrit.ovirt.org/settings Gerrit-MessageType: comment Gerrit-Change-Id: I0b9e9a6b66d800c973334629fa34b3b5443290df Gerrit-PatchSet: 3 Gerrit-Project: ovirt-engine Gerrit-Branch: master Gerrit-Owner: Martin Mucha <mmu...@redhat.com> Gerrit-Reviewer: Lior Vernia <lver...@redhat.com> Gerrit-Reviewer: automat...@ovirt.org Gerrit-Reviewer: oVirt Jenkins CI Server Gerrit-HasComments: Yes _______________________________________________ Engine-patches mailing list Engine-patches@ovirt.org http://lists.ovirt.org/mailman/listinfo/engine-patches