Commit 8b0f4c995292031d00a4101cc246ee5c46c2ec62

Authored by Beatriz Rezener
Committed by Heitor
1 parent 482e66d7

Listing the packages before classes #90

Showing 1 changed file with 3 additions and 1 deletions   Show diff stats
app/views/modules/_module_tree.html.erb
@@ -15,7 +15,9 @@ @@ -15,7 +15,9 @@
15 <% end %> 15 <% end %>
16 16
17 <% cache("#{@root_module_result.id}_tree") do %> 17 <% cache("#{@root_module_result.id}_tree") do %>
18 - <% children = @root_module_result.children %> 18 + <% children = @root_module_result.children.sort do %>
  19 + <% |a,b| (a.module.granularity == b.module.granularity) ? a.module.name <=> b.module.name : -a.module.granularity.length <=> -b.module.granularity.length %>
  20 + <% end %>
19 <% unless children.empty? %> 21 <% unless children.empty? %>
20 <table class="table table-hover"> 22 <table class="table table-hover">
21 <thead> 23 <thead>