diff --git a/app/helpers/application_helper.rb b/app/helpers/application_helper.rb index 3f69732afd..acf5335c1c 100644 --- a/app/helpers/application_helper.rb +++ b/app/helpers/application_helper.rb @@ -107,14 +107,14 @@ def error_message_alert end def onts_for_select(include_views: false) - ontologies ||= LinkedData::Client::Models::Ontology.all({include: "acronym,name", include_views: include_views}) + ontologies ||= LinkedData::Client::Models::Ontology.all({include: "acronym,name,viewOf", include_views: include_views}) onts_for_select = [['', '']] ontologies.each do |ont| next if ( ont.acronym.nil? or ont.acronym.empty? ) acronym = ont.acronym name = ont.name abbreviation = acronym.empty? ? "" : "(#{acronym})" - ont_label = "#{name.strip} #{abbreviation}" + ont_label = "#{name.strip} #{abbreviation}#{ont.viewOf ? ' [view]' : ''}" onts_for_select << [ont_label, acronym] end onts_for_select.sort! { |a,b| a[0].downcase <=> b[0].downcase } diff --git a/app/views/ontologies/ontologies_selector/ontologies_selector_results.html.haml b/app/views/ontologies/ontologies_selector/ontologies_selector_results.html.haml index 2aeafa23df..9bd25a770a 100644 --- a/app/views/ontologies/ontologies_selector/ontologies_selector_results.html.haml +++ b/app/views/ontologies/ontologies_selector/ontologies_selector_results.html.haml @@ -2,7 +2,7 @@ .ontologies-selector-results .horizontal-line .results-number - = t("ontologies.showing_ontologies_size", ontologies_size: @ontologies.length, analytics_size: @total_ontologies_number) + = t("ontologies.showing_ontologies_size", ontologies_size: @ontologies.length, analytics_size: @total_ontologies_number, portals: portal_name) %span.select-all{'data-action': 'click->ontologies-selector#selectall'} = t('ontologies_selector.select_all') .ontologies