Permalink
Browse files

finally ordering I like

  • Loading branch information...
1 parent a96fc7f commit 9a2b2c7d3f143e42f2a0dfcb82ec41f15a05b74e @rdp committed Apr 17, 2012
Showing with 9 additions and 1 deletion.
  1. +9 −1 app/models/product.rb
View
@@ -276,7 +276,15 @@ def linkable_tags user
if user
tags # all :)
else
- tags.select{|t| !t.is_hymn_tag?}.reject{|t| (t.child_ids - self.tag_ids) != t.child_ids}.reject{|t| t.is_original_tag?}.sort_by{|t| t.is_composer_tag? ? 1 : t.is_topic_tag? ? 3 : 2}
+ tags.select{|t| !t.is_hymn_tag?}.reject{|t| (t.child_ids - self.tag_ids) != t.child_ids}.reject{|t| t.is_original_tag?}.sort_by{|t|
+ if t.is_voicing?
+ 1
+ elsif t.is_composer_tag?
+ 2
+ else
+ 3
+ end
+ }
end
end

0 comments on commit 9a2b2c7

Please sign in to comment.