diff --git a/app/views/posts/_post.html.erb b/app/views/posts/_post.html.erb index c4806ef..7d92f74 100644 --- a/app/views/posts/_post.html.erb +++ b/app/views/posts/_post.html.erb @@ -13,6 +13,23 @@ <% end %>
+ <% if post.user.groups.count > 0 %> +
+ <% if post.user.admin?%> +
<%= namelink Group.find(Group::ADMINS) %>
+
<%= post.user.groupers.where(:group_id => Group::ADMINS).first.task %>
+ <% elsif post.user.caster?%> +
<%= namelink Group.find(Group::CASTERS) %>
+
<%= post.user.groupers.where(:group_id => Group::CASTERS).first.task %>
+ <% elsif post.user.ref?%> +
<%= namelink Group.find(Group::REFEREES) %>
+
<%= post.user.groupers.where(:group_id => Group::REFEREES).first.task %>
+ <% else %> +
<%= namelink Group.find(post.user.groupers.first.group_id) %>
+
<%= post.user.groupers.first.task %>
+ <% end %> + + <% end %>
Posts
<%= post.user.posts.count %>
Location