aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorXinhui2016-09-19 11:04:31 +0200
committerXinhui2016-09-19 11:04:42 +0200
commit011a1c85d77757cddccce66fabe3a29c625ff41d (patch)
tree69521cc17a4f7e9e7fb6af90dd36303df37cded7
parentab934bcb678384926cc14742641af8bccb7fb0d1 (diff)
downloadchouette-core-011a1c85d77757cddccce66fabe3a29c625ff41d.tar.bz2
Display StopArea deleted status
Ref #1624
-rw-r--r--app/views/stop_areas/_stop_area.html.slim5
-rw-r--r--app/views/stop_areas/show.html.slim11
-rw-r--r--config/locales/stop_areas.en.yml1
-rw-r--r--config/locales/stop_areas.fr.yml1
4 files changed, 13 insertions, 5 deletions
diff --git a/app/views/stop_areas/_stop_area.html.slim b/app/views/stop_areas/_stop_area.html.slim
index 0265e554a..15f9e4452 100644
--- a/app/views/stop_areas/_stop_area.html.slim
+++ b/app/views/stop_areas/_stop_area.html.slim
@@ -16,6 +16,9 @@
.panel-body
p
+ - if stop_area.deleted_at
+ span.warning = stop_area.human_attribute_name('deleted')
+ p
- unless stop_area.area_type == 'ITL' || stop_area.geometry
span.warning = t('.no_position')
@@ -42,4 +45,4 @@
= t(".no_object")
- else
- stop_area.lines.each do |line|
- span.label.label-default.line = line.number || truncate( line.name, length: 4 ) \ No newline at end of file
+ span.label.label-default.line = line.number || truncate( line.name, length: 4 )
diff --git a/app/views/stop_areas/show.html.slim b/app/views/stop_areas/show.html.slim
index 249e29a57..06ca09dd5 100644
--- a/app/views/stop_areas/show.html.slim
+++ b/app/views/stop_areas/show.html.slim
@@ -4,6 +4,9 @@
= @map.to_html if show_map?
.summary
+ - if @stop_area.deleted_at
+ p
+ label = @stop_area.human_attribute_name('deleted')
p
label = "#{@stop_area.human_attribute_name('comment')} : "
= @stop_area.comment
@@ -143,7 +146,7 @@ p.after_map
- if @stop_area.parent == nil
li
/ = link_to t('stop_areas.actions.clone_as_parent'), new_referential_stop_area_stop_area_copy_path(@referential, @stop_area, :hierarchy => "parent"), :class => "clone"
-
+
- if manage_children
li
/ = link_to t('stop_areas.actions.add_children'), add_children_referential_stop_area_path(@referential, @stop_area), :class => "children"
@@ -159,7 +162,7 @@ p.after_map
/ = link_to t('access_points.actions.new'), new_referential_stop_area_access_point_path(@referential,@stop_area), :class => "add"
li
/ = link_to t('stop_areas.actions.manage_access_links'), access_links_referential_stop_area_path(@referential,@stop_area), :class => "access_link"
-
+
br
-
- = creation_tag(@stop_area) \ No newline at end of file
+
+ = creation_tag(@stop_area)
diff --git a/config/locales/stop_areas.en.yml b/config/locales/stop_areas.en.yml
index a556916bf..4197daaa2 100644
--- a/config/locales/stop_areas.en.yml
+++ b/config/locales/stop_areas.en.yml
@@ -81,6 +81,7 @@ en:
name: "Name"
registration_number: "Registration number"
published_name: "Published name"
+ deleted: "Deleted"
comment: "Comments"
stop_area_type: "Area type"
nearest_topic_name: "Nearest point of interest"
diff --git a/config/locales/stop_areas.fr.yml b/config/locales/stop_areas.fr.yml
index 73e565d59..b552a3483 100644
--- a/config/locales/stop_areas.fr.yml
+++ b/config/locales/stop_areas.fr.yml
@@ -81,6 +81,7 @@ fr:
name: "Nom"
registration_number: "Numéro d'enregistrement"
published_name: "Nom public"
+ deleted: "Supprimé"
comment: "Commentaire"
stop_area_type: "Type d'arrêt"
nearest_topic_name: "Point d'intérêt le plus proche"