From 5ba226bde722f7902f5a24767d07231e4885f66c Mon Sep 17 00:00:00 2001 From: Graham Triggs Date: Wed, 13 Sep 2017 20:27:27 +0100 Subject: [PATCH] [VIVO-1367] Update AGROVOC URL --- .../service/impl/AgrovocService.java | 6 +- .../edit/forms/addAssociatedConcept.ftl | 62 +++++++++++-------- 2 files changed, 38 insertions(+), 30 deletions(-) diff --git a/api/src/main/java/edu/cornell/mannlib/semservices/service/impl/AgrovocService.java b/api/src/main/java/edu/cornell/mannlib/semservices/service/impl/AgrovocService.java index baa43e56..0639b9c4 100644 --- a/api/src/main/java/edu/cornell/mannlib/semservices/service/impl/AgrovocService.java +++ b/api/src/main/java/edu/cornell/mannlib/semservices/service/impl/AgrovocService.java @@ -58,9 +58,9 @@ public class AgrovocService implements ExternalConceptService { protected final String dbpedia_endpoint = " http://dbpedia.org/sparql"; // URL to get all the information for a concept - protected final String conceptSkosMosBase = "http://aims.fao.org/skosmos/rest/v1/"; + protected final String conceptSkosMosBase = "http://artemide.art.uniroma2.it:8081/skosmos/rest/v1/"; protected final String conceptsSkosMosSearch = conceptSkosMosBase + "search?"; - protected final String conceptSkosMosURL = conceptSkosMosBase + "/agrovoc/data?"; + protected final String conceptSkosMosURL = conceptSkosMosBase + "data?"; @Override public List getConcepts(String term) throws Exception { List conceptList = new ArrayList(); @@ -145,7 +145,7 @@ public class AgrovocService implements ExternalConceptService { - + public List processResults(String term) throws Exception { diff --git a/webapp/src/main/webapp/templates/freemarker/edit/forms/addAssociatedConcept.ftl b/webapp/src/main/webapp/templates/freemarker/edit/forms/addAssociatedConcept.ftl index 495fa259..23f5ede3 100644 --- a/webapp/src/main/webapp/templates/freemarker/edit/forms/addAssociatedConcept.ftl +++ b/webapp/src/main/webapp/templates/freemarker/edit/forms/addAssociatedConcept.ftl @@ -42,40 +42,48 @@ <#if (existingConcepts?size > 0)>
  • -
    -
    -

    Concept (Type)

    -
    -
    -

    Vocabulary Source

    -
    -
      -
    -
    +
    +
    +
    +
    +

    Concept (Type)

    +
    +
    +

    Vocabulary Source

    +
    +
      +
    +
    +
    +
  • <#list existingConcepts as existingConcept>
  • +
    -
    ${existingConcept.conceptLabel} - <#if existingConcept.conceptSemanticTypeLabel?has_content> - (${existingConcept.conceptSemanticTypeLabel}) - -
    -
    - <#if existingConcept.vocabURI?has_content && existingConcept.vocabLabel?has_content> - ${existingConcept.vocabLabel} - <#else> -   - <#--We still want the column to be there even if no vocabulary source is present--> - -
    - +
    +
    ${existingConcept.conceptLabel} + <#if existingConcept.conceptSemanticTypeLabel?has_content> + (${existingConcept.conceptSemanticTypeLabel}) + +
    +
    + <#if existingConcept.vocabURI?has_content && existingConcept.vocabLabel?has_content> + ${existingConcept.vocabLabel} + <#else> +   + <#--We still want the column to be there even if no vocabulary source is present--> + +
    + +
    +