# encoding: UTF-8
class WebController < ApplicationController
  skip_before_filter :autorizacia
  
  layout 'public'
  
  def index
  end
  
  def show
    @klient = Klienti.find(params[:id])
  end
  
  def ospolocnosti
  end
  
  def koncerty
  end
  
  def aktuality
  end
  
  def fotogaleria
  end
  
  def kontakt
  end
  
  def sponzoring
  end
  
  def recenzie_show
    @podujatie = Podujatium.find(params[:id])
  end

  def recenzie_new
    @podujatie = Podujatium.find(params[:id])
    @recenzie = Recenzie.new
    @recenzie.ID_Podujatie = @podujatie.ID_Podujatie
  end
  
  def recenzie_create
    @podujatie = Podujatium.find(params[:id])
    @recenzie = Recenzie.new(params[:recenzie])

    respond_to do |format|
      if @recenzie.save
        format.html { redirect_to stranky_recenzie_show_path(@podujatie), notice: 'Recenzie was successfully created.' }
      else
        format.html { render action: "recenzie_new" }
      end
    end
  end
  
end
