Rework bootstrapSwitch

This commit is contained in:
Stella Rouzi 2015-06-14 22:28:33 +03:00
parent a35f98b1a3
commit 53f0606ac1
4 changed files with 89 additions and 32 deletions

View file

@ -22,6 +22,8 @@
%b Submitter
%th
%b Speaker
%th
%b Pre-registration
%th
%b Highlight
%th
@ -72,12 +74,22 @@
= link_to speaker.name, admin_user_path(speaker)
- else
Unknown speaker
%td{'data-order' => "#{event.require_registration}"}
= check_box_tag @conference.short_title, event.id, event.require_registration,
method: :patch, url: "/admin/conference/#{@conference.short_title}/events/#{event.id}?event[require_registration]=",
class: 'switch-checkbox', data: { size: 'small',
off_color: 'warning',
on_text: 'Yes',
off_text: 'No' }
%td{'data-order' => "#{event.is_highlight}"}
= check_box_tag @conference.short_title, event.id, event.is_highlight, class: 'switch-checkbox',
data: { size: "small",
off_color: 'warning',
on_text: 'Yes',
off_text: 'No' }
= check_box_tag @conference.short_title, event.id, event.is_highlight,
method: :patch, url: "/admin/conference/#{@conference.short_title}/events/#{event.id}?event[is_highlight]=",
class: 'switch-checkbox', data: { size: 'small',
off_color: 'warning',
on_text: 'Yes',
off_text: 'No' }
%td
.btn-group