Registration for Events
This commit is contained in:
parent
f188fd5575
commit
01ec43e53a
35 changed files with 522 additions and 46 deletions
|
|
@ -42,7 +42,10 @@
|
|||
250
|
||||
words.
|
||||
|
||||
= f.input :require_registration, label: 'Require participants to register to your event'
|
||||
= f.inputs 'Enable pre-registration' do
|
||||
= f.input :require_registration, label: 'Require participants to register to your event'
|
||||
- message = @event.room ? "Value must be between 1 and #{@event.room.size}" : 'Check room capacity after scheduling.'
|
||||
= f.input :max_attendees, hint: 'The maximum number of participants. ' + message
|
||||
|
||||
- if current_user.has_any_role? :admin, { name: :organizer, resource: @conference }, { name: :cfp, resource: @conference }
|
||||
= f.input :is_highlight
|
||||
|
|
|
|||
|
|
@ -2,7 +2,7 @@
|
|||
.row
|
||||
.col-md-12.page-header
|
||||
%h1
|
||||
Proposals for
|
||||
Proposals for
|
||||
%span.notranslate
|
||||
= @conference.title
|
||||
|
||||
|
|
@ -68,9 +68,9 @@
|
|||
= event.event_type.title
|
||||
= "(#{event.event_type.length} min)"
|
||||
= "in #{event.track.name}" if event.track
|
||||
- if event.state == 'confirmed' && event.require_registration == true
|
||||
,
|
||||
Pre-registered: #{pre_registered(event).count}
|
||||
- if event.require_registration
|
||||
%br
|
||||
= link_to registered_text(event), registrations_conference_program_proposal_path(@conference.short_title, event), class: 'btn btn-xs btn-danger'
|
||||
|
||||
%td.col-md-2{style: "padding:20px 8px 20px 8px;"}
|
||||
= link_to 'Complete your proposal', 'javascript: void(0)', "type"=>"button", "data-trigger"=>"focus", "data-toggle"=>"popover", "title"=>"Your todo list", "data-content"=>"#{render partial: 'tooltip', locals: { event: event} }"
|
||||
|
|
|
|||
36
app/views/proposal/registrations.html.haml
Normal file
36
app/views/proposal/registrations.html.haml
Normal file
|
|
@ -0,0 +1,36 @@
|
|||
.container
|
||||
.row
|
||||
.col-md-10.col-md-offset-1
|
||||
.page-header
|
||||
%h1
|
||||
Registrations (#{@event.events_registrations.length}/#{@event.max_attendees})
|
||||
.text-muted
|
||||
for
|
||||
= @event.title
|
||||
|
||||
.well
|
||||
%table.table.table-hover.table-borderd.table-striped.datatable#registrations
|
||||
%thead
|
||||
%th
|
||||
%th Name
|
||||
%th Email
|
||||
%th Created AT
|
||||
%th Attended
|
||||
%th Attended Conference
|
||||
%tbody
|
||||
- @event.events_registrations.each.with_index(1) do |event_registration, index|
|
||||
%tr
|
||||
%td= index
|
||||
%td= event_registration.name
|
||||
%td= event_registration.email
|
||||
%td= event_registration.created_at
|
||||
%td.text-center
|
||||
- if event_registration.attended
|
||||
%i.fa.fa-check.text-success
|
||||
- else
|
||||
%i.fa.fa-times.text-danger
|
||||
%td
|
||||
- if event_registration.registration.attended
|
||||
%i.fa.fa-check.text-success
|
||||
-else
|
||||
%i.fa.fa-times.text-danger
|
||||
|
|
@ -7,10 +7,13 @@
|
|||
%br
|
||||
%small
|
||||
= @event.subtitle
|
||||
- if can? :schedule, @conference
|
||||
= link_to "Schedule", schedule_conference_path(@conference.short_title), :class =>"btn btn-success pull-right"
|
||||
- if can? :edit, @event
|
||||
= link_to "Edit", edit_conference_program_proposal_path(@conference.short_title, @event), :class => "btn btn-mini btn-primary pull-right"
|
||||
.btn-group.pull-right
|
||||
- if can? :update, @event
|
||||
= link_to 'Registrations', registrations_conference_program_proposal_path(@conference.short_title, @event), class: 'btn btn-mini btn-success'
|
||||
- if can? :edit, @event
|
||||
= link_to "Edit", edit_conference_program_proposal_path(@conference.short_title, @event), :class => "btn btn-mini btn-primary"
|
||||
- if can? :schedule, @conference
|
||||
= link_to "Schedule", schedule_conference_path(@conference.short_title), :class =>"btn btn-success"
|
||||
.row
|
||||
.col-md-3
|
||||
.speakerinfo
|
||||
|
|
@ -28,7 +31,6 @@
|
|||
= @speaker.affiliation
|
||||
-if @speaker.biography?
|
||||
= simple_format(@speaker.biography)
|
||||
|
||||
.col-md-9
|
||||
.row
|
||||
.col-md-12
|
||||
|
|
@ -76,5 +78,9 @@
|
|||
- if @event.difficulty_level_id
|
||||
%span.label{:style =>"background-color: #{@event.difficulty_level.color};"}
|
||||
= @event.difficulty_level.title
|
||||
- if @event.require_registration
|
||||
= link_to "Registration required!", new_conference_conference_registrations_path(@conference.short_title), :class => "btn btn-xs btn-warning"
|
||||
|
||||
- if @event.require_registration
|
||||
.col-md-12
|
||||
%dt Requires Registration:
|
||||
%dd
|
||||
= link_to "Yes (#{registered_text(@event)})", new_conference_conference_registrations_path(@conference.short_title), class: 'btn btn-xs btn-danger', disabled: !@event.registration_possible?
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue