From 85fd390cb808a9346c16ed1b0d5dc63380bd0d1f Mon Sep 17 00:00:00 2001 From: Piet Schijven Date: Fri, 24 Nov 2023 12:32:17 +0100 Subject: [PATCH] Removed the text "translation is missing for " for pref_labels without a translation in the current locale. --- app/models/label/base.rb | 4 ---- app/views/partials/concept/_edit_link_base.html.erb | 4 ++-- 2 files changed, 2 insertions(+), 6 deletions(-) diff --git a/app/models/label/base.rb b/app/models/label/base.rb index bf61696b5..28a83b740 100644 --- a/app/models/label/base.rb +++ b/app/models/label/base.rb @@ -126,10 +126,6 @@ def to_literal end def to_s - if (language.presence || 'none') != I18n.locale.to_s - value.to_s + " [#{I18n.t('txt.common.translation_missing_for')} '#{I18n.locale}']" - else value.to_s - end end end diff --git a/app/views/partials/concept/_edit_link_base.html.erb b/app/views/partials/concept/_edit_link_base.html.erb index 25fd446eb..99ecbfb1c 100644 --- a/app/views/partials/concept/_edit_link_base.html.erb +++ b/app/views/partials/concept/_edit_link_base.html.erb @@ -1,5 +1,5 @@ -<% label = item.pref_label.to_s.presence || ":#{item.origin} [#{t("txt.common.translation_missing_for")} #{[I18n.locale.to_s, Iqvoc::Concept.pref_labeling_languages.first.to_s].uniq.join(", ")}]" %> +<% label = item.pref_label.to_s.presence || ":#{item.origin}" %> <%= link_to truncate(label, :length => 45), (item.published? ? concept_path(:id => item.origin) : concept_path(:published => 0, :id => item.origin)) %> -<%- if (item.additional_info) -%> +<%- if item.additional_info -%> (<%= item.additional_info %>) <%- end -%>