app/views/spina/admin/pages/_form_advanced.html.haml in spina-0.8.3 vs app/views/spina/admin/pages/_form_advanced.html.haml in spina-0.9.0
- old
+ new
@@ -27,17 +27,17 @@
= f.check_box :show_in_menu, data: {switch: true}
%tr{style: ('border-bottom: none' if @page.custom_page?)}
%td
= Spina::Page.human_attribute_name :menu_title
%td
- = f.text_field :menu_title, placeholder: Spina::Page.human_attribute_name(:show_in_menu_placeholder)
+ = f.text_field :menu_title, placeholder: Spina::Page.human_attribute_name(:show_in_menu_placeholder), value: f.object.read_attribute(:menu_title)
%tr{style: ('display: none' if @page.custom_page?)}
%td
= Spina::Page.human_attribute_name :view_template
%td
- .select-dropdown.page-template{data: {page_parts: current_theme.config.view_templates[@page.view_template || "show"][:page_parts]}}
- - options = options_for_select(current_theme.config.view_templates.map { |template| [template[1][:title], template[0], {'data-page-parts' => template[1][:page_parts]}] }, @page.view_template)
+ .select-dropdown.page-template{data: {page_parts: @page.view_template_config(current_theme)[:page_parts]}}
+ - options = options_for_select(current_theme.view_templates.map { |template| [template[:title], template[:name], {'data-page-parts' => template[:page_parts]}] }, @page.view_template)
= f.select :view_template, options
%tr{style: ('display: none' if @page.custom_page?)}
%td
= Spina::Page.human_attribute_name :ancestry