BikeBikeBike/app/views/conferences/stats.html.haml

64 lines
2.2 KiB
Plaintext
Raw Normal View History

2015-08-21 19:29:43 -07:00
= render 'page_header', :page_key => 'Registration_Stats'
%article
= row do
= columns(medium: 12) do
%h2=_'articles.conference_registration.headings.Stats'
%p=_'articles.conference_registration.paragraphs.Stats', :p
2015-09-13 14:06:46 -07:00
= link_to (_'links.download.Excel','Download Data in Excel Format'), stats_path(@this_conference.slug, :format => :xls), {:class => :button}
2015-08-21 19:29:43 -07:00
= columns(medium: 6) do
%ul.stats
%li
%h3=_'articles.conference_registration.terms.Total_Registrations'
.stat.important=_!@total_registrations
%li.money
%h3=_'articles.conference_registration.terms.Total_Donations'
.stat=money @total_donations
%li
%h3=_'articles.conference_registration.terms.Donation_Count'
.stat
= _!"#{@donation_count} / #{@total_registrations}"
%li
%h3=_'articles.conference_registration.terms.Housing'
.breakdown
- @housing.each do |h, v|
- unless h == :none
.stat-with-label
.label=_"articles.conference_registration.questions.housing.#{h}"
.stat=_!v
%li
%h3=_'articles.conference_registration.terms.Bikes'
.breakdown
.stat=_!"#{@bike_count} / #{@total_registrations}"
- @bikes.each do |h, v|
- unless h == :none
.stat-with-label
2015-09-01 21:54:53 -07:00
.label=_"articles.conference_registration.questions.bike.#{h}"
2015-08-21 19:29:43 -07:00
.stat.percent=_!percent(v.to_f / @bike_count)
%li
%h3=_'articles.conference_registration.terms.Food'
.breakdown
- @food.each do |h, v|
.stat-with-label
.label=_"articles.conference_registration.questions.food.#{h}"
.stat.percent=_!percent(v.to_f / @total_registrations)
%li
%h3=_'articles.conference_registration.terms.Languages'
.breakdown
- @languages.each do |h, v|
.stat-with-label
.label=_"languages.#{h}"
.stat.percent=_!percent(v.to_f / @total_registrations)
= columns(medium: 6) do
.allergies
%h3=_'articles.conference_registration.headings.Allergies'
%ul
- @allergies.each do |a|
%li
%p=_!a
.other
%h3=_'articles.conference_registration.headings.other'
%ul
- @other.each do |o|
%li
%p=_!o