2011-06-25 16:25:31 +00:00
|
|
|
- if can?(:manage, @page)
|
2010-07-23 23:57:18 +00:00
|
|
|
|
2011-11-09 01:35:59 +00:00
|
|
|
= f.inputs :name => :information do
|
2010-07-23 23:57:18 +00:00
|
|
|
|
2011-07-01 00:15:45 +00:00
|
|
|
= f.input :title, :wrapper_html => { :class => 'highlighted' }
|
2010-07-23 23:57:18 +00:00
|
|
|
|
2011-06-25 16:25:31 +00:00
|
|
|
- if not @page.index? and not @page.not_found?
|
|
|
|
= f.input :parent_id, :as => :select, :collection => parent_pages_options, :include_blank => false
|
2011-03-03 23:03:55 +00:00
|
|
|
|
2011-11-09 01:35:59 +00:00
|
|
|
= f.input :slug, :required => false, :hint => @page.slug.blank? ? t('.empty_slug') : page_url(@page), :input_html => { :'data-url' => get_path_pages_url, :disabled => @page.index? || @page.not_found? }, :wrapper_html => { :style => "#{'display: none' if @page.templatized?};" }
|
2011-04-29 20:10:13 +00:00
|
|
|
|
2011-06-25 16:25:31 +00:00
|
|
|
= render 'editable_elements', :page => @page
|
2011-03-03 23:03:55 +00:00
|
|
|
|
2011-11-09 01:35:59 +00:00
|
|
|
= f.inputs :name => :seo do
|
2011-04-29 20:10:13 +00:00
|
|
|
|
2011-06-23 12:57:52 +00:00
|
|
|
= f.input :seo_title
|
2011-04-29 20:10:13 +00:00
|
|
|
= f.input :meta_keywords
|
|
|
|
= f.input :meta_description
|
2011-03-03 23:03:55 +00:00
|
|
|
|
2011-06-25 16:25:31 +00:00
|
|
|
- if can?(:manage, @page)
|
2011-03-03 23:03:55 +00:00
|
|
|
|
2011-11-09 01:35:59 +00:00
|
|
|
= f.inputs :name => :advanced_options, :id => 'advanced-options', :class => 'foldable' do
|
2011-03-03 23:03:55 +00:00
|
|
|
|
2011-07-01 00:15:45 +00:00
|
|
|
= f.input :content_type_id, :as => :select, :collection => current_site.content_types.all.to_a, :include_blank => false, :wrapper_html => { :style => "#{'display: none' unless @page.templatized?}" }
|
2010-07-23 23:57:18 +00:00
|
|
|
|
2011-11-09 01:35:59 +00:00
|
|
|
= f.input :templatized, :as => :'Locomotive::Toggle', :style => "#{'display: none' if @page.redirect?}"
|
2010-07-23 23:57:18 +00:00
|
|
|
|
2011-11-09 01:35:59 +00:00
|
|
|
= f.input :published, :as => :'Locomotive::Toggle'
|
2011-03-03 23:03:55 +00:00
|
|
|
|
2011-11-09 01:35:59 +00:00
|
|
|
= f.input :listed, :as => :'Locomotive::Toggle'
|
2011-01-06 14:48:41 +00:00
|
|
|
|
2011-11-09 01:35:59 +00:00
|
|
|
= f.input :redirect, :as => :'Locomotive::Toggle', :style => "#{'display: none' if @page.templatized?}"
|
2011-01-06 14:48:41 +00:00
|
|
|
|
2011-06-25 16:25:31 +00:00
|
|
|
= f.input :cache_strategy, :as => :select, :collection => options_for_page_cache_strategy, :include_blank => false, :wrapper_html => { :style => "#{'display: none' if @page.redirect?}" }
|
|
|
|
|
|
|
|
= f.input :redirect_url, :required => true, :wrapper_html => { :style => "#{'display: none' unless @page.redirect?}" }
|
2010-07-23 23:57:18 +00:00
|
|
|
|
2011-11-09 01:35:59 +00:00
|
|
|
= f.inputs :name => :raw_template, :class => 'foldable' do
|
2010-08-27 15:40:03 +00:00
|
|
|
|
2011-11-09 01:35:59 +00:00
|
|
|
= f.input :raw_template, :as => :'Locomotive::Code'
|