jam-cloud/web/app/controllers/landings_controller.rb

54 lines
1.1 KiB
Ruby

class LandingsController < ApplicationController
respond_to :html
def watch_bands
@promo_buzz = PromoBuzz.active
if Rails.application.config.use_promos_on_homepage
@promo_latest = PromoLatest.active
else
@promo_latest, start = Feed.index(nil, limit: 10)
end
page = params['p'].to_i
if page == 2
render 'watch_bands_2', layout: 'web'
elsif page == 3
render 'watch_bands_3', layout: 'web'
else
render 'watch_bands_1', layout: 'web'
end
end
def watch_overview
@promo_buzz = PromoBuzz.active
if Rails.application.config.use_promos_on_homepage
@promo_latest = PromoLatest.active
else
@promo_latest, start = Feed.index(nil, limit: 10)
end
page = params['p'].to_i
if page == 2
render 'watch_overview_2', layout: 'web'
elsif page == 3
render 'watch_overview_3', layout: 'web'
else
render 'watch_overview_1', layout: 'web'
end
end
def watch_bands_tight
render 'watch_bands_tight', layout: 'web'
end
def watch_overview_tight
render 'watch_overview_tight', layout: 'web'
end
end