diff --git a/app/views/questions/_question.html.haml b/app/views/questions/_question.html.haml
index 10ad2895..55b486c4 100644
--- a/app/views/questions/_question.html.haml
+++ b/app/views/questions/_question.html.haml
@@ -24,15 +24,14 @@
.clearfix
- -#
.show-hide
%p
%span{class: 'toggle', data: {toggle: 'histogram-answers'}}= "Show Histogram".html_safe
|
%span{class: 'toggle', data: {toggle: 'raw'}}= "Show Raw Data".html_safe
- - if question.is_a?(Question) || question.is_a?(GroupedQuestion)
- .histogram-answers.hidden
- = render question
+ .histogram-answers.hidden
+ = render 'shared/histogram', data: aggregated_responses
- %p.raw.hidden= likerts.join(', ')
+ %p.raw.hidden
+ = aggregated_responses.responses.map(&:answer_index).join(', ')
diff --git a/app/views/shared/_histogram.html.haml b/app/views/shared/_histogram.html.haml
new file mode 100644
index 00000000..70a94878
--- /dev/null
+++ b/app/views/shared/_histogram.html.haml
@@ -0,0 +1,2 @@
+%p
+ =# data.inspect
diff --git a/lib/tasks/data.rake b/lib/tasks/data.rake
index 04d5d882..abe2d17c 100644
--- a/lib/tasks/data.rake
+++ b/lib/tasks/data.rake
@@ -196,7 +196,7 @@ namespace :data do
end
responded_at = Date.strptime(row['EndDate'], '%m/%d/%Y %H:%M:%S')
- recipient.attempts.create(question: question, answer_index: answer_index, responded_at: responded_at)
+ recipient.attempts.create(question: question, answer_index: answer_index + 1, responded_at: responded_at)
end
end
end