Count events, users, people and use datatables for them.

Show event types.
Add proposal#show.
This commit is contained in:
Henne Vogelsang 2013-05-07 13:22:45 +02:00 committed by Henne Vogelsang
parent a557f3750e
commit 200a701861
8 changed files with 131 additions and 7 deletions

View file

@ -13,6 +13,12 @@
.row-fluid
.span12
%table.table
%tr
%td
%b Type
%td
- if @event.type
= @event.type.title
%tr
%td
%b State

View file

@ -1,5 +1,11 @@
%table.table.table-striped.table-bordered.table-hover
%h2
People
- if @people
= "(#{@people.length})"
%table.table.table-striped.table-bordered.table-hover#people
%thead
%th
%b Email
%th
%b Last Name
%th
@ -11,8 +17,16 @@
%th
- @people.each do |person|
%tr
%td= person.email
%td= person.last_name
%td= person.first_name
%td= person.public_name
%td= person.registrations.count
%td= link_to "View", admin_person_path(person)
%td= link_to "View", admin_person_path(person)
:javascript
$(document).ready(function() {
$('#people').dataTable( {
sPaginationType: "full_numbers"
} );
} );

View file

@ -4,6 +4,10 @@
= link_to "Export PDF", admin_conference_registrations_path(@conference.short_title, :format => :pdf), :class => "btn btn-success"
.row-fluid
.span12
%h2
Registrations
- if @registrations
= "(#{@registrations.length})"
%table.table.table-striped.table-bordered.table-hover
%thead
%th
@ -45,4 +49,4 @@
%td
= link_to "Edit", "#", :class => "btn btn-primary"
%td
= link_to "Delete", "#", :class => "btn btn-danger", :confirm => "Really delete registration for #{registration.public_name}?"
= link_to "Delete", "#", :class => "btn btn-danger", :confirm => "Really delete registration for #{registration.public_name}?"

View file

@ -1,7 +1,11 @@
.container-fluid
.row-fluid
.span12
%table.table.table-striped.table-bordered.table-hover
%h2
Users
- if @users
= "(#{@users.length})"
%table.table.table-striped.table-bordered.table-hover#users
%thead
%th
%b Email
@ -55,3 +59,9 @@
"data-content" => user.popup_details,
"data-original-title" => ""
:javascript
$(document).ready(function() {
$('#users').dataTable( {
sPaginationType: "full_numbers"
} );
} );