diff --git a/app/views/competitions/_team_list.html.erb b/app/views/competitions/_team_list.html.erb index 3800248c..4c424bc0 100644 --- a/app/views/competitions/_team_list.html.erb +++ b/app/views/competitions/_team_list.html.erb @@ -19,10 +19,10 @@ <% team.teachers.each do |teacher| %> <%= link_to image_tag(url_to_avatar(teacher.user), width: 26, height: 26, class: 'radius fl mr4'), user_path(teacher.user), class: 'fl', target: '_blank', data: { 'tip-down' => "指导老师:#{teacher.user.show_name}" } %> <% end %> - <% team.members.each do |member| %> + <% team.members[0, 8].each do |member| %> <%= link_to image_tag(url_to_avatar(member.user), :width => "20", :height => "20", :class => "radius fl mr4 mt3"), user_path(member.user), :title => member.user.show_name, :target => "_blank", :class => "fl", :alt => "用户头像" %> <% end %> - <% if team.members.size > 8 %> + <% if team.members.size > 9 %> ... <% end %> diff --git a/app/views/competitions/enroll.html.erb b/app/views/competitions/enroll.html.erb index ee439267..449d71c9 100644 --- a/app/views/competitions/enroll.html.erb +++ b/app/views/competitions/enroll.html.erb @@ -79,7 +79,7 @@ <% team.team_members.where("user_id != #{team.teacher_id.present? ? team.teacher_id : '-1'}")[0, 8].each do |member| %> <%= link_to image_tag(url_to_avatar(member.user), :width => "20", :height => "20", :class => "radius fl mr5 mt3"), user_path(member.user), :title => member.user.show_name, :target => "_blank", :class => "fl", :alt => "用户头像" %> <% end %> - <% if team.team_members.size > 8 %> + <% if team.team_members.size > 9 %> <% end %>