Sha256: 471b4e9bd6116400a8e28a9104fa0e3185c19b3ff173e85af171a8c3ca805f9c

Contents?: true

Size: 1.82 KB

Versions: 7

Compression:

Stored size: 1.82 KB

Contents

.page-header
  .row
    .col-md-7
      %h1
        Pages
        %small
          <i class="ace-icon fa fa-angle-double-right"></i>
          manage pages
    .col-md-5
      =link_to 'New page', new_page_path(:parent_id=>@parent_id), :class=>'btn btn-sm btn-primary'
      =link_to 'New folder', newfolder_pages_path(:parent_id=>@parent_id, :is_folder=>1), :class=>'btn btn-sm btn-default'
      .btn-group
        %button(type="button" class="btn btn-default btn-sm dropdown-toggle" data-toggle="dropdown" aria-haspopup="true" aria-expanded="false")
          New... <span class="caret"></span>
        %ul.dropdown-menu
          %li=link_to 'text page', newtextpage_pages_path(:parent_id=>@parent_id)

.filter
  = inline_filter_form_for(@filter)


- if @parent
  =link_to 'HOME', pages_path(:parent_id=>0)
  #{"/"}
  =link_to @parent.title, pages_path(:parent_id=>@parent.id)

%table.table.table-striped.table-bordered
  %tr
    %th= link_to_sortable_column :title, 'Title'
    %th= link_to_sortable_column :name, 'Name'
    %th URL
    %th Template
    %th Commands

  - @items.each do |item|
    %tr
      %td
        - if item.is_folder
          =link_to pages_path(:parent_id=>item.id) do
            <i class="fa fa-folder-o"></i>
            =item.title
        - else
          =link_to item.title, edit_page_path(item)
      %td
        =item.name
      %td
        =item.url
      %td
        - if item.template
          =link_to edit_template_path(item.template) do
            =item.template.title
          %br
          =item.template.basepath
        - elsif !item.is_folder
          N/A
        - else
          &nbsp;

      %td
        =link_to 'Edit', (item.is_folder? ? editfolder_page_path(item) : edit_page_path(item))
        =link_to 'Delete', page_path(item), :method => :delete, data: { confirm: 'Are you sure?' }

=paginate @items

Version data entries

7 entries across 7 versions & 1 rubygems

Version Path
optimacms-0.3.2 app/views/optimacms/admin/pages/index.html.haml
optimacms-0.3.1 app/views/optimacms/admin/pages/index.html.haml
optimacms-0.2.23 app/views/optimacms/admin/pages/index.html.haml
optimacms-0.2.22 app/views/optimacms/admin/pages/index.html.haml
optimacms-0.2.19 app/views/optimacms/admin/pages/index.html.haml
optimacms-0.2.18 app/views/optimacms/admin/pages/index.html.haml
optimacms-0.2.17 app/views/optimacms/admin/pages/index.html.haml