Replace submitter with speakers in reports#index

Also, in events#show and proposals#index

It is more relevant to check if the speakers have registered to the
conference and filled their biographies than the submitter, because,
there can be multiple speakers and the submitter isn't necessarily one
of them

And, remove admin/events/reports.html.haml, since, it isn't used anymore

Fix #1477, fix #1479
This commit is contained in:
AEtherC0r3 2017-05-09 00:14:05 +03:00 committed by Stella Rouzi
parent 4a026c9dde
commit 36b8088726
5 changed files with 24 additions and 141 deletions

View file

@ -214,9 +214,9 @@ class Event < ActiveRecord::Base
# Returns +Hash+
def progress_status
{
registered: program.conference.user_registered?(submitter),
registered: speakers.all? { |speaker| program.conference.user_registered? speaker },
commercials: commercials.any?,
biography: !submitter.biography.blank?,
biographies: speakers.all? { |speaker| !speaker.biography.blank? },
subtitle: !subtitle.blank?,
track: (!track.blank? unless program.tracks.empty?),
difficulty_level: !difficulty_level.blank?,