visual changes

This commit is contained in:
differentreality 2013-07-13 09:57:13 +03:00
parent c68126ab1f
commit ca8759bc10
3 changed files with 105 additions and 89 deletions

View file

@ -1,10 +1,14 @@
%h3 .row-fluid
.span12
%h3
Registered Registered
- if @registered - if @registered
= "(#{@registered})" = "(#{@registered})"
- if @attendees - if @attendees
= " - Attendees (#{@attendees})" = " - Attendees (#{@attendees})"
%table.table.table-bordered.table-striped .row-fluid
.span3
%table.table.table-bordered.table-striped
%thead %thead
%th General Stats %th General Stats
%th # %th #
@ -21,13 +25,14 @@
%td Registred to attend with partner %td Registred to attend with partner
%td= @registered_with_partner %td= @registered_with_partner
%tr %tr
%td Handicapped Access for: %td Handicapped Access for
%td= @conference.registrations.where("handicapped_access_required = ?", true).count %td= @conference.registrations.where("handicapped_access_required = ?", true).count
%tr %tr
%td Staying at suggested hotel: %td Staying at suggested hotel
%td= @conference.registrations.where("using_affiliated_lodging = ?", true).count %td= @conference.registrations.where("using_affiliated_lodging = ?", true).count
- if @conference.use_dietary_choices == true .span3
- if @conference.use_dietary_choices == true
- diet_choices = [] - diet_choices = []
- @conference.dietary_choices.each do |d| - @conference.dietary_choices.each do |d|
- count = @conference.registrations.where("dietary_choice_id = ?", d.id).count - count = @conference.registrations.where("dietary_choice_id = ?", d.id).count
@ -49,8 +54,8 @@
- if @attendees and @attendees > 0 - if @attendees and @attendees > 0
%br %br
= "#{d[1] * 100 / @attendees}% of attendees" = "#{d[1] * 100 / @attendees}% of attendees"
.span3
- if @conference.social_events.count > 0 - if @conference.social_events.count > 0
- social_events = [] - social_events = []
- @conference.social_events.each do |social_event| - @conference.social_events.each do |social_event|
- count = @conference.registrations.joins(:social_events).where("registrations_social_events.social_event_id = ?", social_event.id).count - count = @conference.registrations.joins(:social_events).where("registrations_social_events.social_event_id = ?", social_event.id).count

View file

@ -1,7 +1,7 @@
- count =0 - count =0
%h3 %h3
Speakers (#{@speakers.length}) Speakers (#{@speakers.length})
%table.table.table-striped.table-bordered.table-hover#events %table.table.table-striped.table-bordered.table-hover#speakertable
%thead %thead
%th %th
ID ID
@ -34,3 +34,10 @@
= getdatetime(reg, field) = getdatetime(reg, field)
- else - else
= reg.send(field.to_sym) = reg.send(field.to_sym)
:javascript
$(document).ready(function(){
$('#speakertable').dataTable({
"bPaginate": false
});
});

View file

@ -1,6 +1,10 @@
%h3 .row-fluid
Tickets (#{@tickets.length if @tickets}#{0 unless @tickets}) .span12
- if @supporter_levels.count > 0 %h3
Non-free Tickets (#{@tickets.length if @tickets}#{0 unless @tickets})
.row-fluid
.span5
- if @supporter_levels.count > 0
%table.table.table-bordered.table-striped %table.table.table-bordered.table-striped
%thead %thead
%th Support Level %th Support Level
@ -19,6 +23,6 @@
- if @attendees and @attendees > 0 - if @attendees and @attendees > 0
%br %br
= "#{reg_support.count * 100 / @attendees}% of attendees" = "#{reg_support.count * 100 / @attendees}% of attendees"
- else - else
%p %p
No tickets sold yet No tickets sold yet