Small simplification to events and orga display

This commit is contained in:
echarp 2020-01-01 22:09:37 +01:00
parent 7ddfdff7c4
commit 249714ee10
2 changed files with 5 additions and 5 deletions

View File

@ -12,8 +12,6 @@
= render 'aside' if [controller_name, action_name] == %w[events show] = render 'aside' if [controller_name, action_name] == %w[events show]
%h3= t '.dateAndPlace'
%p= display_date @event %p= display_date @event
%p.full_address %p.full_address
@ -38,7 +36,6 @@
href: 'https://osm.org/search?query=' + @event.full_address } href: 'https://osm.org/search?query=' + @event.full_address }
= image_tag 'osm_logo.svg', alt: 'OSM logo', width: '32px' = image_tag 'osm_logo.svg', alt: 'OSM logo', width: '32px'
%h3= Event.human_attribute_name :description
.description .description
= description sanitize @event.description, = description sanitize @event.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], tags: %w[p h1 h2 h3 h4 br table tr th td ul ol li a strong b em i img sub sup span],

View File

@ -7,7 +7,7 @@
= title @orga.name = title @orga.name
= render partial: '/orgas/favicon', locals: { orga: @orga } = render partial: '/orgas/favicon', locals: { orga: @orga }
= render 'aside' if controller.controller_name == 'orgas' = render 'aside' if [controller_name, action_name] == %w[orgas show]
%p.full_address %p.full_address
- if @orga.place_name.present? - if @orga.place_name.present?
@ -23,13 +23,16 @@
.orga#map{ data: { url: maps_path(format: :json).to_s, .orga#map{ data: { url: maps_path(format: :json).to_s,
latitude: @orga.latitude.to_s, longitude: @orga.longitude.to_s } } latitude: @orga.latitude.to_s, longitude: @orga.longitude.to_s } }
%h3= Orga.human_attribute_name :description
.description .description
= description sanitize @orga.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], 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] attributes: %w[href src width height style title]
%dl %dl
%dd
%h3
%em.fa.fa-info-circle
= t '.infos'
- if @orga.department.present? - if @orga.department.present?
%dt.department %dt.department
%em.fa.fa-puzzle-piece %em.fa.fa-puzzle-piece