- page.page_blocks.order(:order).each do |block| %div.container-fluid.space-bottom %div.row %div{ id: block.div_id } - if block.name.present? %div.back %h2 = block.name - block.thumbnails.each do |thumb| %div.thumb-box %div{ style: 'height:250px;overflow:hidden;' } - if thumb.image = image_tag thumb.image.file.url, class: 'img-responsive' - else = image_tag '/images/default.jpg', class: 'img-responsive' %a{ href: thumb.link } %h4 = raw(thumb.content) - block.text_boxes.each do |box| %div.back = raw box.content - block.markdown_texts.each do |box| %div.back = find_and_preserve(raw(box.content_rendered)) - block.image_boxes.each do |box| %div.image-box - if box.image = image_tag box.image.file.url, class: 'img-responsive' - else = image_tag '/images/default.jpg', class: 'img-responsive' %h3 = link_to box.heading, box.link %p = box.content - block.blog_feeds.each do |feed| - @articles.reverse_order.limit(feed.limit).each do |post| %div.post.back %div.image-post = image_tag post.image.file.url, class: 'img-responsive' if post.image %h2 = link_to post.title, article_path(post), style: 'color:black' %h5 = post.created_at.strftime("%B %d") = raw HTML_Truncator.truncate(post.content_either, 50) %div - post.tags.each do |tag| = link_to tag, blog_path(current_site, tag), class: 'btn btn-default btn-xs' - block.contact_fields.each do |contact| %div.back = 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
= f.submit 'Send Message', class: 'btn btn-primary'