Class: Spree::Admin::ThemesTemplatesController
- Inherits:
-
BaseController
- Object
- BaseController
- Spree::Admin::ThemesTemplatesController
- Defined in:
- app/controllers/spree/admin/themes_templates_controller.rb
Instance Method Summary collapse
Instance Method Details
#create ⇒ Object
15 16 17 18 19 20 21 22 23 24 |
# File 'app/controllers/spree/admin/themes_templates_controller.rb', line 15 def create @template = @theme.themes_templates.build(new_template_params) @template.created_by_admin = true if @template.save redirect_to admin_theme_templates_path(@theme) else render :new end end |
#edit ⇒ Object
26 27 |
# File 'app/controllers/spree/admin/themes_templates_controller.rb', line 26 def edit end |
#index ⇒ Object
8 9 |
# File 'app/controllers/spree/admin/themes_templates_controller.rb', line 8 def index end |
#new ⇒ Object
11 12 13 |
# File 'app/controllers/spree/admin/themes_templates_controller.rb', line 11 def new @template = @theme.themes_templates.build end |
#update ⇒ Object
29 30 31 32 |
# File 'app/controllers/spree/admin/themes_templates_controller.rb', line 29 def update @template.update(template_params) render :edit end |