Fold call for papers & call for tracks into one splashpage section

This commit is contained in:
James Mason 2017-11-21 10:56:46 -08:00
parent 394448dc36
commit f0c3fc357b
8 changed files with 73 additions and 83 deletions

View file

@ -8,7 +8,7 @@
= f.inputs name: 'Components' do
= f.input :include_tracks, label: 'Display tracks', input_html: { checked: params[:action] == 'new' || @splashpage.try(:include_tracks) }
= f.input :include_program, label: 'Display program', input_html: { checked: params[:action] == 'new' || @splashpage.try(:include_program) }
= f.input :include_cfp, label: 'Display call for papers information on splashpage, while cfp is open', input_html: { checked: params[:action] == 'new' || @splashpage.try(:include_cfp) }
= f.input :include_cfp, label: 'Display call for papers and call for tracks information on splashpage, while open', input_html: { checked: params[:action] == 'new' || @splashpage.try(:include_cfp) }
= f.input :include_venue, label: 'Display venue', input_html: { checked: params[:action] == 'new' || @splashpage.try(:include_venue) }
= f.input :include_registrations, label: 'Display the registration period', input_html: { checked: params[:action] == 'new' || @splashpage.try(:include_registrations) }
= f.input :include_tickets, label: 'Display tickets', input_html: { checked: params[:action] == 'new' || @splashpage.try(:include_tickets) }

View file

@ -25,7 +25,7 @@
- else
No
%dt
Include CFP:
Include Calls for Content:
%dd
- if @splashpage.include_cfp
Yes

View file

@ -0,0 +1,14 @@
= content_for :splash_nav do
%li
%a.smoothscroll{ href: '#call' } Call For Content
%section#call
.container
.row
- if @conference.call_for_events.try(:open?) ^ @conference.call_for_tracks.try(:open?)
.col-md-3.col-sm-3.hidden-xs  
- if @conference.call_for_events.try(:open?)
= render 'call_for_paper'
.col-md-2.col-sm-2  
- if @conference.call_for_tracks.try(:open?)
= render 'call_for_tracks'

View file

@ -1,48 +1,37 @@
= content_for :splash_nav do
%li
%a.smoothscroll{ href: '#callforpapers' } Call For Papers
- cache [@conference, @conference.call_for_events, @conference.confirmed_tracks,
'#splash#callforpapers'] do
%section#callforpapers
.container
.row
.col-md-12.text-center
%h2
Call for Papers
%p.lead
We are ready to accept your proposals for sessions!
.row
.col-md-6.col-md-offset-3.col-sm-10.col-sm-offset-1
%p
- if @conference.event_types.any?
You can submit proposals for
%span.notranslate
= "#{event_types(@conference)}."
- if @conference.confirmed_tracks.any?
Proposals should fit in one of the
%span.notranslate
= "#{pluralize(@conference.confirmed_tracks.length, 'track')}:"
= "#{tracks(@conference)}."
- if @conference.call_for_events.try(:open?)
The submission period is open
%em.notranslate
= "#{date_string(@conference.call_for_events.start_date,
@conference.call_for_events.end_date)}."
%b
You have
= pluralize(@conference.call_for_events.remaining_days, 'day')
left!
Remember
%span.notranslate
= @conference.title
will only be as good as the sessions you present.
Submit early, submit often!
- else
The submission period is closed.
.row
.col-md-12.text-center
%p.cta-button
= link_to "Submit your paper now",
conference_program_proposals_path(@conference.short_title),
class: 'btn btn-success btn-lg text-center'
.col-md-5.col-sm-5.text-center
%h2
Call for Papers
%p.lead
We are ready to accept your proposals for sessions!
%p
- if @conference.event_types.any?
You can submit proposals for
%span.notranslate
= "#{event_types(@conference)}."
- if @conference.confirmed_tracks.any?
Proposals should fit in one of the
%span.notranslate
= "#{pluralize(@conference.confirmed_tracks.length, 'track')}:"
= "#{tracks(@conference)}."
- if @conference.call_for_events.try(:open?)
The submission period is open
%em.notranslate
= "#{date_string(@conference.call_for_events.start_date,
@conference.call_for_events.end_date)}."
%b
You have
= pluralize(@conference.call_for_events.remaining_days, 'day')
left!
Remember
%span.notranslate
= @conference.title
will only be as good as the sessions you present.
Submit early, submit often!
- else
The submission period is closed.
%p.cta-button
= link_to "Submit your paper now",
conference_program_proposals_path(@conference.short_title),
class: 'btn btn-success btn-lg text-center'

View file

@ -1,30 +1,19 @@
= content_for :splash_nav do
%li
%a.smoothscroll{ href: '#callfortracks' } Call For Tracks
- cache [@conference, @conference.call_for_tracks, '#splash#callfortracks'] do
%section#callfortracks
.container
.row
.col-md-12.text-center
%h2
Call for Tracks
%p.lead
We are ready to accept requests for tracks!
.row
.col-md-6.col-md-offset-3.col-sm-10.col-sm-offset-1
%p
The submission period for track requests is open
%em.notranslate
= "#{date_string(@conference.call_for_tracks.start_date,
@conference.call_for_tracks.end_date)}."
%b
You have
= pluralize(@conference.call_for_tracks.remaining_days, 'day')
left!
.row
.col-md-12.text-center
%p.cta-button
= link_to("Submit your request for track",
conference_program_tracks_path(@conference.short_title),
class: 'btn btn-success btn-lg text-center')
.col-md-5.col-sm-5.text-center
%h2
Call for Tracks
%p.lead
We are ready to accept requests for tracks!
%p
The submission period for track requests is open
%em.notranslate
= "#{date_string(@conference.call_for_tracks.start_date,
@conference.call_for_tracks.end_date)}."
%b
You have
= pluralize(@conference.call_for_tracks.remaining_days, 'day')
left!
%p.cta-button
= link_to("Submit your request for track",
conference_program_tracks_path(@conference.short_title),
class: 'btn btn-success btn-lg text-center')

View file

@ -21,10 +21,8 @@
= render 'tickets'
// calls for content, or program
- if @conference.splashpage.include_cfp && @conference.call_for_events.try(:open?)
= render 'call_for_paper'
- if @conference.splashpage.include_cfp && @conference.call_for_tracks.try(:open?)
= render 'call_for_tracks'
- if @conference.splashpage.include_cfp
= render 'call_for_content'
- if @conference.splashpage.include_program
= render 'schedule_splashpage'