Merge branch 'develop' of https://github.com/vivo-project/VIVO into develop
This commit is contained in:
commit
e572c423de
10 changed files with 343 additions and 493 deletions
|
@ -185,21 +185,21 @@ issuing SPARQL queries that read data, and its URI for issuing SPARQL UPDATE com
|
||||||
<ul>
|
<ul>
|
||||||
<li>
|
<li>
|
||||||
Mac:
|
Mac:
|
||||||
<ul>
|
<ul>
|
||||||
<li>Chrome 8.0.552.237</li>
|
<li>Chrome 30.0.1599.69 and above</li>
|
||||||
<li>FireFox 3.6.13</li>
|
<li>FireFox 3.6.28, 10.0.12, 24</li>
|
||||||
<li>Opera 10.6.2</li>
|
<li>Opera 12.02</li>
|
||||||
<li>Safari 5.0.3</li>
|
<li>Safari 5.0.3</li>
|
||||||
</ul>
|
</ul>
|
||||||
</li>
|
</li>
|
||||||
<li>
|
<li>
|
||||||
PC:
|
PC:
|
||||||
<ul>
|
<ul>
|
||||||
<li>Chrome 8.0.552.273</li>
|
<li>Chrome 25.1364.2 and above</li>
|
||||||
<li>FireFox 10.0.2</li>
|
<li>FireFox 10.0.12, 24</li>
|
||||||
<li>Internet Explorer 7, 8, 9</li>
|
<li>Internet Explorer 8, 9, 10</li>
|
||||||
<li>Opera 10.6.2</li>
|
<li>Opera 12.02</li>
|
||||||
</ul>
|
</ul>
|
||||||
</li>
|
</li>
|
||||||
</ul>
|
</ul>
|
||||||
|
|
||||||
|
|
|
@ -439,21 +439,21 @@ rdf/tbox/filegraph/tbox/vivo-skos-1.5.owl</pre>
|
||||||
<p>
|
<p>
|
||||||
Mac:
|
Mac:
|
||||||
</p>
|
</p>
|
||||||
<ul>
|
<ul>
|
||||||
<li>Chrome 8.0.552.237</li>
|
<li>Chrome 30.0.1599.69 and above</li>
|
||||||
<li>FireFox 3.6.13</li>
|
<li>FireFox 3.6.28, 10.0.12, 24</li>
|
||||||
<li>Opera 10.6.2</li>
|
<li>Opera 12.02</li>
|
||||||
<li>Safari 5.0.3</li>
|
<li>Safari 5.0.3</li>
|
||||||
</ul>
|
</ul>
|
||||||
<p>
|
</li>
|
||||||
PC:
|
<li>
|
||||||
</p>
|
PC:
|
||||||
<ul>
|
<ul>
|
||||||
<li>Chrome 8.0.552.273</li>
|
<li>Chrome 25.1364.2 and above</li>
|
||||||
<li>FireFox 10.0.2</li>
|
<li>FireFox 10.0.12, 24</li>
|
||||||
<li>Internet Explorer 7, 8, 9</li>
|
<li>Internet Explorer 8, 9, 10</li>
|
||||||
<li>Opera 10.6.2</li>
|
<li>Opera 12.02</li>
|
||||||
</ul>
|
</ul>
|
||||||
</li>
|
</li>
|
||||||
</ul>
|
</ul>
|
||||||
|
|
||||||
|
|
|
@ -1,39 +1,39 @@
|
||||||
<#-- $This file is distributed under the terms of the license in /doc/license.txt$ -->
|
<#-- $This file is distributed under the terms of the license in /doc/license.txt$ -->
|
||||||
<#import "lib-datetime.ftl" as dt>
|
<#import "lib-datetime.ftl" as dt>
|
||||||
|
|
||||||
<#if deptGrants?has_content>
|
<#if deptGrants?has_content>
|
||||||
<section id="pageList">
|
<section id="pageList">
|
||||||
<#list deptGrants as firstRow>
|
<#list deptGrants as firstRow>
|
||||||
<#assign firstDeptLabel = firstRow["deptLabel"]?upper_case />
|
<#assign firstDeptLabel = firstRow["deptLabel"]?upper_case />
|
||||||
<#assign i18TextString = "" />
|
<#assign i18TextString = "" />
|
||||||
<#if ( firstDeptLabel?index_of("THE") == 0 ) >
|
<#if ( firstDeptLabel?index_of("THE") == 0 ) >
|
||||||
<#assign i18TextString = "${i18n().active_grants_for?replace('the','')}" />
|
<#assign i18TextString = "${i18n().active_grants_for?replace('the','')}" />
|
||||||
<#else>
|
<#else>
|
||||||
<#assign i18TextString = "${i18n().active_grants_for}" />
|
<#assign i18TextString = "${i18n().active_grants_for}" />
|
||||||
</#if>
|
</#if>
|
||||||
<h2>${i18TextString} ${firstRow["deptLabel"]} ${i18n().department}</h2>
|
<h2>${i18TextString} ${firstRow["deptLabel"]} ${i18n().department}</h2>
|
||||||
<#break>
|
<#break>
|
||||||
</#list>
|
</#list>
|
||||||
<table id="pageList" >
|
<table id="pageList" >
|
||||||
<tr>
|
<tr>
|
||||||
<th>${i18n().grant_name}</th>
|
<th>${i18n().grant_name}</th>
|
||||||
<th>${i18n().close_date}</th>
|
<th>${i18n().close_date}</th>
|
||||||
</tr>
|
</tr>
|
||||||
<#list deptGrants as resultRow>
|
<#list deptGrants as resultRow>
|
||||||
<tr>
|
<tr>
|
||||||
<td><a href="${urls.base}/individual${resultRow["activity"]?substring(resultRow["activity"]?last_index_of("/"))}" title="${i18n().activity_name}">${resultRow["activityLabel"]}</a></td>
|
<td><a href="${urls.base}/individual${resultRow["grant"]?substring(resultRow["grant"]?last_index_of("/"))}" title="${i18n().grant_name}">${resultRow["grantLabel"]}</a></td>
|
||||||
<td>${dt.formatXsdDateTimeShort(resultRow["dt"], "yearMonthDayPrecision")}</td>
|
<td>${dt.formatXsdDateTimeShort(resultRow["dt"], "yearMonthDayPrecision")}</td>
|
||||||
</tr>
|
</tr>
|
||||||
</#list>
|
</#list>
|
||||||
</table>
|
</table>
|
||||||
<#else>
|
<#else>
|
||||||
${i18n().no_active_grants}
|
${i18n().no_active_grants}
|
||||||
</#if>
|
</#if>
|
||||||
|
|
||||||
</section>
|
</section>
|
||||||
|
|
||||||
|
|
||||||
${stylesheets.add('<link rel="stylesheet" href="${urls.base}/css/menupage/pageList.css" />')}
|
${stylesheets.add('<link rel="stylesheet" href="${urls.base}/css/menupage/pageList.css" />')}
|
||||||
|
|
||||||
${scripts.add('<script type="text/javascript" src="${urls.base}/js/browserUtils.js"></script>')}
|
${scripts.add('<script type="text/javascript" src="${urls.base}/js/browserUtils.js"></script>')}
|
||||||
|
|
||||||
|
|
|
@ -1,193 +1,193 @@
|
||||||
<#-- $This file is distributed under the terms of the license in /doc/license.txt$ -->
|
<#-- $This file is distributed under the terms of the license in /doc/license.txt$ -->
|
||||||
<#import "lib-vivo-form.ftl" as lvf>
|
<#import "lib-vivo-form.ftl" as lvf>
|
||||||
<#include "addAssociatedConceptVocabSpecificDisplay.ftl" >
|
<#include "addAssociatedConceptVocabSpecificDisplay.ftl" >
|
||||||
<#assign existingConcepts = editConfiguration.pageData.existingConcepts/>
|
<#assign existingConcepts = editConfiguration.pageData.existingConcepts/>
|
||||||
<#assign userDefinedConceptUrl = editConfiguration.pageData.userDefinedConceptUrl/>
|
<#assign userDefinedConceptUrl = editConfiguration.pageData.userDefinedConceptUrl/>
|
||||||
<#assign sources = editConfiguration.pageData.searchServices/>
|
<#assign sources = editConfiguration.pageData.searchServices/>
|
||||||
<#assign inversePredicate = editConfiguration.pageData.inversePredicate />
|
<#assign inversePredicate = editConfiguration.pageData.inversePredicate />
|
||||||
|
|
||||||
<#--If edit submission exists, then retrieve validation errors if they exist-->
|
<#--If edit submission exists, then retrieve validation errors if they exist-->
|
||||||
<#if editSubmission?has_content && editSubmission.submissionExists = true && editSubmission.validationErrors?has_content>
|
<#if editSubmission?has_content && editSubmission.submissionExists = true && editSubmission.validationErrors?has_content>
|
||||||
<#assign submissionErrors = editSubmission.validationErrors/>
|
<#assign submissionErrors = editSubmission.validationErrors/>
|
||||||
</#if>
|
</#if>
|
||||||
|
|
||||||
|
|
||||||
<h2>${i18n().manage_concepts}</h2>
|
<h2>${i18n().manage_concepts}</h2>
|
||||||
|
|
||||||
|
|
||||||
<#if submissionErrors?has_content>
|
<#if submissionErrors?has_content>
|
||||||
<section id="error-alert" role="alert">
|
<section id="error-alert" role="alert">
|
||||||
<img src="${urls.images}/iconAlert.png" width="24" height="24" alert="${i18n().error_alert_icon}" />
|
<img src="${urls.images}/iconAlert.png" width="24" height="24" alert="${i18n().error_alert_icon}" />
|
||||||
<p>
|
<p>
|
||||||
<#--below shows examples of both printing out all error messages and checking the error message for a specific field-->
|
<#--below shows examples of both printing out all error messages and checking the error message for a specific field-->
|
||||||
<#list submissionErrors?keys as errorFieldName>
|
<#list submissionErrors?keys as errorFieldName>
|
||||||
${errorFieldName} : ${submissionErrors[errorFieldName]}
|
${errorFieldName} : ${submissionErrors[errorFieldName]}
|
||||||
</#list>
|
</#list>
|
||||||
|
|
||||||
|
|
||||||
</p>
|
</p>
|
||||||
</section>
|
</section>
|
||||||
</#if>
|
</#if>
|
||||||
|
|
||||||
<@lvf.unsupportedBrowser urls.base/>
|
<@lvf.unsupportedBrowser urls.base/>
|
||||||
|
|
||||||
<div class="noIE67">
|
<div class="noIE67">
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
<ul id="existingConcepts">
|
<ul id="existingConcepts">
|
||||||
|
|
||||||
<script type="text/javascript">
|
<script type="text/javascript">
|
||||||
var existingConceptsData = [];
|
var existingConceptsData = [];
|
||||||
</script>
|
</script>
|
||||||
<#if (existingConcepts?size > 0)>
|
<#if (existingConcepts?size > 0)>
|
||||||
<li class="conceptHeadings conceptsListContainer">
|
<li class="conceptHeadings conceptsListContainer">
|
||||||
<div class="row">
|
<div class="row">
|
||||||
<div class="column conceptLabelInfo">
|
<div class="column conceptLabelInfo">
|
||||||
<h4>Concept (Type)</h4>
|
<h4>Concept (Type)</h4>
|
||||||
</div>
|
</div>
|
||||||
<div class="column conceptVocabSource">
|
<div class="column conceptVocabSource">
|
||||||
<h4>Vocabulary Source</h4>
|
<h4>Vocabulary Source</h4>
|
||||||
</div>
|
</div>
|
||||||
<div class="column conceptRemoval">
|
<div class="column conceptRemoval">
|
||||||
</div>
|
</div>
|
||||||
</div>
|
</div>
|
||||||
</li>
|
</li>
|
||||||
</#if>
|
</#if>
|
||||||
|
|
||||||
<#list existingConcepts as existingConcept>
|
<#list existingConcepts as existingConcept>
|
||||||
<li class="existingConcept conceptsListContainer">
|
<li class="existingConcept conceptsListContainer">
|
||||||
<div class="row">
|
<div class="row">
|
||||||
<div class="column conceptLabelInfo"> ${existingConcept.conceptLabel}
|
<div class="column conceptLabelInfo"> ${existingConcept.conceptLabel}
|
||||||
<#if existingConcept.conceptSemanticTypeLabel?has_content>
|
<#if existingConcept.conceptSemanticTypeLabel?has_content>
|
||||||
(${existingConcept.conceptSemanticTypeLabel})
|
(${existingConcept.conceptSemanticTypeLabel})
|
||||||
</#if>
|
</#if>
|
||||||
</div>
|
</div>
|
||||||
<div class="column conceptVocabSource">
|
<div class="column conceptVocabSource">
|
||||||
<#if existingConcept.vocabURI?has_content && existingConcept.vocabLabel?has_content>
|
<#if existingConcept.vocabURI?has_content && existingConcept.vocabLabel?has_content>
|
||||||
${existingConcept.vocabLabel}
|
${existingConcept.vocabLabel}
|
||||||
</#if>
|
</#if>
|
||||||
</div>
|
</div>
|
||||||
<div class="column conceptRemoval">
|
<div class="column conceptRemoval">
|
||||||
<a href="${urls.base}/edit/primitiveRdfEdit" class="remove" title="${i18n().remove_capitalized}">${i18n().remove_capitalized}</a>
|
<a href="${urls.base}/edit/primitiveRdfEdit" class="remove" title="${i18n().remove_capitalized}">${i18n().remove_capitalized}</a>
|
||||||
|
|
||||||
</div>
|
</div>
|
||||||
</div>
|
</div>
|
||||||
</li>
|
</li>
|
||||||
|
|
||||||
<script type="text/javascript">
|
<script type="text/javascript">
|
||||||
existingConceptsData.push({
|
existingConceptsData.push({
|
||||||
"conceptNodeUri": "${existingConcept.conceptURI}",
|
"conceptNodeUri": "${existingConcept.conceptURI}",
|
||||||
"conceptLabel": "${existingConcept.conceptLabel}"
|
"conceptLabel": "${existingConcept.conceptLabel}"
|
||||||
});
|
});
|
||||||
</script>
|
</script>
|
||||||
|
|
||||||
</#list>
|
</#list>
|
||||||
|
|
||||||
</ul>
|
</ul>
|
||||||
|
|
||||||
|
|
||||||
<#if (existingConcepts?size = 0) >
|
<#if (existingConcepts?size = 0) >
|
||||||
<p>${i18n().no_concepts_specified}</p>
|
<p>${i18n().no_concepts_specified}</p>
|
||||||
<#else>
|
<#else>
|
||||||
|
|
||||||
</#if>
|
</#if>
|
||||||
|
|
||||||
<div id="showAddForm">
|
<div id="showAddForm">
|
||||||
|
|
||||||
<input type="submit" value="${i18n().add_concept}" id="showAddFormButton" name="showAddFormButton"> ${i18n().or}
|
<input type="submit" value="${i18n().add_concept}" id="showAddFormButton" name="showAddFormButton"> ${i18n().or}
|
||||||
<a class="cancel" href="${cancelUrl}&url=/individual" title="${i18n().return_to_profile}">${i18n().return_to_profile}</a>
|
<a class="cancel" href="${cancelUrl}&url=/individual" title="${i18n().return_to_profile}">${i18n().return_to_profile}</a>
|
||||||
</div>
|
</div>
|
||||||
<form id="addConceptForm" class="customForm" action="${submitUrl}">
|
<form id="addConceptForm" class="customForm" action="${submitUrl}">
|
||||||
<#assign checkedSource = false />
|
<#assign checkedSource = false />
|
||||||
<h4 class="services">${i18n().external_vocabulary_services}</h4>
|
<h4 class="services">${i18n().external_vocabulary_services}</h4>
|
||||||
<#list sources?values?sort_by("label") as thisSource>
|
<#list sources?values?sort_by("label") as thisSource>
|
||||||
<input type="radio" name="source" value="${thisSource.schema}" role="radio" <#if checkedSource = false><#assign checkedSource = true/>checked="checked"</#if>>
|
<input type="radio" name="source" value="${thisSource.schema}" role="radio" <#if checkedSource = false><#assign checkedSource = true/>checked="checked"</#if>>
|
||||||
<label class="inline" for="${thisSource.label}"> <a href="${thisSource.url}">${thisSource.label}</a> (${thisSource.description})</label>
|
<label class="inline" for="${thisSource.label}"> <a href="${thisSource.url}">${thisSource.label}</a> (${thisSource.description})</label>
|
||||||
<br />
|
<br />
|
||||||
</#list>
|
</#list>
|
||||||
<p class="inline-search">
|
<p class="inline-search">
|
||||||
<input type="text" id="searchTerm" label="Search" class="acSelector" size="35" />
|
<input type="text" id="searchTerm" label="Search" class="acSelector" size="35" />
|
||||||
<input type="button" class="submit concept-search" id="searchButton" name="searchButton" value="${i18n().search_button}"/>
|
<input type="button" class="submit concept-search" id="searchButton" name="searchButton" value="${i18n().search_button}"/>
|
||||||
</p><span id="createOwnOne"> ${i18n().or} <a href="${userDefinedConceptUrl}" title="${i18n().create_own_concept}">${i18n().create_own_concept} </a></span>
|
</p><span id="createOwnOne"> ${i18n().or} <a href="${userDefinedConceptUrl}" title="${i18n().create_own_concept}">${i18n().create_own_concept} </a></span>
|
||||||
<input type="hidden" id="conceptNode" name="conceptNode" value=""/> <!-- Field value populated by JavaScript -->
|
<input type="hidden" id="conceptNode" name="conceptNode" value=""/> <!-- Field value populated by JavaScript -->
|
||||||
<input type="hidden" id="conceptLabel" name="conceptLabel" value="" /> <!-- Field value populated by JavaScript -->
|
<input type="hidden" id="conceptLabel" name="conceptLabel" value="" /> <!-- Field value populated by JavaScript -->
|
||||||
<input type="hidden" id="conceptSource" name="conceptSource" value="" /> <!-- Field value populated by JavaScript -->
|
<input type="hidden" id="conceptSource" name="conceptSource" value="" /> <!-- Field value populated by JavaScript -->
|
||||||
<input type="hidden" id="conceptSemanticTypeURI" name="conceptSemanticTypeURI" value="" /> <!-- Field value populated by JavaScript -->
|
<input type="hidden" id="conceptSemanticTypeURI" name="conceptSemanticTypeURI" value="" /> <!-- Field value populated by JavaScript -->
|
||||||
<input type="hidden" id="conceptSemanticTypeLabel" name="conceptSemanticTypeLabel" value="" /> <!-- Field value populated by JavaScript -->
|
<input type="hidden" id="conceptSemanticTypeLabel" name="conceptSemanticTypeLabel" value="" /> <!-- Field value populated by JavaScript -->
|
||||||
<input type="hidden" id="conceptBroaderURI" name="conceptBroaderURI" value=""/><!-- Field value populated by JavaScript -->
|
<input type="hidden" id="conceptBroaderURI" name="conceptBroaderURI" value=""/><!-- Field value populated by JavaScript -->
|
||||||
<input type="hidden" id="conceptNarrowerURI" name="conceptNarrowerURI" value=""/><!-- Field value populated by JavaScript -->
|
<input type="hidden" id="conceptNarrowerURI" name="conceptNarrowerURI" value=""/><!-- Field value populated by JavaScript -->
|
||||||
<div id="indicator" class="hidden">
|
<div id="indicator" class="hidden">
|
||||||
<img id="loadingIndicator" class="indicator" src="${urls.base}/images/indicatorWhite.gif" alt="${i18n().processing_indicator}"/>
|
<img id="loadingIndicator" class="indicator" src="${urls.base}/images/indicatorWhite.gif" alt="${i18n().processing_indicator}"/>
|
||||||
</div>
|
</div>
|
||||||
<div id="selectedConcept" name="selectedConcept" class="acSelection">
|
<div id="selectedConcept" name="selectedConcept" class="acSelection">
|
||||||
<p class="inline">
|
<p class="inline">
|
||||||
|
|
||||||
</p>
|
</p>
|
||||||
|
|
||||||
<!-- Search results populated by JavaScript -->
|
<!-- Search results populated by JavaScript -->
|
||||||
</div>
|
</div>
|
||||||
<div id="showHideResults" name="showHideResults">
|
<div id="showHideResults" name="showHideResults">
|
||||||
<a class="more-less" href="#show more content" id="showHideLink" title="${i18n().show_more_content}">
|
<a class="more-less" href="#show more content" id="showHideLink" title="${i18n().show_more_content}">
|
||||||
</a>
|
</a>
|
||||||
</div>
|
</div>
|
||||||
<div id="errors" name="errors"></div>
|
<div id="errors" name="errors"></div>
|
||||||
|
|
||||||
<input type="hidden" name="editKey" id="editKey" value="${editKey}"/>
|
<input type="hidden" name="editKey" id="editKey" value="${editKey}"/>
|
||||||
<p class="submit">
|
<p class="submit">
|
||||||
<input type="submit" id="submit" name="submit" value="${i18n().add_selected_concept}" />
|
<input type="submit" id="submit" name="submit" value="${i18n().add_selected_concept}" />
|
||||||
|
|
||||||
</p>
|
</p>
|
||||||
<div id="createOwnTwo"><br />
|
<div id="createOwnTwo"><br />
|
||||||
<a href="${userDefinedConceptUrl}" > ${i18n().cannot_find_concept}</a>
|
<a href="${userDefinedConceptUrl}" > ${i18n().cannot_find_concept}</a>
|
||||||
|
|
||||||
</div>
|
</div>
|
||||||
<p>
|
<p>
|
||||||
<span class="or"> ${i18n().or} </span><a class="cancel" href="${cancelUrl}&url=/individual" title="${i18n().return_to_profile}">${i18n().return_to_profile}</a>
|
<span class="or"> ${i18n().or} </span><a class="cancel" href="${cancelUrl}&url=/individual" title="${i18n().return_to_profile}">${i18n().return_to_profile}</a>
|
||||||
</p>
|
</p>
|
||||||
</form>
|
</form>
|
||||||
</div>
|
</div>
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
<script type="text/javascript">
|
<script type="text/javascript">
|
||||||
var customFormData = {
|
var customFormData = {
|
||||||
dataServiceUrl: '${urls.base}/conceptSearchService',
|
dataServiceUrl: '${urls.base}/conceptSearchService',
|
||||||
subjectUri: '${editConfiguration.subjectUri}',
|
subjectUri: '${editConfiguration.subjectUri}',
|
||||||
predicateUri: '${editConfiguration.predicateUri}',
|
predicateUri: '${editConfiguration.predicateUri}',
|
||||||
inversePredicateUri: '${inversePredicate}'
|
inversePredicateUri: '${inversePredicate}'
|
||||||
};
|
};
|
||||||
var vocabSpecificDisplay = {};
|
var vocabSpecificDisplay = {};
|
||||||
<#list vocabSpecificDisplay?keys as vocab>
|
<#list vocabSpecificDisplay?keys as vocab>
|
||||||
vocabSpecificDisplay["${vocab}"] = "${vocabSpecificDisplay[vocab]}";
|
vocabSpecificDisplay["${vocab}"] = "${vocabSpecificDisplay[vocab]}";
|
||||||
</#list>
|
</#list>
|
||||||
var i18nStrings = {
|
var i18nStrings = {
|
||||||
vocServiceUnavailable: '${i18n().vocabulary_service_error}',
|
vocServiceUnavailable: '${i18n().vocabulary_service_unavailable}',
|
||||||
noResultsFound: '${i18n().no_serch_results_found}',
|
noResultsFound: '${i18n().no_serch_results_found}',
|
||||||
defaultLabelTypeString: '${i18n().label_type}',
|
defaultLabelTypeString: '${i18n().label_type}',
|
||||||
definitionString: '${i18n().definition_capitalized}',
|
definitionString: '${i18n().definition_capitalized}',
|
||||||
bestMatchString: '${i18n().best_match}',
|
bestMatchString: '${i18n().best_match}',
|
||||||
selectTermFromResults: '${i18n().select_term_from_results}',
|
selectTermFromResults: '${i18n().select_term_from_results}',
|
||||||
selectVocSource: '${i18n().select_vocabulary_source_to_search}',
|
selectVocSource: '${i18n().select_vocabulary_source_to_search}',
|
||||||
confirmTermDelete: '${i18n().confirm_term_deletion}',
|
confirmTermDelete: '${i18n().confirm_term_deletion}',
|
||||||
errorTernNotRemoved: '${i18n().error_term_not_deleted}',
|
errorTernNotRemoved: '${i18n().error_term_not_deleted}',
|
||||||
vocabSpecificLabels: vocabSpecificDisplay,
|
vocabSpecificLabels: vocabSpecificDisplay,
|
||||||
displayMoreEllipsis: '${i18n().display_more_ellipsis}',
|
displayMoreEllipsis: '${i18n().display_more_ellipsis}',
|
||||||
displayLess: '${i18n().display_less}',
|
displayLess: '${i18n().display_less}',
|
||||||
showMoreContent: '${i18n().show_more_content}'
|
showMoreContent: '${i18n().show_more_content}'
|
||||||
};
|
};
|
||||||
</script>
|
</script>
|
||||||
|
|
||||||
${stylesheets.add('<link rel="stylesheet" href="${urls.base}/js/jquery-ui/css/smoothness/jquery-ui-1.8.9.custom.css" />')}
|
${stylesheets.add('<link rel="stylesheet" href="${urls.base}/js/jquery-ui/css/smoothness/jquery-ui-1.8.9.custom.css" />')}
|
||||||
${stylesheets.add('<link rel="stylesheet" href="${urls.base}/templates/freemarker/edit/forms/css/customForm.css" />')}
|
${stylesheets.add('<link rel="stylesheet" href="${urls.base}/templates/freemarker/edit/forms/css/customForm.css" />')}
|
||||||
|
|
||||||
${stylesheets.add('<link rel="stylesheet" href="${urls.base}/templates/freemarker/edit/forms/css/addConcept.css" />')}
|
${stylesheets.add('<link rel="stylesheet" href="${urls.base}/templates/freemarker/edit/forms/css/addConcept.css" />')}
|
||||||
${scripts.add('<script type="text/javascript" src="${urls.base}/js/jquery-ui/js/jquery-ui-1.8.9.custom.min.js"></script>')}
|
${scripts.add('<script type="text/javascript" src="${urls.base}/js/jquery-ui/js/jquery-ui-1.8.9.custom.min.js"></script>')}
|
||||||
${scripts.add('<script type="text/javascript" src="${urls.base}/js/json2.js"></script>')}
|
${scripts.add('<script type="text/javascript" src="${urls.base}/js/json2.js"></script>')}
|
||||||
${scripts.add('<script type="text/javascript" src="${urls.base}/js/customFormUtils.js"></script>')}
|
${scripts.add('<script type="text/javascript" src="${urls.base}/js/customFormUtils.js"></script>')}
|
||||||
${scripts.add('<script type="text/javascript" src="${urls.base}/js/browserUtils.js"></script>')}
|
${scripts.add('<script type="text/javascript" src="${urls.base}/js/browserUtils.js"></script>')}
|
||||||
${scripts.add('<script type="text/javascript" src="${urls.base}/templates/freemarker/edit/forms/js/addConcept.js"></script>')}
|
${scripts.add('<script type="text/javascript" src="${urls.base}/templates/freemarker/edit/forms/js/addConcept.js"></script>')}
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
|
@ -1,86 +0,0 @@
|
||||||
<#-- $This file is distributed under the terms of the license in /doc/license.txt$ -->
|
|
||||||
|
|
||||||
<#-- this is in request.subject.name -->
|
|
||||||
|
|
||||||
<#-- leaving this edit/add mode code in for reference in case we decide we need it -->
|
|
||||||
|
|
||||||
<#import "lib-vivo-form.ftl" as lvf>
|
|
||||||
|
|
||||||
<#--Retrieve certain edit configuration information-->
|
|
||||||
<#if editConfiguration.objectUri?has_content>
|
|
||||||
<#assign editMode = "edit">
|
|
||||||
<#else>
|
|
||||||
<#assign editMode = "add">
|
|
||||||
</#if>
|
|
||||||
|
|
||||||
<#assign htmlForElements = editConfiguration.pageData.htmlForElements />
|
|
||||||
|
|
||||||
<#--Retrieve variables needed-->
|
|
||||||
<#assign telephoneNumberValue = lvf.getFormFieldValue(editSubmission, editConfiguration, "telephoneNumber") />
|
|
||||||
|
|
||||||
<#--If edit submission exists, then retrieve validation errors if they exist-->
|
|
||||||
<#if editSubmission?has_content && editSubmission.submissionExists = true && editSubmission.validationErrors?has_content>
|
|
||||||
<#assign submissionErrors = editSubmission.validationErrors/>
|
|
||||||
</#if>
|
|
||||||
|
|
||||||
<#if editMode == "edit">
|
|
||||||
<#assign titleVerb="${i18n().edit_capitalized}">
|
|
||||||
<#assign submitButtonText="${titleVerb}" + " ${i18n().telephone_number}">
|
|
||||||
<#assign disabledVal="disabled">
|
|
||||||
<#else>
|
|
||||||
<#assign titleVerb="${i18n().create_capitalized}">
|
|
||||||
<#assign submitButtonText="${titleVerb}" + " ${i18n().telephone_number}">
|
|
||||||
<#assign disabledVal=""/>
|
|
||||||
</#if>
|
|
||||||
|
|
||||||
<#assign requiredHint = "<span class='requiredHint'> *</span>" />
|
|
||||||
|
|
||||||
<h2>${titleVerb} ${i18n().telephone_number_for} ${editConfiguration.subjectName}</h2>
|
|
||||||
|
|
||||||
<#--Display error messages if any-->
|
|
||||||
<#if submissionErrors?has_content>
|
|
||||||
<section id="error-alert" role="alert">
|
|
||||||
<img src="${urls.images}/iconAlert.png" width="24" height="24" alert="${i18n().error_alert_icon}" />
|
|
||||||
<p>
|
|
||||||
<#--Checking if any required fields are empty-->
|
|
||||||
<#if lvf.submissionErrorExists(editSubmission, "telephoneNumber")>
|
|
||||||
${i18n().enter_telephone_number}<br />
|
|
||||||
</#if>
|
|
||||||
</p>
|
|
||||||
</section>
|
|
||||||
</#if>
|
|
||||||
|
|
||||||
<@lvf.unsupportedBrowser urls.base />
|
|
||||||
|
|
||||||
<section id="personHasTelephoneNumber" role="region">
|
|
||||||
|
|
||||||
<form id="personHasTelephoneNumber" class="customForm noIE67" action="${submitUrl}" role="add/edit phone">
|
|
||||||
|
|
||||||
<p>
|
|
||||||
<label for="telephoneNumber">${i18n().telephone_number} ${requiredHint}</label>
|
|
||||||
<input size="25" type="text" id="telephoneNumber" name="telephoneNumber" value="${telephoneNumberValue}" />
|
|
||||||
</p>
|
|
||||||
|
|
||||||
<input type="hidden" id="editKey" name="editKey" value="${editKey}"/>
|
|
||||||
|
|
||||||
<p class="submit">
|
|
||||||
<input type="submit" id="submit" value="${submitButtonText}"/><span class="or"> ${i18n().or} </span>
|
|
||||||
<a class="cancel" href="${cancelUrl}" title="${i18n().cancel_title}">${i18n().cancel_link}</a>
|
|
||||||
</p>
|
|
||||||
|
|
||||||
<p id="requiredLegend" class="requiredHint">* ${i18n().required_fields}</p>
|
|
||||||
|
|
||||||
</form>
|
|
||||||
|
|
||||||
</section>
|
|
||||||
|
|
||||||
${stylesheets.add('<link rel="stylesheet" href="${urls.base}/js/jquery-ui/css/smoothness/jquery-ui-1.8.9.custom.css" />')}
|
|
||||||
${stylesheets.add('<link rel="stylesheet" href="${urls.base}/templates/freemarker/edit/forms/css/customForm.css" />')}
|
|
||||||
${stylesheets.add('<link rel="stylesheet" href="${urls.base}/templates/freemarker/edit/forms/css/customFormWithAutocomplete.css" />')}
|
|
||||||
|
|
||||||
${scripts.add('<script type="text/javascript" src="${urls.base}/js/jquery-ui/js/jquery-ui-1.8.9.custom.min.js"></script>',
|
|
||||||
'<script type="text/javascript" src="${urls.base}/js/extensions/String.js"></script>',
|
|
||||||
'<script type="text/javascript" src="${urls.base}/js/browserUtils.js"></script>',
|
|
||||||
'<script type="text/javascript" src="${urls.base}/js/jquery_plugins/jquery.bgiframe.pack.js"></script>')}
|
|
||||||
|
|
||||||
|
|
|
@ -476,7 +476,7 @@ local:orgFaxContext a :ConfigContext ;
|
||||||
local:orgFaxConfig a :ObjectPropertyDisplayConfig ;
|
local:orgFaxConfig a :ObjectPropertyDisplayConfig ;
|
||||||
:listViewConfigFile "listViewConfig-faxNumber.xml"^^xsd:string ;
|
:listViewConfigFile "listViewConfig-faxNumber.xml"^^xsd:string ;
|
||||||
:displayName "fax" ;
|
:displayName "fax" ;
|
||||||
vitro:displayRankAnnot 10;
|
vitro:displayRankAnnot 20;
|
||||||
vitro:hiddenFromDisplayBelowRoleLevelAnnot role:public ;
|
vitro:hiddenFromDisplayBelowRoleLevelAnnot role:public ;
|
||||||
vitro:prohibitedFromUpdateBelowRoleLevelAnnot role:public ;
|
vitro:prohibitedFromUpdateBelowRoleLevelAnnot role:public ;
|
||||||
vitro:customEntryFormAnnot "edu.cornell.mannlib.vitro.webapp.edit.n3editing.configuration.generators.SubjectHasPhoneFaxNumberGenerator"^^<http://www.w3.org/2001/XMLSchema#string> ;
|
vitro:customEntryFormAnnot "edu.cornell.mannlib.vitro.webapp.edit.n3editing.configuration.generators.SubjectHasPhoneFaxNumberGenerator"^^<http://www.w3.org/2001/XMLSchema#string> ;
|
||||||
|
@ -688,3 +688,18 @@ local:grantRelatesConfig a :ObjectPropertyDisplayConfig ;
|
||||||
vitro:hiddenFromDisplayBelowRoleLevelAnnot role:public ;
|
vitro:hiddenFromDisplayBelowRoleLevelAnnot role:public ;
|
||||||
vitro:prohibitedFromUpdateBelowRoleLevelAnnot role:public ;
|
vitro:prohibitedFromUpdateBelowRoleLevelAnnot role:public ;
|
||||||
:propertyGroup <http://vivoweb.org/ontology#vitroPropertyGroupbiography> .
|
:propertyGroup <http://vivoweb.org/ontology#vitroPropertyGroupbiography> .
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
local:testRemovalContext a :ConfigContext ;
|
||||||
|
:hasConfiguration local:testRemovalConfig ;
|
||||||
|
:configContextFor <http://purl.obolibrary.org/obo/RO_0000053> ;
|
||||||
|
:qualifiedByDomain <http://xmlns.com/foaf/0.1/Person> ;
|
||||||
|
:qualifiedBy <http://purl.obolibrary.org/obo/BFO_0000001> .
|
||||||
|
|
||||||
|
local:testRemovalConfig a :ObjectPropertyDisplayConfig ;
|
||||||
|
:listViewConfigFile "listViewConfig-default.xml"^^xsd:string ;
|
||||||
|
:displayName "related by" ;
|
||||||
|
vitro:hiddenFromDisplayBelowRoleLevelAnnot role:root ;
|
||||||
|
vitro:prohibitedFromUpdateBelowRoleLevelAnnot role:root ;
|
||||||
|
:propertyGroup <http://vivoweb.org/ontology#vitroPropertyGroupother> .
|
||||||
|
|
|
@ -20,3 +20,6 @@ local:authorInAuthorshipConfig a :ObjectPropertyDisplayConfig ;
|
||||||
|
|
||||||
local:informationResourceInAuthorshipConfig a :ObjectPropertyDisplayConfig ;
|
local:informationResourceInAuthorshipConfig a :ObjectPropertyDisplayConfig ;
|
||||||
:deleteLinkSuppressed "true"^^xsd:boolean .
|
:deleteLinkSuppressed "true"^^xsd:boolean .
|
||||||
|
|
||||||
|
local:informationResourceInEditorshipConfig a :ObjectPropertyDisplayConfig ;
|
||||||
|
:deleteLinkSuppressed "true"^^xsd:boolean .
|
||||||
|
|
|
@ -25,11 +25,14 @@ display:getDepartmentDataGetter
|
||||||
PREFIX rdfs: <http://www.w3.org/2000/01/rdf-schema#>
|
PREFIX rdfs: <http://www.w3.org/2000/01/rdf-schema#>
|
||||||
PREFIX vivo: <http://vivoweb.org/ontology/core#>
|
PREFIX vivo: <http://vivoweb.org/ontology/core#>
|
||||||
PREFIX afn: <http://jena.hpl.hp.com/ARQ/function#>
|
PREFIX afn: <http://jena.hpl.hp.com/ARQ/function#>
|
||||||
|
PREFIX foaf: <http://xmlns.com/foaf/0.1/>
|
||||||
SELECT DISTINCT (str(?departmentLabel) AS ?deptLabel) ?dept
|
SELECT DISTINCT (str(?departmentLabel) AS ?deptLabel) ?dept
|
||||||
WHERE {
|
WHERE {
|
||||||
?individualURI vivo:researchAreaOf ?person .
|
?individualURI vivo:researchAreaOf ?person .
|
||||||
?person vivo:personInPosition ?posn .
|
?person vivo:relatedBy ?posn .
|
||||||
?posn vivo:positionInOrganization ?dept .
|
?posn a vivo:Position .
|
||||||
|
?posn vivo:relates ?dept .
|
||||||
|
?dept a foaf:Organization .
|
||||||
?dept rdfs:label ?departmentLabel
|
?dept rdfs:label ?departmentLabel
|
||||||
OPTIONAL { ?posn vivo:dateTimeInterval ?dti
|
OPTIONAL { ?posn vivo:dateTimeInterval ?dti
|
||||||
OPTIONAL { ?dti vivo:end ?end .
|
OPTIONAL { ?dti vivo:end ?end .
|
||||||
|
@ -44,19 +47,20 @@ display:getDepartmentDataGetter
|
||||||
|
|
||||||
## detail page for dept research areas ##
|
## detail page for dept research areas ##
|
||||||
|
|
||||||
<http://vitro.mannlib.cornell.edu/ns/default#n55553333>
|
<http://vitro.mannlib.cornell.edu/ns/default/page#AffiliatedDepartments>
|
||||||
a <http://vitro.mannlib.cornell.edu/ontologies/display/1.1#Page> ;
|
a <http://vitro.mannlib.cornell.edu/ontologies/display/1.1#Page> ;
|
||||||
<http://vitro.mannlib.cornell.edu/ontologies/display/1.1#hasDataGetter> <http://vitro.mannlib.cornell.edu/ns/default#n55552222> ;
|
<http://vitro.mannlib.cornell.edu/ontologies/display/1.1#hasDataGetter> <http://vitro.mannlib.cornell.edu/ns/default/datagetter#AffiliatedDepartmentsDG> ;
|
||||||
<http://vitro.mannlib.cornell.edu/ontologies/display/1.1#requiresBodyTemplate> "individual-affiliated-dept-details.ftl" ;
|
<http://vitro.mannlib.cornell.edu/ontologies/display/1.1#requiresBodyTemplate> "individual-affiliated-dept-details.ftl" ;
|
||||||
<http://vitro.mannlib.cornell.edu/ontologies/display/1.1#title> "Affiliated Departments" ;
|
<http://vitro.mannlib.cornell.edu/ontologies/display/1.1#title> "Affiliated Departments" ;
|
||||||
<http://vitro.mannlib.cornell.edu/ontologies/display/1.1#urlMapping> "/affiliatedDepartments" .
|
<http://vitro.mannlib.cornell.edu/ontologies/display/1.1#urlMapping> "/affiliatedDepartments" .
|
||||||
|
|
||||||
<http://vitro.mannlib.cornell.edu/ns/default#n55552222>
|
<http://vitro.mannlib.cornell.edu/ns/default/datagetter#AffiliatedDepartmentsDG>
|
||||||
a <java:edu.cornell.mannlib.vitro.webapp.utils.dataGetter.SparqlQueryDataGetter> ;
|
a <java:edu.cornell.mannlib.vitro.webapp.utils.dataGetter.SparqlQueryDataGetter> ;
|
||||||
<http://vitro.mannlib.cornell.edu/ontologies/display/1.1#query>
|
<http://vitro.mannlib.cornell.edu/ontologies/display/1.1#query>
|
||||||
"""
|
"""
|
||||||
PREFIX rdfs: <http://www.w3.org/2000/01/rdf-schema#>
|
PREFIX rdfs: <http://www.w3.org/2000/01/rdf-schema#>
|
||||||
PREFIX vivo: <http://vivoweb.org/ontology/core#>
|
PREFIX vivo: <http://vivoweb.org/ontology/core#>
|
||||||
|
PREFIX foaf: <http://xmlns.com/foaf/0.1/>
|
||||||
SELECT DISTINCT (str (?prsnLabel) AS ?personLabel)
|
SELECT DISTINCT (str (?prsnLabel) AS ?personLabel)
|
||||||
?person
|
?person
|
||||||
(Str(?researchAreaLabel) AS ?raLabel)
|
(Str(?researchAreaLabel) AS ?raLabel)
|
||||||
|
@ -64,9 +68,11 @@ display:getDepartmentDataGetter
|
||||||
?raURI
|
?raURI
|
||||||
?orgURI
|
?orgURI
|
||||||
WHERE {
|
WHERE {
|
||||||
?orgURI vivo:organizationForPosition ?posn .
|
?orgURI vivo:relatedBy ?posn .
|
||||||
|
?posn a vivo:Position .
|
||||||
?orgURI rdfs:label ?orgLabel .
|
?orgURI rdfs:label ?orgLabel .
|
||||||
?posn vivo:positionForPerson ?person .
|
?posn vivo:relates ?person .
|
||||||
|
?person a foaf:Person .
|
||||||
?person rdfs:label ?prsnLabel .
|
?person rdfs:label ?prsnLabel .
|
||||||
?person vivo:hasResearchArea ?raURI .
|
?person vivo:hasResearchArea ?raURI .
|
||||||
?raURI rdfs:label ?researchAreaLabel
|
?raURI rdfs:label ?researchAreaLabel
|
||||||
|
|
|
@ -32,10 +32,13 @@ display:getResearchAreaDataGetter
|
||||||
PREFIX rdfs: <http://www.w3.org/2000/01/rdf-schema#>
|
PREFIX rdfs: <http://www.w3.org/2000/01/rdf-schema#>
|
||||||
PREFIX vivo: <http://vivoweb.org/ontology/core#>
|
PREFIX vivo: <http://vivoweb.org/ontology/core#>
|
||||||
PREFIX afn: <http://jena.hpl.hp.com/ARQ/function#>
|
PREFIX afn: <http://jena.hpl.hp.com/ARQ/function#>
|
||||||
|
PREFIX foaf: <http://xmlns.com/foaf/0.1/>
|
||||||
SELECT DISTINCT (str(?researchAreaLabel) AS ?raLabel) ?ra
|
SELECT DISTINCT (str(?researchAreaLabel) AS ?raLabel) ?ra
|
||||||
WHERE {
|
WHERE {
|
||||||
?individualURI vivo:organizationForPosition ?posn .
|
?individualURI vivo:relatedBy ?posn .
|
||||||
?posn vivo:positionForPerson ?person .
|
?posn a vivo:Position .
|
||||||
|
?posn vivo:relates ?person .
|
||||||
|
?person a foaf:Person .
|
||||||
?person vivo:hasResearchArea ?ra .
|
?person vivo:hasResearchArea ?ra .
|
||||||
?ra rdfs:label ?researchAreaLabel
|
?ra rdfs:label ?researchAreaLabel
|
||||||
OPTIONAL { ?posn vivo:dateTimeInterval ?dti
|
OPTIONAL { ?posn vivo:dateTimeInterval ?dti
|
||||||
|
@ -51,19 +54,20 @@ display:getResearchAreaDataGetter
|
||||||
|
|
||||||
## detail page for non-academic department research areas ##
|
## detail page for non-academic department research areas ##
|
||||||
|
|
||||||
<http://vitro.mannlib.cornell.edu/ns/default#n55550000>
|
<http://vitro.mannlib.cornell.edu/ns/default/page#AffiliatedResearchAreas>
|
||||||
a <http://vitro.mannlib.cornell.edu/ontologies/display/1.1#Page> ;
|
a <http://vitro.mannlib.cornell.edu/ontologies/display/1.1#Page> ;
|
||||||
<http://vitro.mannlib.cornell.edu/ontologies/display/1.1#hasDataGetter> <http://vitro.mannlib.cornell.edu/ns/default#n55551111> ;
|
<http://vitro.mannlib.cornell.edu/ontologies/display/1.1#hasDataGetter> <http://vitro.mannlib.cornell.edu/ns/default/datagetter#AffiliatedResearchAreasDG> ;
|
||||||
<http://vitro.mannlib.cornell.edu/ontologies/display/1.1#requiresBodyTemplate> "individual-affiliated-res-area-details.ftl" ;
|
<http://vitro.mannlib.cornell.edu/ontologies/display/1.1#requiresBodyTemplate> "individual-affiliated-res-area-details.ftl" ;
|
||||||
<http://vitro.mannlib.cornell.edu/ontologies/display/1.1#title> "Affiliated Research Areas" ;
|
<http://vitro.mannlib.cornell.edu/ontologies/display/1.1#title> "Affiliated Research Areas" ;
|
||||||
<http://vitro.mannlib.cornell.edu/ontologies/display/1.1#urlMapping> "/affiliatedResearchAreas" .
|
<http://vitro.mannlib.cornell.edu/ontologies/display/1.1#urlMapping> "/affiliatedResearchAreas" .
|
||||||
|
|
||||||
<http://vitro.mannlib.cornell.edu/ns/default#n55551111>
|
<http://vitro.mannlib.cornell.edu/ns/default/datagetter#AffiliatedResearchAreasDG>
|
||||||
a <java:edu.cornell.mannlib.vitro.webapp.utils.dataGetter.SparqlQueryDataGetter> ;
|
a <java:edu.cornell.mannlib.vitro.webapp.utils.dataGetter.SparqlQueryDataGetter> ;
|
||||||
<http://vitro.mannlib.cornell.edu/ontologies/display/1.1#query>
|
<http://vitro.mannlib.cornell.edu/ontologies/display/1.1#query>
|
||||||
"""
|
"""
|
||||||
PREFIX rdfs: <http://www.w3.org/2000/01/rdf-schema#>
|
PREFIX rdfs: <http://www.w3.org/2000/01/rdf-schema#>
|
||||||
PREFIX vivo: <http://vivoweb.org/ontology/core#>
|
PREFIX vivo: <http://vivoweb.org/ontology/core#>
|
||||||
|
PREFIX foaf: <http://xmlns.com/foaf/0.1/>
|
||||||
SELECT DISTINCT (str (?prsnLabel) AS ?personLabel)
|
SELECT DISTINCT (str (?prsnLabel) AS ?personLabel)
|
||||||
?person
|
?person
|
||||||
(str(?researchAreaLabel) AS ?raLabel)
|
(str(?researchAreaLabel) AS ?raLabel)
|
||||||
|
@ -71,9 +75,11 @@ display:getResearchAreaDataGetter
|
||||||
?raURI
|
?raURI
|
||||||
?orgURI
|
?orgURI
|
||||||
WHERE {
|
WHERE {
|
||||||
?orgURI vivo:organizationForPosition ?posn .
|
?orgURI vivo:relatedBy ?posn .
|
||||||
|
?posn a vivo:Position .
|
||||||
?orgURI rdfs:label ?organizationLabel .
|
?orgURI rdfs:label ?organizationLabel .
|
||||||
?posn vivo:positionForPerson ?person .
|
?posn vivo:relates ?person .
|
||||||
|
?person a foaf:Person .
|
||||||
?person rdfs:label ?prsnLabel .
|
?person rdfs:label ?prsnLabel .
|
||||||
?person vivo:hasResearchArea ?raURI .
|
?person vivo:hasResearchArea ?raURI .
|
||||||
?raURI rdfs:label ?researchAreaLabel
|
?raURI rdfs:label ?researchAreaLabel
|
||||||
|
@ -84,19 +90,20 @@ display:getResearchAreaDataGetter
|
||||||
|
|
||||||
## detail page for academic department research areas ##
|
## detail page for academic department research areas ##
|
||||||
|
|
||||||
<http://vitro.mannlib.cornell.edu/ns/default#n5100>
|
<http://vitro.mannlib.cornell.edu/ns/default/page#DepartmentalResearchAreas>
|
||||||
a <http://vitro.mannlib.cornell.edu/ontologies/display/1.1#Page> ;
|
a <http://vitro.mannlib.cornell.edu/ontologies/display/1.1#Page> ;
|
||||||
<http://vitro.mannlib.cornell.edu/ontologies/display/1.1#hasDataGetter> <http://vitro.mannlib.cornell.edu/ns/default#n3450> ;
|
<http://vitro.mannlib.cornell.edu/ontologies/display/1.1#hasDataGetter> <http://vitro.mannlib.cornell.edu/ns/default/datagetter#DepartmentalResearchAreasDG> ;
|
||||||
<http://vitro.mannlib.cornell.edu/ontologies/display/1.1#requiresBodyTemplate> "individual-dept-res-area-details.ftl" ;
|
<http://vitro.mannlib.cornell.edu/ontologies/display/1.1#requiresBodyTemplate> "individual-dept-res-area-details.ftl" ;
|
||||||
<http://vitro.mannlib.cornell.edu/ontologies/display/1.1#title> "Departmental Research Areas" ;
|
<http://vitro.mannlib.cornell.edu/ontologies/display/1.1#title> "Departmental Research Areas" ;
|
||||||
<http://vitro.mannlib.cornell.edu/ontologies/display/1.1#urlMapping> "/deptResearchAreas" .
|
<http://vitro.mannlib.cornell.edu/ontologies/display/1.1#urlMapping> "/deptResearchAreas" .
|
||||||
|
|
||||||
<http://vitro.mannlib.cornell.edu/ns/default#n3450>
|
<http://vitro.mannlib.cornell.edu/ns/default/datagetter#DepartmentalResearchAreasDG>
|
||||||
a <java:edu.cornell.mannlib.vitro.webapp.utils.dataGetter.SparqlQueryDataGetter> ;
|
a <java:edu.cornell.mannlib.vitro.webapp.utils.dataGetter.SparqlQueryDataGetter> ;
|
||||||
<http://vitro.mannlib.cornell.edu/ontologies/display/1.1#query>
|
<http://vitro.mannlib.cornell.edu/ontologies/display/1.1#query>
|
||||||
"""
|
"""
|
||||||
PREFIX rdfs: <http://www.w3.org/2000/01/rdf-schema#>
|
PREFIX rdfs: <http://www.w3.org/2000/01/rdf-schema#>
|
||||||
PREFIX vivo: <http://vivoweb.org/ontology/core#>
|
PREFIX vivo: <http://vivoweb.org/ontology/core#>
|
||||||
|
PREFIX foaf: <http://xmlns.com/foaf/0.1/>
|
||||||
SELECT DISTINCT (str (?prsnLabel) AS ?personLabel)
|
SELECT DISTINCT (str (?prsnLabel) AS ?personLabel)
|
||||||
?person
|
?person
|
||||||
(Str(?researchAreaLabel) AS ?raLabel)
|
(Str(?researchAreaLabel) AS ?raLabel)
|
||||||
|
@ -104,9 +111,11 @@ display:getResearchAreaDataGetter
|
||||||
?raURI
|
?raURI
|
||||||
?orgURI
|
?orgURI
|
||||||
WHERE {
|
WHERE {
|
||||||
?orgURI vivo:organizationForPosition ?posn .
|
?orgURI vivo:relatedBy ?posn .
|
||||||
?orgURI rdfs:label ?orgLabel .
|
?posn a vivo:Position .
|
||||||
?posn vivo:positionForPerson ?person .
|
?orgURI rdfs:label ?organizationLabel .
|
||||||
|
?posn vivo:relates ?person .
|
||||||
|
?person a foaf:Person .
|
||||||
?person rdfs:label ?prsnLabel .
|
?person rdfs:label ?prsnLabel .
|
||||||
?person vivo:hasResearchArea ?raURI .
|
?person vivo:hasResearchArea ?raURI .
|
||||||
?raURI rdfs:label ?researchAreaLabel
|
?raURI rdfs:label ?researchAreaLabel
|
||||||
|
@ -134,14 +143,18 @@ display:getGrantsDataGetter
|
||||||
PREFIX rdfs: <http://www.w3.org/2000/01/rdf-schema#>
|
PREFIX rdfs: <http://www.w3.org/2000/01/rdf-schema#>
|
||||||
PREFIX vivo: <http://vivoweb.org/ontology/core#>
|
PREFIX vivo: <http://vivoweb.org/ontology/core#>
|
||||||
PREFIX afn: <http://jena.hpl.hp.com/ARQ/function#>
|
PREFIX afn: <http://jena.hpl.hp.com/ARQ/function#>
|
||||||
SELECT DISTINCT ?activity
|
PREFIX foaf: <http://xmlns.com/foaf/0.1/>
|
||||||
|
SELECT DISTINCT ?grant
|
||||||
WHERE {
|
WHERE {
|
||||||
?individualURI vivo:organizationForPosition ?posn .
|
?individualURI vivo:relatedBy ?posn .
|
||||||
?posn vivo:positionForPerson ?person .
|
?posn a vivo:Position .
|
||||||
?person ?roleProperty ?role .
|
?posn vivo:relates ?person .
|
||||||
?roleProperty rdfs:subPropertyOf vivo:hasResearcherRole .
|
?person a foaf:Person .
|
||||||
?role vivo:roleContributesTo ?activity .
|
?person <http://purl.obolibrary.org/obo/RO_0000053> ?role .
|
||||||
?activity vivo:dateTimeInterval ?dti .
|
?role a vivo:ResearcherRole .
|
||||||
|
?role vivo:relatedBy ?grant .
|
||||||
|
?grant a vivo:Grant .
|
||||||
|
?grant vivo:dateTimeInterval ?dti .
|
||||||
?dti vivo:end ?end.
|
?dti vivo:end ?end.
|
||||||
?end vivo:dateTime ?dt
|
?end vivo:dateTime ?dt
|
||||||
FILTER (?dt > afn:now())
|
FILTER (?dt > afn:now())
|
||||||
|
@ -151,35 +164,39 @@ display:getGrantsDataGetter
|
||||||
|
|
||||||
## data getter for the grants detail page ##
|
## data getter for the grants detail page ##
|
||||||
|
|
||||||
<http://vitro.mannlib.cornell.edu/ns/default#n1697>
|
<http://vitro.mannlib.cornell.edu/ns/default/page#DepartmentalGrants>
|
||||||
a <http://vitro.mannlib.cornell.edu/ontologies/display/1.1#Page> ;
|
a <http://vitro.mannlib.cornell.edu/ontologies/display/1.1#Page> ;
|
||||||
<http://vitro.mannlib.cornell.edu/ontologies/display/1.1#hasDataGetter> <http://vitro.mannlib.cornell.edu/ns/default#n4170> ;
|
<http://vitro.mannlib.cornell.edu/ontologies/display/1.1#hasDataGetter> <http://vitro.mannlib.cornell.edu/ns/default/datagetter#DepartmentalGrantsDG> ;
|
||||||
<http://vitro.mannlib.cornell.edu/ontologies/display/1.1#requiresBodyTemplate> "individual-dept-active-grants.ftl" ;
|
<http://vitro.mannlib.cornell.edu/ontologies/display/1.1#requiresBodyTemplate> "individual-dept-active-grants.ftl" ;
|
||||||
<http://vitro.mannlib.cornell.edu/ontologies/display/1.1#title> "Departmental Grants" ;
|
<http://vitro.mannlib.cornell.edu/ontologies/display/1.1#title> "Departmental Grants" ;
|
||||||
<http://vitro.mannlib.cornell.edu/ontologies/display/1.1#urlMapping> "/deptGrants" .
|
<http://vitro.mannlib.cornell.edu/ontologies/display/1.1#urlMapping> "/deptGrants" .
|
||||||
|
|
||||||
<http://vitro.mannlib.cornell.edu/ns/default#n4170>
|
<http://vitro.mannlib.cornell.edu/ns/default/datagetter#DepartmentalGrantsDG>
|
||||||
a <java:edu.cornell.mannlib.vitro.webapp.utils.dataGetter.SparqlQueryDataGetter> ;
|
a <java:edu.cornell.mannlib.vitro.webapp.utils.dataGetter.SparqlQueryDataGetter> ;
|
||||||
<http://vitro.mannlib.cornell.edu/ontologies/display/1.1#query>
|
<http://vitro.mannlib.cornell.edu/ontologies/display/1.1#query>
|
||||||
"""
|
"""
|
||||||
PREFIX rdfs: <http://www.w3.org/2000/01/rdf-schema#>
|
PREFIX rdfs: <http://www.w3.org/2000/01/rdf-schema#>
|
||||||
PREFIX vivo: <http://vivoweb.org/ontology/core#>
|
PREFIX vivo: <http://vivoweb.org/ontology/core#>
|
||||||
PREFIX afn: <http://jena.hpl.hp.com/ARQ/function#>
|
PREFIX afn: <http://jena.hpl.hp.com/ARQ/function#>
|
||||||
SELECT DISTINCT (str (?actLabel) AS ?activityLabel) ?dt (str(?departmentLabel) AS ?deptLabel) ?activity
|
PREFIX foaf: <http://xmlns.com/foaf/0.1/>
|
||||||
|
SELECT DISTINCT (str (?gLabel) AS ?grantLabel) ?dt (str(?departmentLabel) AS ?deptLabel) ?grant
|
||||||
WHERE {
|
WHERE {
|
||||||
?individualURI vivo:organizationForPosition ?posn .
|
?individualURI vivo:relatedBy ?posn .
|
||||||
|
?posn a vivo:Position .
|
||||||
?individualURI rdfs:label ?departmentLabel .
|
?individualURI rdfs:label ?departmentLabel .
|
||||||
?posn vivo:positionForPerson ?person .
|
?posn vivo:relates ?person .
|
||||||
?person ?roleProperty ?role .
|
?person a foaf:Person .
|
||||||
?roleProperty rdfs:subPropertyOf vivo:hasResearcherRole .
|
?person <http://purl.obolibrary.org/obo/RO_0000053> ?role .
|
||||||
?role vivo:roleContributesTo ?activity .
|
?role a vivo:ResearcherRole .
|
||||||
?activity rdfs:label ?actLabel .
|
?role vivo:relatedBy ?grant .
|
||||||
?activity vivo:dateTimeInterval ?dti .
|
?grant a vivo:Grant .
|
||||||
|
?grant rdfs:label ?gLabel .
|
||||||
|
?grant vivo:dateTimeInterval ?dti .
|
||||||
?dti vivo:end ?end.
|
?dti vivo:end ?end.
|
||||||
?end vivo:dateTime ?dt
|
?end vivo:dateTime ?dt
|
||||||
FILTER (?dt > afn:now())
|
FILTER (?dt > afn:now())
|
||||||
}
|
}
|
||||||
ORDER BY ?activityLabel
|
ORDER BY ?gLabel
|
||||||
""" ;
|
""" ;
|
||||||
<http://vitro.mannlib.cornell.edu/ontologies/display/1.1#saveToVar> "deptGrants" .
|
<http://vitro.mannlib.cornell.edu/ontologies/display/1.1#saveToVar> "deptGrants" .
|
||||||
|
|
||||||
|
|
|
@ -1,105 +0,0 @@
|
||||||
/* $This file is distributed under the terms of the license in /doc/license.txt$ */
|
|
||||||
|
|
||||||
package edu.cornell.mannlib.vitro.webapp.edit.n3editing.configuration.generators;
|
|
||||||
|
|
||||||
import java.util.ArrayList;
|
|
||||||
import java.util.Arrays;
|
|
||||||
import java.util.Collections;
|
|
||||||
import java.util.HashMap;
|
|
||||||
import java.util.List;
|
|
||||||
import java.util.Map;
|
|
||||||
|
|
||||||
import javax.servlet.http.HttpSession;
|
|
||||||
|
|
||||||
import org.apache.commons.logging.Log;
|
|
||||||
import org.apache.commons.logging.LogFactory;
|
|
||||||
|
|
||||||
import com.hp.hpl.jena.vocabulary.XSD;
|
|
||||||
|
|
||||||
import edu.cornell.mannlib.vitro.webapp.controller.VitroRequest;
|
|
||||||
import edu.cornell.mannlib.vitro.webapp.dao.VitroVocabulary;
|
|
||||||
import edu.cornell.mannlib.vitro.webapp.edit.n3editing.VTwo.EditConfigurationUtils;
|
|
||||||
import edu.cornell.mannlib.vitro.webapp.edit.n3editing.VTwo.EditConfigurationVTwo;
|
|
||||||
import edu.cornell.mannlib.vitro.webapp.edit.n3editing.VTwo.fields.ChildVClassesOptions;
|
|
||||||
import edu.cornell.mannlib.vitro.webapp.edit.n3editing.VTwo.fields.FieldVTwo;
|
|
||||||
import edu.cornell.mannlib.vitro.webapp.edit.n3editing.VTwo.fields.IndividualsViaVClassOptions;
|
|
||||||
import edu.cornell.mannlib.vitro.webapp.edit.n3editing.configuration.validators.AntiXssValidation;
|
|
||||||
|
|
||||||
public class PersonHasTelephoneNumberGenerator extends VivoBaseGenerator implements
|
|
||||||
EditConfigurationGenerator {
|
|
||||||
private Log log = LogFactory.getLog(PersonHasTelephoneNumberGenerator.class);
|
|
||||||
|
|
||||||
@Override
|
|
||||||
public EditConfigurationVTwo getEditConfiguration(VitroRequest vreq,
|
|
||||||
HttpSession session) throws Exception {
|
|
||||||
|
|
||||||
EditConfigurationVTwo conf = new EditConfigurationVTwo();
|
|
||||||
|
|
||||||
initBasics(conf, vreq);
|
|
||||||
initPropertyParameters(vreq, session, conf);
|
|
||||||
initObjectPropForm(conf, vreq);
|
|
||||||
String phoneUri = getPhoneUri(vreq);
|
|
||||||
|
|
||||||
conf.setTemplate("personHasTelephoneNumber.ftl");
|
|
||||||
|
|
||||||
conf.setVarNameForSubject("person");
|
|
||||||
conf.setVarNameForPredicate("predicate");
|
|
||||||
conf.setVarNameForObject("individualVcard");
|
|
||||||
|
|
||||||
conf.setN3Required( Arrays.asList( n3ForNewPhone ) );
|
|
||||||
conf.setN3Optional( Arrays.asList( telephoneNumberAssertion ) );
|
|
||||||
|
|
||||||
conf.addNewResource("phone", DEFAULT_NS_FOR_NEW_RESOURCE);
|
|
||||||
conf.addNewResource("individualVcard", DEFAULT_NS_FOR_NEW_RESOURCE);
|
|
||||||
|
|
||||||
conf.setLiteralsOnForm(Arrays.asList("telephoneNumber" ));
|
|
||||||
|
|
||||||
conf.addSparqlForExistingLiteral("telephoneNumber", telephoneNumberQuery);
|
|
||||||
conf.addSparqlForAdditionalUrisInScope("individualVcard", individualVcardQuery);
|
|
||||||
|
|
||||||
if ( conf.isUpdate() ) {
|
|
||||||
HashMap<String, List<String>> urisInScope = new HashMap<String, List<String>>();
|
|
||||||
urisInScope.put("phone", Arrays.asList(new String[]{phoneUri}));
|
|
||||||
conf.addUrisInScope(urisInScope);
|
|
||||||
}
|
|
||||||
|
|
||||||
conf.addField( new FieldVTwo().
|
|
||||||
setName("telephoneNumber")
|
|
||||||
.setRangeDatatypeUri( XSD.xstring.toString() ).
|
|
||||||
setValidators( list("nonempty") ));
|
|
||||||
|
|
||||||
conf.addValidator(new AntiXssValidation());
|
|
||||||
|
|
||||||
prepare(vreq, conf);
|
|
||||||
return conf;
|
|
||||||
}
|
|
||||||
|
|
||||||
/* N3 assertions */
|
|
||||||
|
|
||||||
final static String n3ForNewPhone =
|
|
||||||
"?person <http://purl.obolibrary.org/obo/ARG_2000028> ?individualVcard . \n" +
|
|
||||||
"?individualVcard a <http://www.w3.org/2006/vcard/ns#Individual> . \n" +
|
|
||||||
"?individualVcard <http://purl.obolibrary.org/obo/ARG_2000029> ?person . \n" +
|
|
||||||
"?individualVcard <http://www.w3.org/2006/vcard/ns#hasTelephone> ?phone . \n" +
|
|
||||||
"?phone a <http://www.w3.org/2006/vcard/ns#Telephone> . " ;
|
|
||||||
|
|
||||||
final static String telephoneNumberAssertion =
|
|
||||||
"?phone <http://www.w3.org/2006/vcard/ns#telephone> ?telephoneNumber .";
|
|
||||||
|
|
||||||
/* Queries for editing an existing entry */
|
|
||||||
|
|
||||||
final static String individualVcardQuery =
|
|
||||||
"SELECT ?existingIndividualVcard WHERE { \n" +
|
|
||||||
"?person <http://purl.obolibrary.org/obo/ARG_2000028> ?existingIndividualVcard . \n" +
|
|
||||||
"}";
|
|
||||||
|
|
||||||
final static String telephoneNumberQuery =
|
|
||||||
"SELECT ?existingTelephoneNumber WHERE {\n"+
|
|
||||||
"?phone <http://www.w3.org/2006/vcard/ns#telephone> ?existingTelephoneNumber . }";
|
|
||||||
|
|
||||||
private String getPhoneUri(VitroRequest vreq) {
|
|
||||||
String phoneUri = vreq.getParameter("phoneUri");
|
|
||||||
|
|
||||||
return phoneUri;
|
|
||||||
}
|
|
||||||
}
|
|
Loading…
Add table
Reference in a new issue