<% if @agency.css && @agency.css.strip.length > 0 %> <% end %> <% if html_header=Setting.get('html_header') %> <%= raw html_header %> <% end %> <% unless @posts @agents = User.where(:agency_id => @agency.id).agent.order('presence desc').limit(8) #- Posts @posts = Post.site(@agency.id).language(I18n.locale).includes(:user, :place, :agency_post).where(:kind => INDEXABLE_POSTS).order('created_at desc') if @agency_template && hashtag = Setting.get("hashtag_#{@agency_template}") @posts = @posts.hashtag(hashtag) end @posts = @posts.limit(Setting.get('fp_post_count') || 15) #- Experiences order = Setting.get('experiences_order') || 'hits_all desc' @experiences = Post.site(@agency.id).language(I18n.locale).includes(:place).where(:kind => VENDOR).order(order) if @agency_template && hashtag = Setting.get("hashtag_#{@agency_template}") @experiences = @experiences.hashtag(hashtag) end @experiences = @experiences.limit(Setting.get('fp_exp_count') || 8) #- Look for sidebar content @sidebars = Page.site(@agency.id).language(I18n.locale).where(:external_link => 'sidebar_home').order('title').all @nobranding = true @title = @agency.meta_title && @agency.meta_title.strip.length > 0 ? @agency.meta_title : @agency.name unless @agency.meta_description && @agency.meta_description.strip.length > 0 && @description = @agency.meta_description @description = @agency.description end #- Get a random testimonial @testimonial = Post.site(@agency.id).language(I18n.locale).tag_search('leisure').where(:kind => TESTIMONIAL).order('random()').first end %> <%= render_page('header_leisure') %> <%= render_page('navigation_leisure') %>

Vacations with that little extra

<% if tags = Post.tags(@agency.id, VENDOR) %>
<% tags[0..8].each do |k,v| %> <%= k.capitalize %> (<%= v %>) <% end %>
<% end %>
<%= render_page('vacation_slider') %>

<%= t('Top Value Offers')%>

<%= render_page('block_listing') %>

<%= t('Ideas to inspire your next vacation')%>

<%= render_page('block_listing_ideas') %>
<%= render_page('website_selector_vac') %> <%= render_page('ad_side_leisureindex') %> <%= render_page('agents_side_list') %> <% if @testimonial %> <%= render_page('testimonial_side') %> <% end %>

<%= t('From the blog')%>

<% #- Blog posts for corporate @blogs = Post.site(@agency.id).includes(:agency_post).language(I18n.locale).where(:kind => BLOG).hashtag('#leisure').order('created_at desc').limit(3).all %> <% if @blogs && @blogs.length > 0 %> <% @blogs.each do |post| %>
<% next unless post.place and post.user %>
<% if ap = post.agency_post %> <%= ap.created_at.strftime('%B %d, %Y') %> <% else %> <%= post.created_at.strftime('%B %d, %Y') %> <% end %>

<%= post.summary || raw(clean_up_wiki_content(post.preview(250))) %>

<% end %> <% end %>
<%= render_page('tat_subscribe_form') %>
<%= render_page('footer_leisure') %> <%= render_page('js') %> <% if @enable_ckeditor %> <%= render :partial => 'layouts/ckeditor' %> <% end %> <%= render_page('google_code') %>