18F/confidential-survey

View on GitHub
app/models/intersection.rb

Summary

Maintainability
A
0 mins
Test Coverage
# A model to represent intersection results of choices between several questions
class Intersection < Struct.new(:survey, :keys)
  def tally_key
    keys.join('|')
  end

  def survey_id
    survey.id
  end
end