Sha256: fa3ea6e8a1d92293382495bd88a057af92fdc8fbdd217cc6587961927e24e92e

Contents?: true

Size: 1.64 KB

Versions: 2

Compression:

Stored size: 1.64 KB

Contents

- provide(:title, @page.title)
- provide(:meta_tags, @page.meta_tags)
- provide(:meta_description, @page.meta_description)

- if @sliders && @sliders.count == 1
  %div.container-contain.main-background
    = image_tag @sliders.first.image.file if @sliders.first.image
    %div.header-text
      %h1
        = @sliders.first.header if @sliders.first.header
      %p
        = @sliders.first.subheading if @sliders.first.subheading

- elsif @sliders
  = render 'slider', slider_elements: @sliders

%h1
  = @page.title

%div.container-fluid
  - if @sidebar
    %div.row
      %div.col-md-9.col-sm-9
        = render partial: 'pages_cms/pages/main', locals: { page: @page }
      %div.col-md-3.col-sm-3.hidden-xs.back
        = raw @sidebar.content
        %hr
        - if @sidebar.all_posts
          %h5 Blog Posts
          - PagesCms::Article.all.each do |article|
            = link_to article.title, article_path(article), class: 'btn btn-xs btn-default'
          %hr
        - if @sidebar.all_tags
          %h5 Tagged
          - PagesCms::Article.pluck(:tags).flatten.uniq.each do |tag|
            = link_to tag, blog_path(current_site, tag), class: 'btn btn-xs btn-default'
          %hr
        - if @sidebar.all_pages
          %h5 Pages
          %ul.nav.nav-pills.nav-stacked
            - PagesCms::Page.where(sidebar_show: true).each do |link|
              %li
                = link_to link.title, slugged_path(link)
            - @sidebar.links.each_line do |line|
              %li
                - splitted = line.split(',')
                = link_to splitted[0], splitted[1]

  - else
    = render partial: 'pages_cms/pages/main', locals: { page: @page }

Version data entries

2 entries across 2 versions & 1 rubygems

Version Path
pages_cms-2.0.1 app/views/pages_cms/pages/show.html.haml
pages_cms-2.0.0 app/views/pages_cms/pages/show.html.haml