-if input.category_id

  -articles = Article.before(Date.today).where(:category_id => input.category_id).recents.joins(:lang_articles).where("lang_articles.enabled = 1 and lang_articles.lang_site_id = ?", @lang.id).limit(6)
  

  
  .dark_bottom_links.nos_combats_article_index
   
    -articles.each do |article|
      -lang_article = article.lang_articles.where(:lang_site_id => @lang.id).first
      
      -if lang_article.image_file
        -img_url = lang_article.image_file.file.large.url 
       
      -elsif article.image_file
        -img_url = article.image_file.file.large.url
        
      =link_to article_path(:slug => lang_article.slug, :lang => @lang.slug),:data => {:ratio => 0.66}, :class => "with_ratio square_link article_other", :style => "background-image:url('#{img_url}');background-size:100%;background-size:cover;" do
        .inner
          .vertical_center=lang_article.title
    -category = Category.find(input.category_id)
    -count = category.articles.recents.joins(:lang_articles).where("lang_articles.enabled = 1 and lang_articles.lang_site_id = ?", @lang.id).count
    -if count > 9
      .more_link
        =link_to "Voir plus d'articles >", category_public_article_path(:lang => @lang.slug,:slug => category.lang(I18n.locale.to_s).slug), :title => "Articles de la catégorie \""+category.lang(I18n.locale.to_s).name.to_s+'"', :class => "btn"