Changing id fullViewOnly to class, since we may need more than one per form

This commit is contained in:
rjy7 2010-07-14 17:42:01 +00:00
parent 71eb6f9223
commit 3c76cdcc93
10 changed files with 13 additions and 23 deletions

View file

@ -1,12 +1,10 @@
<%-- $This file is distributed under the terms of the license in /doc/license.txt$ --%>
<%-- sparqlForAcFilter must be all one line for JavaScript. --%>
<jsp:include page="addRoleToPersonTwoStage.jsp">
<jsp:param name="sparqlForAcFilter" value="PREFIX core: <http://vivoweb.org/ontology/core#> SELECT ?pubUri WHERE {<${subjectUri}> core:authorInAuthorship ?authorshipUri .?authorshipUri core:linkedInformationResource ?pubUri .}" />
<jsp:param name="roleActivityTypeLabel" value="clinical activity" />
<jsp:param name="roleType" value="http://vivoweb.org/ontology/core#ClinicalRole" />
<jsp:param name="roleActivityType_optionsType" value="LITERALS" />
<jsp:param name="roleActivityType_objectClassUri" value="" />
<jsp:param name="roleActivityType_literalOptions" value='["http://vivoweb.org/ontology/core#Project", "Project" ], [ "http://vivoweb.org/ontology/core#Service","Service"] ' />
<jsp:param name="roleActivityType_literalOptions" value='["", "Select one" ], ["http://vivoweb.org/ontology/core#Project", "Project" ], [ "http://vivoweb.org/ontology/core#Service","Service"] ' />
</jsp:include>

View file

@ -205,7 +205,7 @@ if ( ((String)request.getAttribute("predicateUri")).endsWith("hasPrincipalInvest
<%-- Must be all one line for JavaScript. --%>
<c:set var="sparqlForAcFilter">
PREFIX core: <${vivoCore}> SELECT ?grantUri WHERE {<${subjectUri}> core:hasPrincipalInvestigatorRole ?grantRole .?grantRole core:relatedRole ?grantUri .}
PREFIX core: <${vivoCore}> SELECT ?grantUri WHERE {<${subjectUri}> core:hasPrincipalInvestigatorRole ?grantRole . ?grantRole core:roleIn ?grantUri .}
</c:set>
<script type="text/javascript">

View file

@ -1,12 +1,10 @@
<%-- $This file is distributed under the terms of the license in /doc/license.txt$ --%>
<%-- sparqlForAcFilter must be all one line for JavaScript. --%>
<jsp:include page="addRoleToPersonTwoStage.jsp">
<jsp:param name="sparqlForAcFilter" value="PREFIX core: <http://vivoweb.org/ontology/core#> SELECT ?pubUri WHERE {<${subjectUri}> core:authorInAuthorship ?authorshipUri .?authorshipUri core:linkedInformationResource ?pubUri .}" />
<jsp:param name="roleActivityTypeLabel" value="membership" />
<jsp:param name="roleType" value="http://vivoweb.org/ontology/core#MemberRole" />
<jsp:param name="roleActivityType_optionsType" value="CHILD_VCLASSES" />
<jsp:param name="roleActivityType_objectClassUri" value="http://xmlns.com/foaf/0.1/Organization" />
<jsp:param name="roleActivityType_literalOptions" value="" />
<jsp:param name="roleActivityType_literalOptions" value="[ 'Select one' ]" />
</jsp:include>

View file

@ -1,13 +1,11 @@
<%-- $This file is distributed under the terms of the license in /doc/license.txt$ --%>
<%-- sparqlForAcFilter must be all one line for JavaScript. --%>
<jsp:include page="addRoleToPersonTwoStage.jsp">
<jsp:param name="sparqlForAcFilter" value="PREFIX core: &lt;http://vivoweb.org/ontology/core#&gt; SELECT ?pubUri WHERE {&lt;${subjectUri}&gt; core:authorInAuthorship ?authorshipUri .?authorshipUri core:linkedInformationResource ?pubUri .}" />
<jsp:param name="roleActivityTypeLabel" value="presentation" />
<jsp:param name="roleType" value="http://vivoweb.org/ontology/core#PresenterRole" />
<jsp:param name="roleActivityType_optionsType" value="LITERALS" />
<jsp:param name="roleActivityType_objectClassUri" value="" />
<jsp:param name="roleActivityType_literalOptions" value='["http://vivoweb.org/ontology/core#Presentation", "Presentation" ], [ "http://vivoweb.org/ontology/core#InvitedTalk","Invited Talk"] ' />
<jsp:param name="roleActivityType_literalOptions" value='["", "Select one" ], ["http://vivoweb.org/ontology/core#Presentation", "Presentation" ], [ "http://vivoweb.org/ontology/core#InvitedTalk","Invited Talk"] ' />
</jsp:include>

View file

@ -210,7 +210,7 @@ SPARQL queries for existing values. --%>
<p class="inline"><v:input type="select" label="Publication Type ${requiredHint}" name="pubType" id="typeSelector" /></p>
<div id="fullViewOnly">
<div class="fullViewOnly">
<p><v:input type="text" id="label" name="title" label="Title" cssClass="acSelector" size="50" /></p>

View file

@ -1,12 +1,10 @@
<%-- $This file is distributed under the terms of the license in /doc/license.txt$ --%>
<%-- sparqlForAcFilter must be all one line for JavaScript. --%>
<jsp:include page="addRoleToPersonTwoStage.jsp">
<jsp:param name="sparqlForAcFilter" value="PREFIX core: <http://vivoweb.org/ontology/core#> SELECT ?pubUri WHERE {<${subjectUri}> core:authorInAuthorship ?authorshipUri .?authorshipUri core:linkedInformationResource ?pubUri .}" />
<jsp:param name="roleActivityTypeLabel" value="research activity" />
<jsp:param name="roleType" value="http://vivoweb.org/ontology/core#ResearcherRole" />
<jsp:param name="roleActivityType_optionsType" value="LITERALS" />
<jsp:param name="roleActivityType_objectClassUri" value="" />
<jsp:param name="roleActivityType_literalOptions" value='["http://vivoweb.org/ontology/core#Grant", "Grant" ], [ "http://vivoweb.org/ontology/core#Project","Project"] ' />
<jsp:param name="roleActivityType_literalOptions" value='["", "Select one" ], ["http://vivoweb.org/ontology/core#Grant", "Grant" ], [ "http://vivoweb.org/ontology/core#Project","Project"] ' />
</jsp:include>

View file

@ -218,7 +218,7 @@
<p class="inline"><v:input type="select" label="${roleActivityTypeLabel} Type ${requiredHint}" name="roleActivityType" id="typeSelector" /></p>
<div id="fullViewOnly">
<div class="fullViewOnly">
<p><v:input type="text" id="label" name="title" label="Title" cssClass="acSelector" size="50" /></p>
@ -239,7 +239,7 @@
<%-- Must be all one line for JavaScript. --%>
<c:set var="sparqlForAcFilter">
SELECT ?indUri WHERE {<${subjectUri}> <${predicateUri}> ?role .?role <...> ?indUri .}
SELECT ?indUri WHERE {<${subjectUri}> <${predicateUri}> ?role . ?role <${vivoCore}relatedRole> ?indUri .}
</c:set>
<script type="text/javascript">

View file

@ -1,12 +1,10 @@
<%-- $This file is distributed under the terms of the license in /doc/license.txt$ --%>
<%-- sparqlForAcFilter must be all one line for JavaScript. --%>
<jsp:include page="addRoleToPersonTwoStage.jsp">
<jsp:param name="sparqlForAcFilter" value="PREFIX core: &lt;http://vivoweb.org/ontology/core#&gt; SELECT ?pubUri WHERE {&lt;${subjectUri}&gt; core:authorInAuthorship ?authorshipUri .?authorshipUri core:linkedInformationResource ?pubUri .}" />
<jsp:param name="roleActivityTypeLabel" value="teaching activity" />
<jsp:param name="roleType" value="http://vivoweb.org/ontology/core#TeacherRole" />
<jsp:param name="roleActivityType_optionsType" value="LITERALS" />
<jsp:param name="roleActivityType_objectClassUri" value="" />
<jsp:param name="roleActivityType_literalOptions" value='["http://purl.org/ontology/bibo/Conference", "Conference" ], [ "http://vivoweb.org/ontology/core#Course","Course"], [ "http://purl.org/ontology/bibo/Workshop","Workshop"] ' />
<jsp:param name="roleActivityType_literalOptions" value='["", "Select one" ], ["http://purl.org/ontology/bibo/Conference", "Conference" ], [ "http://vivoweb.org/ontology/core#Course","Course"], [ "http://purl.org/ontology/bibo/Workshop","Workshop"] ' />
</jsp:include>

View file

@ -2,7 +2,7 @@
/* Although Javascript hides these on page load, hide here as well to avoid the flash on page load.
This needs to be removed to support a non-JS version of the form. */
#fullViewOnly,
.fullViewOnly,
#submit,
.or,
#requiredLegend {

View file

@ -23,7 +23,7 @@ var customForm = {
initObjects: function(){
this.form = $('#content form');
this.fullViewOnly = $('#fullViewOnly');
this.fullViewOnly = $('.fullViewOnly');
this.button = $('#submit');
this.baseButtonText = this.button.val();
this.requiredLegend = $('#requiredLegend');
@ -223,11 +223,11 @@ var customForm = {
filteredResults = [];
$.each(results, function() {
if ($.inArray(this.uri, customForm.acFilter) == -1) {
// console.log("adding " + this.label + " to filtered results");
console.log("adding " + this.label + " to filtered results");
filteredResults.push(this);
}
else {
// console.log("filtering out " + this.label);
console.log("filtering out " + this.label);
}
});
return filteredResults;