Change in ovirt-engine[master]: webadmin: Fix server-side sort issue

Vojtech Szocs has submitted this change and it was merged. Change subject: webadmin: Fix server-side sort issue ...................................................................... webadmin: Fix server-side sort issue This patch fixes an issue where triggering server-side sorting on a given column (via mouse click on sortable column header) might corrupt the actual search query dispatched by the model. - UI search string contains syntax error(s) - UI search string contains SORTBY syntax object If any of above holds true, sorting should be cleared across all columns of the given table - all columns should appear as not sorted. After applying this patch, following behavior is enforced: a, assume there is NO sorting applied on the given table, user triggers server-side sorting on a given column: a1, if the UI search string is 'valid' (no syntax errors, no SORTBY present), append SORTBY to the search string when dispatching actual search query (without updating UI search string) and execute refresh to fetch items a2, otherwise, clear sorting on given table - all columns should appear as not sorted b, assume the given table is sorted on a given column, user enters new UI search string and applies it via Search icon (or by pressing Enter key): b1, if the UI search string is NOT 'valid' (syntax errors and/or SORTBY present), clear sorting on given table - all columns should appear as not sorted b2, otherwise, proceed with applying sorting on the given column Change-Id: I7ce39a4e2b6323e6e0276a3a462a3f9da005344b Signed-off-by: Vojtech Szocs <vszocs@redhat.com> --- M backend/manager/modules/searchbackend/src/main/java/org/ovirt/engine/core/searchbackend/SyntaxChecker.java M frontend/webadmin/modules/gwt-common/src/main/java/org/ovirt/engine/ui/common/system/BaseApplicationInit.java M frontend/webadmin/modules/gwt-common/src/main/java/org/ovirt/engine/ui/common/widget/table/AbstractActionTable.java M frontend/webadmin/modules/uicommonweb/src/main/java/org/ovirt/engine/ui/uicommonweb/models/SearchableListModel.java M frontend/webadmin/modules/uicommonweb/src/main/java/org/ovirt/engine/ui/uicommonweb/models/autocomplete/SearchSuggestModel.java 5 files changed, 143 insertions(+), 43 deletions(-) Approvals: Vojtech Szocs: Verified; Looks good to me, approved -- To view, visit http://gerrit.ovirt.org/28557 To unsubscribe, visit http://gerrit.ovirt.org/settings Gerrit-MessageType: merged Gerrit-Change-Id: I7ce39a4e2b6323e6e0276a3a462a3f9da005344b Gerrit-PatchSet: 6 Gerrit-Project: ovirt-engine Gerrit-Branch: master Gerrit-Owner: Vojtech Szocs <vszocs@redhat.com> Gerrit-Reviewer: Alexander Wels <awels@redhat.com> Gerrit-Reviewer: Daniel Erez <derez@redhat.com> Gerrit-Reviewer: Einav Cohen <ecohen@redhat.com> Gerrit-Reviewer: Frank Kobzik <fkobzik@redhat.com> Gerrit-Reviewer: Lior Vernia <lvernia@redhat.com> Gerrit-Reviewer: Vojtech Szocs <vszocs@redhat.com> Gerrit-Reviewer: automation@ovirt.org Gerrit-Reviewer: oVirt Jenkins CI Server
participants (1)
-
vszocs@redhat.com