class REDCap::Form::Checkboxes
Public Instance Methods
value(responses)
click to toggle source
# File lib/red_cap/form/fields.rb, line 100 def value responses selected_options(responses).values end
Private Instance Methods
selected_options(responses)
click to toggle source
# File lib/red_cap/form/fields.rb, line 106 def selected_options responses options.select do |key, value| responses["#{field_name}___#{key}"] == "1" end end