Files
old-roraccounting/app/controllers/static_controller.rb

18 lines
384 B
Ruby

class StaticController < ActionController::API
include ActionView::Layouts
include BasicAuth
def frontend_index_html
if params[:path].present?
send_file params[:path]
else
render file: 'protected_public/index.html'
end
end
def frontend_static
full_path = "protected_public/#{params[:path]}.#{params[:format]}"
send_file full_path
end
end