From 8cba00a0c7ccb1a003d5324c7ebc6f0f3b0e2f40 Mon Sep 17 00:00:00 2001 From: j2blake Date: Wed, 23 Oct 2013 09:41:21 -0400 Subject: [PATCH 01/16] Line-end characters --- .../testrunner/selenium/how-to-create-firefox-profile.txt | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/utilities/testrunner/selenium/how-to-create-firefox-profile.txt b/utilities/testrunner/selenium/how-to-create-firefox-profile.txt index 0c5af1d1d..03007d63f 100644 --- a/utilities/testrunner/selenium/how-to-create-firefox-profile.txt +++ b/utilities/testrunner/selenium/how-to-create-firefox-profile.txt @@ -1,3 +1,3 @@ -Here is an excellent description of how to create a Firefox profile for use when running Selenium tests. - +Here is an excellent description of how to create a Firefox profile for use when running Selenium tests. + http://girliemangalo.wordpress.com/2009/02/05/creating-firefox-profile-for-your-selenium-rc-tests/ \ No newline at end of file From 876f1d65dba57e017b8ba64c1fc7849911d88201 Mon Sep 17 00:00:00 2001 From: j2blake Date: Wed, 23 Oct 2013 09:51:20 -0400 Subject: [PATCH 02/16] VIVO-383 don't list every file graph at startup. Also, use shorter, relative paths when listing RDF files loaded. --- .../webapp/servlet/setup/FileGraphSetup.java | 2 +- .../webapp/servlet/setup/RDFFilesLoader.java | 15 ++++++++++++--- 2 files changed, 13 insertions(+), 4 deletions(-) diff --git a/webapp/src/edu/cornell/mannlib/vitro/webapp/servlet/setup/FileGraphSetup.java b/webapp/src/edu/cornell/mannlib/vitro/webapp/servlet/setup/FileGraphSetup.java index a58a52386..72f1fef71 100644 --- a/webapp/src/edu/cornell/mannlib/vitro/webapp/servlet/setup/FileGraphSetup.java +++ b/webapp/src/edu/cornell/mannlib/vitro/webapp/servlet/setup/FileGraphSetup.java @@ -174,7 +174,7 @@ public class FileGraphSetup implements ServletContextListener { if ( !model.isEmpty() ) { baseModel.addSubModel(model); - log.info("Attached file graph as " + type + " submodel " + p.getFileName()); + log.debug("Attached file graph as " + type + " submodel " + p.getFileName()); } modelChanged = modelChanged | updateGraphInDB(dataset, model, type, p); diff --git a/webapp/src/edu/cornell/mannlib/vitro/webapp/servlet/setup/RDFFilesLoader.java b/webapp/src/edu/cornell/mannlib/vitro/webapp/servlet/setup/RDFFilesLoader.java index f01b5b244..89b6dbfe6 100644 --- a/webapp/src/edu/cornell/mannlib/vitro/webapp/servlet/setup/RDFFilesLoader.java +++ b/webapp/src/edu/cornell/mannlib/vitro/webapp/servlet/setup/RDFFilesLoader.java @@ -87,14 +87,23 @@ public class RDFFilesLoader { OntModel model) { OntModel everytimeModel = ModelFactory .createOntologyModel(OntModelSpec.OWL_MEM); - Set paths = getPaths(locateHomeDirectory(ctx), RDF, modelPath, - EVERY_TIME); + String home = locateHomeDirectory(ctx); + Set paths = getPaths(home, RDF, modelPath, EVERY_TIME); for (Path p : paths) { + log.info("Loading " + relativePath(p, home)); readOntologyFileIntoModel(p, everytimeModel); } model.addSubModel(everytimeModel); } + private static Path relativePath(Path p, String home) { + try { + return Paths.get(home).relativize(p); + } catch (Exception e) { + return p; + } + } + /** * Create a model from all the RDF files in the specified directory. */ @@ -148,7 +157,7 @@ public class RDFFilesLoader { private static void readOntologyFileIntoModel(Path p, Model model) { String format = getRdfFormat(p); - log.info("Loading "+ p); + log.debug("Loading "+ p); try (InputStream stream = new FileInputStream(p.toFile())) { model.read(stream, null, format); log.debug("...successful"); From 3c896785221b5bc6abf581b583fd4251dc767dac Mon Sep 17 00:00:00 2001 From: j2blake Date: Wed, 23 Oct 2013 09:41:21 -0400 Subject: [PATCH 03/16] Line-end characters --- .../testrunner/selenium/how-to-create-firefox-profile.txt | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/utilities/testrunner/selenium/how-to-create-firefox-profile.txt b/utilities/testrunner/selenium/how-to-create-firefox-profile.txt index 0c5af1d1d..03007d63f 100644 --- a/utilities/testrunner/selenium/how-to-create-firefox-profile.txt +++ b/utilities/testrunner/selenium/how-to-create-firefox-profile.txt @@ -1,3 +1,3 @@ -Here is an excellent description of how to create a Firefox profile for use when running Selenium tests. - +Here is an excellent description of how to create a Firefox profile for use when running Selenium tests. + http://girliemangalo.wordpress.com/2009/02/05/creating-firefox-profile-for-your-selenium-rc-tests/ \ No newline at end of file From 4ce41fb6ed5bfc9c84f288ed3e1a7f3af17362e1 Mon Sep 17 00:00:00 2001 From: tworrall Date: Wed, 23 Oct 2013 13:11:46 -0400 Subject: [PATCH 04/16] VIVO-397 --- .../individual-property-group-menus.ftl | 9 ++- .../individual-property-group-tabs.ftl | 56 ++++++++++--------- 2 files changed, 35 insertions(+), 30 deletions(-) diff --git a/webapp/web/templates/freemarker/body/partials/individual/individual-property-group-menus.ftl b/webapp/web/templates/freemarker/body/partials/individual/individual-property-group-menus.ftl index 0cd78b2b0..df68bbd06 100644 --- a/webapp/web/templates/freemarker/body/partials/individual/individual-property-group-menus.ftl +++ b/webapp/web/templates/freemarker/body/partials/individual/individual-property-group-menus.ftl @@ -4,7 +4,6 @@ <#import "lib-properties.ftl" as p> <#assign subjectUri = individual.controlPanelUrl()?split("=") > -<#assign nameForOtherGroup = nameForOtherGroup!"other"> <#if (propertyGroups.all)??> <#assign groups = propertyGroups.all> @@ -13,6 +12,7 @@ - - + + <#list propertyGroups.all as group> + <#if (group.properties?size > 0)> <#assign groupName = group.getName(nameForOtherGroup)> <#assign verbose = (verbosePropertySwitch.currentValue)!false> @@ -50,4 +52,5 @@ <#-- List the properties in the group --> <#include "individual-properties.ftl"> + diff --git a/webapp/web/templates/freemarker/body/partials/individual/individual-property-group-tabs.ftl b/webapp/web/templates/freemarker/body/partials/individual/individual-property-group-tabs.ftl index bb9bd9dc8..2c8d83e27 100644 --- a/webapp/web/templates/freemarker/body/partials/individual/individual-property-group-tabs.ftl +++ b/webapp/web/templates/freemarker/body/partials/individual/individual-property-group-tabs.ftl @@ -11,14 +11,14 @@
  •  
  • <#list propertyGroups.all as groupTabs> <#if ( groupTabs.properties?size > 0 ) > - <#assign groupName = groupTabs.getName(nameForOtherGroup)> - <#if groupName?has_content> - <#--the function replaces spaces in the name with underscores, also called for the property group menu--> - <#assign groupNameHtmlId = p.createPropertyGroupHtmlId(groupName) > - <#else> - <#assign groupName = "${i18n().properties_capitalized}"> - <#assign groupNameHtmlId = "${i18n().properties}" > - + <#assign groupName = groupTabs.getName(nameForOtherGroup)> + <#if groupName?has_content> + <#--the function replaces spaces in the name with underscores, also called for the property group menu--> + <#assign groupNameHtmlId = p.createPropertyGroupHtmlId(groupName) > + <#else> + <#assign groupName = "${i18n().properties_capitalized}"> + <#assign groupNameHtmlId = "${i18n().properties}" > + <#if tabCount = 1 >
  • ${groupName?capitalize}
  •  
  • @@ -35,30 +35,32 @@ <#list propertyGroups.all as group> - <#assign groupName = group.getName(nameForOtherGroup)> - <#assign groupNameHtmlId = p.createPropertyGroupHtmlId(groupName) > - <#assign verbose = (verbosePropertySwitch.currentValue)!false> -
    - + <#if (group.properties?size > 0)> + <#assign groupName = group.getName(nameForOtherGroup)> + <#assign groupNameHtmlId = p.createPropertyGroupHtmlId(groupName) > + <#assign verbose = (verbosePropertySwitch.currentValue)!false> +
    + - <#-- Display the group heading --> - <#if groupName?has_content> - <#--the function replaces spaces in the name with underscores, also called for the property group menu--> - <#assign groupNameHtmlId = p.createPropertyGroupHtmlId(groupName) > - - <#else> - - + <#-- Display the group heading --> + <#if groupName?has_content> + <#--the function replaces spaces in the name with underscores, also called for the property group menu--> + <#assign groupNameHtmlId = p.createPropertyGroupHtmlId(groupName) > + + <#else> + +
    <#-- List the properties in the group --> <#include "individual-properties.ftl">
    -
    -<#assign sectionCount = 2 > +
    + <#assign sectionCount = 2 > +