Sha256: 716015d1a0f26b9c72ad98bc4fbcd52cab113ee272d7f6b8a5e9301e7db90f58

Contents?: true

Size: 1.91 KB

Versions: 5

Compression:

Stored size: 1.91 KB

Contents

- page.page_blocks.order(:order).each do |block|
  %hr
  %div.container-fluid
    %div.row
      %div{ id: block.div_id }
        - if block.name
          %h2
            = block.name
        - block.thumbnails.each do |thumb|
          %div.thumbnail.col-md-4.col-sm-6
            - if thumb.image
              = image_tag thumb.image.file
            - else
              = image_tag '/images/default.jpg'
            %h4
              = link_to raw(thumb.content), thumb.link

        - block.text_boxes.each do |box|
          %p
            = raw box.content

        - block.image_boxes.each do |box|
          %div.image-box
            - if box.image
              = image_tag box.image.file
            - else
              = image_tag '/images/default.jpg'
            %h3
              = link_to box.heading, box.link

        - block.blog_feeds.each do |feed|
          - @articles.limit(feed.limit).each do |post|
            %div.post{ onclick: "window.location='/articles/#{post.id}';", style: 'cursor: pointer' }
              %div.image-post
                = image_tag post.image.file if post.image
              %h2.center
                = post.title
              = post.created_at.strftime("%B %d")
              %p
                = raw HTML_Truncator.truncate(post.content, 50)
            %div
              - post.tags.each do |tag|
                = link_to tag, blog_path(tag), class: 'btn btn-default btn-xs'

        - block.contact_fields.each do |contact|
          = raw contact.content
          = form_for PagesCms::Contact.new, url: contacts_path, method: :post do |f|
            = f.text_field :name, placeholder: 'your name', class: 'form-control'
            = f.text_field :email, placeholder: 'your email', class: 'form-control'
            = f.text_area :message, placeholder: 'your message', class: 'form-control', rows: 10
            <br />
            = f.submit 'Send Message', class: 'btn btn-primary'

Version data entries

5 entries across 5 versions & 1 rubygems

Version Path
pages_cms-1.2.3 app/views/pages_cms/pages/_main.html.haml
pages_cms-1.2.2 app/views/pages_cms/pages/_main.html.haml
pages_cms-1.2.1 app/views/pages_cms/pages/_main.html.haml
pages_cms-1.2.0 app/views/pages_cms/pages/_main.html.haml
pages_cms-1.1.0 app/views/pages_cms/pages/_main.html.haml