A
<% case sq.type %>
<% when SurveyQuestion::Radio, SurveyQuestion::Select %>
<%= SurveysHelper.parse_value(@survey_answer[sq.id.to_s]) %>
<% when SurveyQuestion::Check %>
<% puts sq.id %>
<%= SurveysHelper.parse_checkbox_value_html(@survey_answer[sq.id.to_s]) %>
<% when SurveyQuestion::Radiogroup %>
<% sq.survey_question_options.each do |sqo| %>
<% if !@survey_answer[sq.id.to_s].nil? %>
<% if sq.custom_option_each_option %>
<%= @survey_answer[sq.id.to_s]["#{sqo.id}_custom_group_field"].blank? ? sqo.name : @survey_answer[sq.id.to_s]["#{sqo.id}_custom_group_field"] %> :
<% else %>
<%= sqo.name %> :
<% end %>
<%= SurveysHelper.parse_value(@survey_answer[sq.id.to_s][sqo.id.to_s]) %>
<% end %>
<% end %>
<% if sq.custom_option_new_option %>
<%= sq.custom_option_title %> <%= @survey_answer[sq.id.to_s]['custom_option'] %>
<% end %>
<% when SurveyQuestion::Oneline, SurveyQuestion::Multiline %>
<%= @survey_answer[sq.id.to_s] rescue "" %>
<% when SurveyQuestion::DoubleLevelOption %>
<%= @survey_answer[sq.id.to_s].collect{|v| SurveysHelper.parse_double_level_value(v,sq.custom_option_title.to_s)}.join('
').html_safe %>
<% end %>