From: Jan Provaznik <[email protected]>

---
 src/app/views/templates/_groups.haml  |    6 +++---
 src/app/views/templates/software.haml |   10 ++++++----
 2 files changed, 9 insertions(+), 7 deletions(-)

diff --git a/src/app/views/templates/_groups.haml 
b/src/app/views/templates/_groups.haml
index 21fce86..5a4ae07 100644
--- a/src/app/views/templates/_groups.haml
+++ b/src/app/views/templates/_groups.haml
@@ -1,8 +1,8 @@
 %ul{:class => 'groups_to_select selection_list'}
   - @groups.keys.sort.each do |group|
-    %li
-      - pkgs = @groups[group][:packages].keys.join("','")
-      = group
+    %li{:class => 'group'}
+      %span{:class => "groupname"}
+        = group
       %a{:class => 'select_group action_link', :href => url_for(:action => 
'select_group', :id => params[:id], :group => group)}
         Select
       %ul{:class => 'groupkgs'}
diff --git a/src/app/views/templates/software.haml 
b/src/app/views/templates/software.haml
index 998ce9b..02e3220 100644
--- a/src/app/views/templates/software.haml
+++ b/src/app/views/templates/software.haml
@@ -16,6 +16,7 @@
             $("#selected_packages").load($(ev.target).attr('href'), 
loadCallback);
             return false;
           });
+          createTree('.groups_to_select');
         }
       });
       // when JS is enabled, hide the Dashboard content -- it'll be loaded
@@ -28,10 +29,11 @@
         $("#selected_packages").load($(ev.target).attr('href'), loadCallback);
         return false;
       });
-      createTree();
+      createTree('#selected_packages');
     };
-    function createTree() {
-      $("li.group").each(function() {
+    function createTree(tree_selector) {
+      var tree = $(tree_selector);
+      $("li.group", tree).each(function() {
         var group = $(this);
         group.addClass("closed_folder");
         $(".groupname", group).toggle(
@@ -46,7 +48,7 @@
           }
         );
       })
-      $("li.group > ul > li").addClass("hidden");
+      $("li.group > ul > li", tree).addClass("hidden");
     };
     function get_repository(ev) {
       var rep = $(ev.target).val();
-- 
1.7.0.1

_______________________________________________
deltacloud-devel mailing list
[email protected]
https://fedorahosted.org/mailman/listinfo/deltacloud-devel

Reply via email to