Working on refactoring select option generation NIHVIVO-3657
This commit is contained in:
parent
41171a48f4
commit
f2707b0bb1
37 changed files with 1542 additions and 1042 deletions
|
@ -3,94 +3,15 @@
|
|||
@prefix owl: <http://www.w3.org/2002/07/owl#> .
|
||||
@prefix rdf: <http://www.w3.org/1999/02/22-rdf-syntax-ns#> .
|
||||
|
||||
<http://vitro.mannlib.cornell.edu/ontologies/display/1.1#MenuText>
|
||||
<http://vitro.mannlib.cornell.edu/ontologies/display/1.1#hasMenuText>
|
||||
"""# $This file is distributed under the terms of the license in /doc/license.txt$
|
||||
|
||||
@prefix owl: <http://www.w3.org/2002/07/owl#> .
|
||||
@prefix display: <http://vitro.mannlib.cornell.edu/ontologies/display/1.1#> .
|
||||
@prefix rdf: <http://www.w3.org/1999/02/22-rdf-syntax-ns#> .
|
||||
@prefix core: <http://vivoweb.org/ontology/core#> .
|
||||
@prefix vivoweb: <http://vivoweb.org/ontology#> .
|
||||
|
||||
### This file defines the default menu for vivo. ###
|
||||
|
||||
#### Default Menu ####
|
||||
|
||||
display:DefaultMenu
|
||||
a display:MainMenu ;
|
||||
display:hasElement display:EventsMenuItem ;
|
||||
display:hasElement display:HomeMenuItem ;
|
||||
display:hasElement display:OrganizationsMenuItem ;
|
||||
display:hasElement display:PeopleMenuItem ;
|
||||
display:hasElement display:ResearchMenuItem .
|
||||
|
||||
#### Menu Items for Default Menu ####
|
||||
|
||||
display:HomeMenuItem
|
||||
a display:NavigationElement ;
|
||||
display:menuPosition 1;
|
||||
display:linkText \"Home\";
|
||||
display:toPage display:Home .
|
||||
|
||||
display:PeopleMenuItem
|
||||
a display:NavigationElement ;
|
||||
display:menuPosition 2;
|
||||
display:linkText \"People\";
|
||||
display:toPage display:People .
|
||||
|
||||
display:OrganizationsMenuItem
|
||||
a display:NavigationElement ;
|
||||
display:menuPosition 3;
|
||||
display:linkText \"Organizations\";
|
||||
display:toPage display:Organizations .
|
||||
|
||||
display:ResearchMenuItem
|
||||
a display:NavigationElement ;
|
||||
display:menuPosition 4;
|
||||
display:linkText \"Research\";
|
||||
display:toPage display:Research .
|
||||
|
||||
display:EventsMenuItem
|
||||
a display:NavigationElement ;
|
||||
display:menuPosition 5;
|
||||
display:linkText \"Events\";
|
||||
display:toPage display:Events .
|
||||
|
||||
########## Pages ############
|
||||
|
||||
display:Home
|
||||
a display:HomePage ;
|
||||
a display:Page ;
|
||||
display:title \"Home\" ;
|
||||
display:urlMapping \"/\" .
|
||||
|
||||
display:Events
|
||||
a display:Page ;
|
||||
a display:ClassGroupPage;
|
||||
display:forClassGroup vivoweb:vitroClassGroupevents ;
|
||||
display:title \"Events\" ;
|
||||
display:urlMapping \"/events\" .
|
||||
|
||||
display:Organizations
|
||||
a display:Page ;
|
||||
a display:ClassGroupPage;
|
||||
display:forClassGroup vivoweb:vitroClassGrouporganizations ;
|
||||
display:title \"Organizations\" ;
|
||||
display:urlMapping \"/organizations\" .
|
||||
|
||||
display:People
|
||||
a display:Page ;
|
||||
a display:ClassGroupPage;
|
||||
display:forClassGroup vivoweb:vitroClassGrouppeople ;
|
||||
display:requiresBodyTemplate \"menupage--classgroup-people.ftl\" ;
|
||||
display:title \"People\" ;
|
||||
display:urlMapping \"/people\" .
|
||||
|
||||
display:Research
|
||||
a display:Page ;
|
||||
a display:ClassGroupPage;
|
||||
display:forClassGroup vivoweb:vitroClassGrouppublications ;
|
||||
display:title \"Research\" ;
|
||||
display:urlMapping \"/research\" .
|
||||
""" .
|
||||
rdf:type
|
||||
a owl:ObjectProperty ;
|
||||
rdfs:label "RDF Type"@en-US ;
|
||||
rdfs:range owl:Class;
|
||||
<http://vitro.mannlib.cornell.edu/ns/vitro/0.7#customEntryFormAnnot>
|
||||
"edu.cornell.mannlib.vitro.webapp.edit.n3editing.configuration.generators.RdfTypeGenerator"^^xsd:string ;
|
||||
<http://vitro.mannlib.cornell.edu/ns/vitro/0.7#offerCreateNewOptionAnnot>
|
||||
"true"^^xsd:boolean ;
|
||||
<http://vitro.mannlib.cornell.edu/ns/vitro/0.7#selectFromExistingAnnot>
|
||||
"true"^^xsd:boolean ;
|
||||
|
||||
|
|
@ -64,6 +64,7 @@ rdfs:comment
|
|||
rdfs:label
|
||||
a owl:DatatypeProperty .
|
||||
|
||||
|
||||
owl:versionInfo
|
||||
a owl:DatatypeProperty .
|
||||
|
||||
|
@ -145,6 +146,18 @@ owl:topObjectProperty
|
|||
<http://vitro.mannlib.cornell.edu/ns/vitro/0.7#stubObjectPropertyAnnot>
|
||||
"true"^^xsd:boolean .
|
||||
|
||||
rdf:type
|
||||
a owl:ObjectProperty ;
|
||||
rdfs:label "RDF Type"@en-US ;
|
||||
rdfs:range owl:Class ;
|
||||
<http://vitro.mannlib.cornell.edu/ns/vitro/0.7#customEntryFormAnnot>
|
||||
"edu.cornell.mannlib.vitro.webapp.edit.n3editing.configuration.generators.RdfTypeGenerator"^^xsd:string ;
|
||||
<http://vitro.mannlib.cornell.edu/ns/vitro/0.7#offerCreateNewOptionAnnot>
|
||||
"true"^^xsd:boolean ;
|
||||
<http://vitro.mannlib.cornell.edu/ns/vitro/0.7#selectFromExistingAnnot>
|
||||
"true"^^xsd:boolean .
|
||||
|
||||
|
||||
<http://vitro.mannlib.cornell.edu/ns/vitro/0.7#additionalLink>
|
||||
a owl:ObjectProperty ;
|
||||
rdfs:label "Additional Link"@en-US ;
|
||||
|
|
45
webapp/web/templates/freemarker/edit/forms/rdfTypeForm.ftl
Normal file
45
webapp/web/templates/freemarker/edit/forms/rdfTypeForm.ftl
Normal file
|
@ -0,0 +1,45 @@
|
|||
<#-- $This file is distributed under the terms of the license in /doc/license.txt$ -->
|
||||
|
||||
<#--Assign variables from editConfig-->
|
||||
<#assign rangeOptions = editConfiguration.pageData.object />
|
||||
<#assign rangeOptionsExist = false />
|
||||
<#if (rangeOptions?keys?size > 0)>
|
||||
<#assign rangeOptionsExist = true/>
|
||||
</#if>
|
||||
|
||||
<h2>${editConfiguration.formTitle}</h2>
|
||||
|
||||
|
||||
<#if rangeOptionsExist = true >
|
||||
<#assign rangeOptionKeys = rangeOptions?keys />
|
||||
<form class="editForm" action = "${submitUrl}">
|
||||
<input type="hidden" name="editKey" id="editKey" value="${editKey}" role="input" />
|
||||
<select id="object" name="object" role="select">
|
||||
<#list rangeOptionKeys as key>
|
||||
<option value="${key}" <#if editConfiguration.objectUri?has_content && editConfiguration.objectUri = key>selected</#if> role="option">${rangeOptions[key]}</option>
|
||||
</#list>
|
||||
</select>
|
||||
|
||||
<p>
|
||||
<input type="submit" id="submit" value="${editConfiguration.submitLabel}" role="button "/>
|
||||
<span class="or"> or </span>
|
||||
<a title="Cancel" class="cancel" href="${cancelUrl}">Cancel</a>
|
||||
</p>
|
||||
</form>
|
||||
<#else>
|
||||
<p> There are no Classes in the system from which to select. </p>
|
||||
</#if>
|
||||
|
||||
<#if editConfiguration.propertyOfferCreateNewOption = true>
|
||||
<#include "defaultOfferCreateNewOptionForm.ftl">
|
||||
|
||||
</#if>
|
||||
|
||||
<#if editConfiguration.propertySelectFromExisting = false && editConfiguration.propertyOfferCreateNewOption = false>
|
||||
<p>This property is currently configured to prohibit editing. </p>
|
||||
</#if>
|
||||
|
||||
<#if editConfiguration.includeDeletionForm = true>
|
||||
<#include "defaultDeletePropertyForm.ftl">
|
||||
</#if>
|
||||
|
Loading…
Add table
Add a link
Reference in a new issue