cloudstack-commits mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From jessicaw...@apache.org
Subject git commit: updated refs/heads/master to a39bf18
Date Wed, 10 Sep 2014 22:36:13 GMT
Repository: cloudstack
Updated Branches:
  refs/heads/master 7a555b398 -> a39bf18bc


CLOUDSTACK-7462: UI > Network > VPC > Router > Network ACL Lists > click an
entry from list > Details tab > ACL List Rules tab > click Edit icon on any existing
rule > fix the JavaScript error "args.jsonObj is undefined".


Project: http://git-wip-us.apache.org/repos/asf/cloudstack/repo
Commit: http://git-wip-us.apache.org/repos/asf/cloudstack/commit/a39bf18b
Tree: http://git-wip-us.apache.org/repos/asf/cloudstack/tree/a39bf18b
Diff: http://git-wip-us.apache.org/repos/asf/cloudstack/diff/a39bf18b

Branch: refs/heads/master
Commit: a39bf18bc7eb3c55286ed74aa473e32cbe980ec8
Parents: 7a555b3
Author: Jessica Wang <jessicawang@apache.org>
Authored: Wed Sep 10 15:35:53 2014 -0700
Committer: Jessica Wang <jessicawang@apache.org>
Committed: Wed Sep 10 15:35:53 2014 -0700

----------------------------------------------------------------------
 ui/scripts/sharedFunctions.js | 66 +++++++++++++++++++-------------------
 1 file changed, 33 insertions(+), 33 deletions(-)
----------------------------------------------------------------------


http://git-wip-us.apache.org/repos/asf/cloudstack/blob/a39bf18b/ui/scripts/sharedFunctions.js
----------------------------------------------------------------------
diff --git a/ui/scripts/sharedFunctions.js b/ui/scripts/sharedFunctions.js
index bb2d596..41f5d3a 100644
--- a/ui/scripts/sharedFunctions.js
+++ b/ui/scripts/sharedFunctions.js
@@ -2173,42 +2173,42 @@ cloudStack.api = {
                 }
             },
             dataProvider: function(args) {
-            	args.response.success({
-                    data: args.jsonObj.tags
-                });
-            	
-            	/*
-                var resourceId = args.context[contextId][0].id;
-                var data = {
-                    resourceId: resourceId,
-                    resourceType: resourceType
-                };
-
-                if (isAdmin() || isDomainAdmin()) {
-                    data.listAll = true;
-                }
-
-                if (args.context.projects) {
-                    data.projectid = args.context.projects[0].id;
-                }
+            	if (args.jsonObj != undefined) {
+	            	args.response.success({
+	                    data: args.jsonObj.tags
+	                });
+            	} else {
+            		var resourceId = args.context[contextId][0].id;
+                    var data = {
+                        resourceId: resourceId,
+                        resourceType: resourceType
+                    };
+
+                    if (isAdmin() || isDomainAdmin()) {
+                        data.listAll = true;
+                    }
 
-                if (args.jsonObj != null && args.jsonObj.projectid != null &&
data.projectid == null) {
-                    data.projectid = args.jsonObj.projectid;
-                }
+                    if (args.context.projects) {
+                        data.projectid = args.context.projects[0].id;
+                    }
 
-                $.ajax({
-                    url: createURL('listTags'),
-                    data: data,
-                    success: function(json) {
-                        args.response.success({
-                            data: json.listtagsresponse ? json.listtagsresponse.tag : []
-                        });
-                    },
-                    error: function(json) {
-                        args.response.error(parseXMLHttpResponse(json));
+                    if (args.jsonObj != null && args.jsonObj.projectid != null &&
data.projectid == null) {
+                        data.projectid = args.jsonObj.projectid;
                     }
-                });
-                */
+
+                    $.ajax({
+                        url: createURL('listTags'),
+                        data: data,
+                        success: function(json) {
+                            args.response.success({
+                                data: json.listtagsresponse ? json.listtagsresponse.tag :
[]
+                            });
+                        },
+                        error: function(json) {
+                            args.response.error(parseXMLHttpResponse(json));
+                        }
+                    });
+            	}            	
             }
         };
     }


Mime
View raw message