From 14776a3d995fe5fe7fc7f4365ddc06453c50ae8d Mon Sep 17 00:00:00 2001 From: Petko Bordjukov Date: Sun, 9 Oct 2016 04:00:52 +0300 Subject: [PATCH] Show only unique conference participants --- app/models/conference.rb | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/app/models/conference.rb b/app/models/conference.rb index fb37fa9..05f0ad7 100644 --- a/app/models/conference.rb +++ b/app/models/conference.rb @@ -17,7 +17,7 @@ class Conference < ActiveRecord::Base has_many :volunteer_teams has_many :volunteers has_one :call_for_participation, dependent: :destroy - has_many :participants, class_name: 'User', through: :events + has_many :participants, -> { uniq }, class_name: 'User', through: :events has_many :participant_profiles, class_name: 'PersonalProfile' has_many :slots, through: :halls