30 lines
1.1 KiB
Text
30 lines
1.1 KiB
Text
- if champ.selections_utilisateur.present?
|
|
.areas-title Sélections utilisateur
|
|
.areas
|
|
%ul
|
|
- champ.selections_utilisateur.each do |geo_area|
|
|
%li{ class: editing ? '' : 'flex column mb-2' }
|
|
- if editing
|
|
= link_to '#', data: { geo_area: geo_area.id } do
|
|
= geo_area_label(geo_area)
|
|
= text_field_tag :description, geo_area.description, data: { geo_area: geo_area.id }, placeholder: 'Description de la sélection'
|
|
- else
|
|
= link_to '#', data: { geo_area: geo_area.id } do
|
|
= geo_area_label(geo_area)
|
|
- if geo_area.description.present?
|
|
%span
|
|
= geo_area.description
|
|
|
|
- if champ.cadastres?
|
|
.areas-title Parcelles cadastrales
|
|
.areas
|
|
- if !champ.geometry?
|
|
Aucune zone tracée
|
|
- elsif champ.cadastres.blank?
|
|
= t('errors.messages.cadastres_empty', count: champ.selections_utilisateur.size)
|
|
- else
|
|
%ul
|
|
- champ.cadastres.each do |geo_area|
|
|
%li.flex.column.mb-2
|
|
= link_to '#', data: { geo_area: geo_area.id } do
|
|
= geo_area_label(geo_area)
|