From 4ee87241dfa81df986c0c3f009a6f6f3d7e07159 Mon Sep 17 00:00:00 2001 From: echarp Date: Fri, 8 Jan 2016 11:23:25 +0100 Subject: [PATCH] The organisations listed along events is now limited to active organisations. Refs #43 --- app/views/events/show.html.haml | 6 ++---- app/views/orgas/show.text.haml | 1 + 2 files changed, 3 insertions(+), 4 deletions(-) diff --git a/app/views/events/show.html.haml b/app/views/events/show.html.haml index e6025fd9..488d59d1 100644 --- a/app/views/events/show.html.haml +++ b/app/views/events/show.html.haml @@ -15,16 +15,14 @@ %em.fa.fa-users = t '.orga-list' %ul.fa-ul - - @event.region.orgas.each do |orga| + - @event.region.orgas.select(&:active).each do |orga| %li = link_to orga do - if orga.kind %em.fa.fa-li{ class: "fa-#{orga.kind.icon}", title: Kind.human_attribute_name("name_#{orga.kind.name}") } = orga.name - (#{orga.department}) - = link_to orga.url do - = image_tag orga.url + '/favicon.ico', alt: '', class: :favicon + = image_tag orga.url + '/favicon.ico', alt: '', class: :favicon %h1 %em.fa.fa-wrench diff --git a/app/views/orgas/show.text.haml b/app/views/orgas/show.text.haml index c545607c..3ced5046 100644 --- a/app/views/orgas/show.text.haml +++ b/app/views/orgas/show.text.haml @@ -5,6 +5,7 @@ #{Orga.human_attribute_name(:department).concat(':').ljust 12 } #{@orga.department} #{Orga.human_attribute_name(:region).concat(':').ljust 12 } #{@orga.region} #{Orga.human_attribute_name(:url).concat(':').ljust 12 } #{@orga.url} +#{Orga.human_attribute_name(:diaspora).concat(':').ljust 12 } #{@orga.diaspora} #{Orga.human_attribute_name(:feed).concat(':').ljust 12 } #{@orga.feed} #{Orga.human_attribute_name(:contact).concat(':').ljust 12 } #{@orga.contact} #{Orga.human_attribute_name(:submitter).concat(':').ljust 12 } #{@orga.submitter}