Frank Kobzik has uploaded a new change for review. Change subject: core: Allow VM sorting according to missing fields ......................................................................
core: Allow VM sorting according to missing fields This patch makes it possible to sort search results according to assigned and running pool pools count. This enhancement was needed as we also want to sort by these fields in the ui. Change-Id: Ia2e03d31e7bc67f750dcccfe0b57401f4630b13c Signed-off-by: Frantisek Kobzik <[email protected]> Bug-Url: https://bugzilla.redhat.com/1104790 --- M backend/manager/modules/searchbackend/src/main/java/org/ovirt/engine/core/searchbackend/PoolConditionFieldAutoCompleter.java 1 file changed, 8 insertions(+), 0 deletions(-) git pull ssh://gerrit.ovirt.org:29418/ovirt-engine refs/changes/74/28374/1 diff --git a/backend/manager/modules/searchbackend/src/main/java/org/ovirt/engine/core/searchbackend/PoolConditionFieldAutoCompleter.java b/backend/manager/modules/searchbackend/src/main/java/org/ovirt/engine/core/searchbackend/PoolConditionFieldAutoCompleter.java index 0184de2..2d1ecbd 100644 --- a/backend/manager/modules/searchbackend/src/main/java/org/ovirt/engine/core/searchbackend/PoolConditionFieldAutoCompleter.java +++ b/backend/manager/modules/searchbackend/src/main/java/org/ovirt/engine/core/searchbackend/PoolConditionFieldAutoCompleter.java @@ -11,6 +11,8 @@ public static final String CLUSTER = "CLUSTER"; public static final String DATACENTER = "DATACENTER"; public static final String ARCHITECTURE = "ARCHITECTURE"; + public static final String ASSIGNED_VM_COUNT = "ASSIGNED_VM_COUNT"; + public static final String RUNNING_VM_COUNT = "RUNNING_VM_COUNT"; public PoolConditionFieldAutoCompleter() { // Building the basic vervs Dict @@ -20,6 +22,8 @@ mVerbs.add(CLUSTER); mVerbs.add(DATACENTER); mVerbs.add(ARCHITECTURE); + mVerbs.add(ASSIGNED_VM_COUNT); + mVerbs.add(RUNNING_VM_COUNT); // Building the autoCompletion Dict buildCompletions(); @@ -30,6 +34,8 @@ getTypeDictionary().put(CLUSTER, String.class); getTypeDictionary().put(DATACENTER, String.class); getTypeDictionary().put(ARCHITECTURE, ArchitectureType.class); + getTypeDictionary().put(ASSIGNED_VM_COUNT, Integer.class); + getTypeDictionary().put(RUNNING_VM_COUNT, Integer.class); // building the ColumnName Dict columnNameDict.put(NAME, "vm_pool_name"); @@ -38,6 +44,8 @@ columnNameDict.put(CLUSTER, "vds_group_name"); columnNameDict.put(DATACENTER, "storage_pool_name"); columnNameDict.put(ARCHITECTURE, "architecture"); + columnNameDict.put(ASSIGNED_VM_COUNT, "assigned_vm_count"); + columnNameDict.put(RUNNING_VM_COUNT, "vm_running_count"); // Building the validation dict buildBasicValidationTable(); -- To view, visit http://gerrit.ovirt.org/28374 To unsubscribe, visit http://gerrit.ovirt.org/settings Gerrit-MessageType: newchange Gerrit-Change-Id: Ia2e03d31e7bc67f750dcccfe0b57401f4630b13c Gerrit-PatchSet: 1 Gerrit-Project: ovirt-engine Gerrit-Branch: master Gerrit-Owner: Frank Kobzik <[email protected]> _______________________________________________ Engine-patches mailing list [email protected] http://lists.ovirt.org/mailman/listinfo/engine-patches
