diff --git a/app/models/summary.rb b/app/models/summary.rb index 65fc8b3..a524e53 100644 --- a/app/models/summary.rb +++ b/app/models/summary.rb @@ -25,6 +25,10 @@ class Summary @ranking ||= Ranking.new(talk_ids: talk_ids).ranking end + def conflicts + @conflicts ||= ConflictsSummary.new(talk_ids: talk_ids).conflicts + end + private def least_conflicts_for_single_talk diff --git a/app/views/summaries/show.json.jbuilder b/app/views/summaries/show.json.jbuilder index 6f5ae26..9990e5d 100644 --- a/app/views/summaries/show.json.jbuilder +++ b/app/views/summaries/show.json.jbuilder @@ -1 +1 @@ -json.extract! @summary, :number_of_ballots, :most_conflicts, :least_conflicts, :ranking +json.extract! @summary, :number_of_ballots, :most_conflicts, :least_conflicts, :ranking, :conflicts