Merge pull request #148 from gopesht/splash_page
Create view for splash page from existing routes
This commit is contained in:
commit
322ddd1501
8 changed files with 37 additions and 1 deletions
5
app/controllers/conference_controller.rb
Normal file
5
app/controllers/conference_controller.rb
Normal file
|
|
@ -0,0 +1,5 @@
|
|||
class ConferenceController < ApplicationController
|
||||
def show
|
||||
@conference = Conference.find_by_short_title(params[:id])
|
||||
end
|
||||
end
|
||||
3
app/views/conference/show.html.haml
Normal file
3
app/views/conference/show.html.haml
Normal file
|
|
@ -0,0 +1,3 @@
|
|||
= content_for :splash_logo do
|
||||
= link_to @conference.title, "#", :class => 'navbar-brand'
|
||||
= render :partial => "home/conference_details", :locals => {:conference => @conference}
|
||||
|
|
@ -20,6 +20,8 @@
|
|||
= simple_format(conference.venue.description, class: 'lead')
|
||||
.col-md-2
|
||||
.btn-group-vertical
|
||||
- if !@conference || @conference != conference
|
||||
= link_to "View Conference", conference_path(conference.short_title), :class =>"btn btn-default"
|
||||
- if conference.registration_open?
|
||||
- if conference.user_registered?(current_user)
|
||||
= link_to "Modify Registration", register_conference_path(conference.short_title), :class =>"btn btn-default"
|
||||
|
|
|
|||
|
|
@ -7,8 +7,10 @@
|
|||
%span.icon-bar
|
||||
%span.icon-bar
|
||||
%span.icon-bar
|
||||
= yield(:splash_logo)
|
||||
= link_to CONFIG['name'], root_path, :class => 'navbar-brand', :title => "Open Source Event Manager"
|
||||
.collapse.navbar-collapse
|
||||
= yield(:splash_header)
|
||||
- if @conference && !@conference.short_title.nil?
|
||||
%p.navbar-text
|
||||
= @conference.short_title
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue