diff --git a/app/controllers/competitions/competitions_controller.rb b/app/controllers/competitions/competitions_controller.rb index 2c3d00529..18e5bb371 100644 --- a/app/controllers/competitions/competitions_controller.rb +++ b/app/controllers/competitions/competitions_controller.rb @@ -30,6 +30,8 @@ class Competitions::CompetitionsController < Competitions::BaseController def show @competition = current_competition + + current_competition.increment(:visits) end def update diff --git a/app/controllers/polls_controller.rb b/app/controllers/polls_controller.rb index 039d5e5c8..2504b8eb8 100644 --- a/app/controllers/polls_controller.rb +++ b/app/controllers/polls_controller.rb @@ -1436,7 +1436,7 @@ class PollsController < ApplicationController if poll_un_anony user_login = u_user.login user_name = u_user.real_name.present? ? u_user.real_name : "--" - user_class = poll.course.user_group_name + user_class = poll.course.user_group_name(u_user.id) user_student_id = u_user.student_id.present? ? u_user.student_id : "--" user_school_name = u_user.school_name.present? ? u_user.school_name : "--" user_cell += [user_login,user_name, user_class, u_user.mail, user_student_id, user_school_name]