FIX: display custom sections with default theme

also cleans up mechanism for previewing themes, cleans up naming,
gets rid of old janky "preview_style", secures local theme key
This commit is contained in:
Sam
2017-04-14 13:35:12 -04:00
parent 8370b4b1b7
commit def7348777
14 changed files with 113 additions and 50 deletions

View File

@ -1,6 +1,12 @@
class Admin::ThemesController < Admin::AdminController
skip_before_filter :check_xhr, only: [:show]
skip_before_filter :check_xhr, only: [:show, :preview]
def preview
@theme = Theme.find(params[:id])
redirect_to path("/"), flash: {preview_theme_key: @theme.key}
end
def import