91 lines
2.7 KiB
Plaintext
91 lines
2.7 KiB
Plaintext
- set_orga_meta
|
|
|
|
%h2
|
|
- if @orga.kind
|
|
%em.fa{ class: "fa-#{@orga.kind.icon}",
|
|
title: Kind.human_attribute_name("name_#{@orga.kind.name}") }
|
|
= title @orga.name
|
|
= render partial: '/orgas/favicon', locals: { orga: @orga }
|
|
|
|
= render 'aside' if controller.controller_name == 'orgas'
|
|
|
|
%p.full_address
|
|
- if @orga.place_name.present?
|
|
%span.place_name= @orga.place_name
|
|
- if @orga.address.present?
|
|
%span.address= @orga.address
|
|
%span.city= @orga.city
|
|
%span.region
|
|
= t @orga.region.code.present? ? @orga.region.code : @orga.region.name,
|
|
scope: :countries, default: @orga.region.name
|
|
|
|
- if @orga.latitude && @orga.longitude
|
|
.orga#map{ data: { url: maps_path(format: :json).to_s,
|
|
latitude: @orga.latitude.to_s, longitude: @orga.longitude.to_s } }
|
|
|
|
%h3= t '.description'
|
|
.description
|
|
= description sanitize @orga.description,
|
|
tags: %w[p h1 h2 h3 h4 br table tr th td ul ol li a strong b em i img sub sup span],
|
|
attributes: %w[href src width height style title]
|
|
|
|
%dl
|
|
- if @orga.department.present?
|
|
%dt.department
|
|
%em.fa.fa-puzzle-piece
|
|
= Orga.human_attribute_name :department
|
|
%dd= @orga.department
|
|
- if @orga.url.present?
|
|
%dt.url
|
|
%em.fa.fa-external-link-alt
|
|
= Orga.human_attribute_name :url
|
|
%dd= link_to @orga.url, @orga.url.html_safe
|
|
- if @orga.diaspora.present?
|
|
%dt.diaspora<
|
|
= Orga.human_attribute_name :diaspora
|
|
%em.fa
|
|
%dd= link_to @orga.diaspora, @orga.diaspora
|
|
- if @orga.feed.present?
|
|
%dt.feed
|
|
%em.fa.fa-rss
|
|
= Orga.human_attribute_name :feed
|
|
%dd= link_to @orga.feed, @orga.feed
|
|
- if @orga.contact.present?
|
|
%dt.contact
|
|
%em.fa.fa-envelope
|
|
= Event.human_attribute_name :contact
|
|
%dd= mail_to @orga.contact, nil,
|
|
encode: (request.format == 'text/html' ? :javascript : nil),
|
|
replace_at: ' CHEZ ', replace_dot: ' POINT '
|
|
- if @orga.tags.any?
|
|
%dt.tags
|
|
%em.fa.fa-tags
|
|
= Event.human_attribute_name :tags
|
|
%dd
|
|
- @orga.tags.each do |tag|
|
|
= link_to tag, tag_path(tag.name), rel: :tag
|
|
%dt.active
|
|
%em.fa.fa-heartbeat
|
|
= Orga.human_attribute_name :active
|
|
%dd= t @orga.active.to_s
|
|
- if @orga.updated_at
|
|
%dt.updated_at
|
|
%em.fa.fa-calendar
|
|
= Orga.human_attribute_name :updated_at
|
|
%dd= l @orga.updated_at.to_date, format: :long
|
|
|
|
- if @events_future && @events_future.any?
|
|
%dt.future
|
|
%em.fa.fa-forward
|
|
= t '.future'
|
|
%dd
|
|
= link_to tag_path @orga.name_as_tag do
|
|
= t '.count', count: @events_future.count
|
|
- if @events_future && @events_past.any?
|
|
%dt.past
|
|
%em.fa.fa-backward
|
|
= t '.past'
|
|
%dd
|
|
= link_to tag_path @orga.name_as_tag do
|
|
= t '.count', count: @events_past.count
|