The organisation favicon is now in its own template

This commit is contained in:
echarp 2019-02-27 12:56:45 +00:00
parent 0a1b7fcbe3
commit 0ad35f1fb7
4 changed files with 5 additions and 4 deletions

View File

@ -12,7 +12,7 @@
%em.fa.fa-li{ class: "fa-#{orga.kind.icon}",
title: Kind.human_attribute_name("name_#{orga.kind.name}") }
= orga.name
= image_tag orga.url + '/favicon.ico', alt: '', class: :favicon
= render partial: '/orgas/favicon', locals: { orga: orga }
%h2
%em.fa.fa-wrench

View File

@ -0,0 +1,2 @@
- if orga.url.match?(/^http/) && !orga.url.match?(/facebook/)
= image_tag orga.url + '/favicon.ico', alt: '', class: :favicon

View File

@ -30,8 +30,7 @@
title: Kind.human_attribute_name("name_#{orga.kind.name}") }
%td.name
= orga.name
- if orga.url =~ /^http/
= image_tag orga.url + '/favicon.ico', alt: '', class: :favicon
= render partial: '/orgas/favicon', locals: { orga: orga }
%td.city= orga.city
%td.department= orga.department
%td.region= orga.region

View File

@ -5,7 +5,7 @@
%em.fa{ class: "fa-#{@orga.kind.icon}",
title: Kind.human_attribute_name("name_#{@orga.kind.name}") }
= title @orga.name
= image_tag @orga.url + '/favicon.ico', alt: '', class: :favicon
= render partial: '/orgas/favicon', locals: { orga: @orga }
= render 'aside' if controller.controller_name == 'orgas'