aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorZog2018-04-19 16:46:04 +0200
committerJohan Van Ryseghem2018-04-27 11:17:19 +0200
commitc495d4bb70b85db944a41be139c78c68c5623357 (patch)
tree626b0d6a531c3370c1e223831459d43e7d17f175
parente8e029da36b493827820289f8db50645eb939806 (diff)
downloadchouette-core-c495d4bb70b85db944a41be139c78c68c5623357.tar.bz2
Refs #6572; Updte wording
-rw-r--r--app/assets/stylesheets/base.sass4
-rw-r--r--app/helpers/referentials_helper.rb11
-rw-r--r--app/views/referentials/show.html.slim20
-rw-r--r--config/locales/actions.fr.yml4
4 files changed, 19 insertions, 20 deletions
diff --git a/app/assets/stylesheets/base.sass b/app/assets/stylesheets/base.sass
index 83d92076c..43831fb6b 100644
--- a/app/assets/stylesheets/base.sass
+++ b/app/assets/stylesheets/base.sass
@@ -16,3 +16,7 @@
// OL3
@import 'OpenLayers/ol'
+
+span.sb, span.fa
+ & + span
+ margin-left: 0.3em
diff --git a/app/helpers/referentials_helper.rb b/app/helpers/referentials_helper.rb
index c0a60410a..1f396d43a 100644
--- a/app/helpers/referentials_helper.rb
+++ b/app/helpers/referentials_helper.rb
@@ -25,14 +25,9 @@ module ReferentialsHelper
end.html_safe
end
- def referential_state referential
- out = if referential.archived?
- "<div class='td-block'><span class='fa fa-archive'></span><span>#{t('activerecord.attributes.referential.archived_at')}</span></div>"
- else
- "<div class='td-block'>#{"referentials.states.#{referential.state}".t}</div>"
- end
-
- out.html_safe
+ def referential_state referential, icon: true
+ state_icon = icon && icon_for_referential_state(@referential.state)
+ "<div class='td-block'>#{state_icon}<span>#{"referentials.states.#{referential.state}".t}</span></div>".html_safe
end
def referential_overview referential
diff --git a/app/views/referentials/show.html.slim b/app/views/referentials/show.html.slim
index 5849bc582..9785c074d 100644
--- a/app/views/referentials/show.html.slim
+++ b/app/views/referentials/show.html.slim
@@ -13,16 +13,16 @@
= definition_list t('metadatas'), attributes
- unless @referential.ready?
- - operation = @referential.last_operation
- .jumbotron
- = import_status(operation.status)
- - url = operation.is_a?(Import::Base) ? [operation.workbench, operation.parent || operation] : [@referential, operation]
- = link_to url do
- | &nbsp;
- span
- strong= operation.try(:name) || operation.created_at.l(format: :short)
- | &nbsp;
- span= "(#{operation.class.ts})"
+ - if operation = @referential.last_operation
+ .jumbotron
+ = import_status(operation.status)
+ - url = operation.is_a?(Import::Base) ? [operation.workbench, operation.parent || operation] : [@referential, operation]
+ = link_to url do
+ | &nbsp;
+ span
+ strong= operation.try(:name) || operation.created_at.l(format: :short)
+ | &nbsp;
+ span= "(#{operation.class.ts})"
- else
- if params[:q].present? or @reflines.any?
diff --git a/config/locales/actions.fr.yml b/config/locales/actions.fr.yml
index ed1a86189..9e1a132a7 100644
--- a/config/locales/actions.fr.yml
+++ b/config/locales/actions.fr.yml
@@ -13,8 +13,8 @@ fr:
remove: Retirer
new: 'Créer'
show: 'Consulter'
- archive: 'Conserver'
- unarchive: 'Déconserver'
+ archive: 'Archiver'
+ unarchive: 'Désarchiver'
clone: 'Dupliquer'
duplicate: 'Dupliquer'
clean_up: 'Purger'