wizard.rb 419 B

123456789101112131415
  1. class CustomWizard::WizardController < ::ApplicationController
  2. def set_layout
  3. File.expand_path('../../views/layouts/custom_wizard.html.erb', __FILE__)
  4. end
  5. def index
  6. respond_to do |format|
  7. format.json do
  8. wizard = CustomWizard::Builder.new(current_user, params[:wizard_id].underscore).build
  9. render_serialized(wizard, WizardSerializer)
  10. end
  11. format.html {}
  12. end
  13. end
  14. end