<% content_for :javascript_includes do %> <%= javascript_include_tag "/assets/ckeditor/ckeditor" %> <% end %> <%= simple_form_for [:admin, @page], wrapper: :horizontal_form, wrapper_mappings: { check_boxes: :horizontal_collection } do |f| %> <%= f.error_notification %> <%= f.input :title %> <%= f.input :content, as: :ckeditor, input_html: { ckeditor: { toolbar: 'Full' } } %> <%= f.input :page, :as => :hidden, :input_html => { :value => params[:page] || 1 } %>
<%= f.button :submit, class: "btn-primary" %> <%= link_to "Cancel", admin_pages_path(:page => params[:page]), class: "btn btn-outline-secondary" %>
<% end %>