CLOUDSTACK-7731: UI > Infrastructure > Virtual Routers > group by XXXXXXX view 
> listView > detailView > add View All link > not show "group by XXXXXXX" in 
select view dropdown.


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

Branch: refs/heads/baremetal-systemvm
Commit: 7004deb528657c7e5403118926836b7fd19717c0
Parents: a3eaff8
Author: Jessica Wang <[email protected]>
Authored: Wed Oct 15 17:02:21 2014 -0700
Committer: Jessica Wang <[email protected]>
Committed: Thu Oct 16 12:34:55 2014 -0700

----------------------------------------------------------------------
 ui/scripts/system.js | 11 ++++++++++-
 1 file changed, 10 insertions(+), 1 deletion(-)
----------------------------------------------------------------------


http://git-wip-us.apache.org/repos/asf/cloudstack/blob/7004deb5/ui/scripts/system.js
----------------------------------------------------------------------
diff --git a/ui/scripts/system.js b/ui/scripts/system.js
index f87de62..ef4d7c1 100644
--- a/ui/scripts/system.js
+++ b/ui/scripts/system.js
@@ -9391,7 +9391,16 @@
         subsections: {
             virtualRouters: {
                 sectionSelect: {
-                    label: 'label.select-view'
+                    label: 'label.select-view',
+                    preFilter: function(args) {                        
+                       //Only clicking ViewAll Link("view all Virtual 
Routers") in "Virtual Routers group by XXXXXXX" detailView will have 
"routerGroupByXXXXXXX" included in args.context
+                        if (("routerGroupByZone" in args.context) || 
("routerGroupByPod" in args.context) || ("routerGroupByCluster" in 
args.context) || ("routerGroupByAccount" in args.context)) {
+                               return ["routerNoGroup"];
+                        }
+                        else {
+                               return ["routerNoGroup", "routerGroupByZone", 
"routerGroupByPod", "routerGroupByCluster", "routerGroupByAccount"];
+                        }
+                    }
                 },
                 sections: {
                     routerNoGroup: {

Reply via email to