[Kimchi-devel] [PATCH 3/5] More Granular Task Queries: UI

Christy Perez christy at linux.vnet.ibm.com
Wed Feb 25 16:20:53 UTC 2015


Add the 'clone' filter to the Cloning tasks API URL so that
when vm-creation is also a running task, only Cloning VMs will
be returned.

Signed-off-by: Christy Perez <christy at linux.vnet.ibm.com>
---
 ui/js/src/kimchi.guest_main.js | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

diff --git a/ui/js/src/kimchi.guest_main.js b/ui/js/src/kimchi.guest_main.js
index 21caf1b..e31b332 100644
--- a/ui/js/src/kimchi.guest_main.js
+++ b/ui/js/src/kimchi.guest_main.js
@@ -203,7 +203,7 @@ kimchi.listVmsAuto = function() {
     }
     var getCloningGuests = function(){
         var guests = [];
-        kimchi.getTasksByFilter('status=running&target_uri='+encodeURIComponent('^/vms/*'), function(tasks) {
+        kimchi.getTasksByFilter('status=running&description=clone&target_uri='+encodeURIComponent('^/vms/*'), function(tasks) {
             for(var i=0;i<tasks.length;i++){
                 var guestUri = tasks[i].target_uri;
                 var guestName = guestUri.substring(guestUri.lastIndexOf('/')+1, guestUri.length);
-- 
2.1.0




More information about the Kimchi-devel mailing list