[VIVO-1528] Select an editor for input fields based on annotation (#76)
* provide WYSIWYG editor for range XMLLiteral only * Update defaultDataPropertyForm.ftl * add annotation based selection of the desired editor for editing values of datatype properties in the frontend * create new annotation vitro:editing to allow configuration of desired editor for editing of related dataproperties Resolves: https://jira.duraspace.org/browse/VIVO-1528
This commit is contained in:
parent
734b9ccf68
commit
129e1219a8
6 changed files with 31 additions and 20 deletions
|
@ -22,6 +22,8 @@ public class DataProperty extends Property implements Comparable<DataProperty>,
|
|||
private String domainClassURI = null;
|
||||
private String rangeDatatypeURI = null;
|
||||
|
||||
private String editing = null;
|
||||
|
||||
private boolean functional = false;
|
||||
|
||||
private String example = null;
|
||||
|
@ -89,6 +91,14 @@ public class DataProperty extends Property implements Comparable<DataProperty>,
|
|||
public void setRangeDatatypeURI(String rangeDatatypeURI) {
|
||||
this.rangeDatatypeURI = rangeDatatypeURI;
|
||||
}
|
||||
|
||||
public void setEditing(String editing) {
|
||||
this.editing = editing;
|
||||
}
|
||||
|
||||
public String getEditing() {
|
||||
return this.editing;
|
||||
}
|
||||
|
||||
public boolean getFunctional() {
|
||||
return this.functional;
|
||||
|
|
|
@ -46,6 +46,7 @@ public class VitroVocabulary {
|
|||
|
||||
public static final String DESCRIPTION_ANNOT = vitroURI + "descriptionAnnot";
|
||||
public static final String PUBLIC_DESCRIPTION_ANNOT = vitroURI + "publicDescriptionAnnot";
|
||||
public static final String EDITING = vitroURI + "editing";
|
||||
public static final String SHORTDEF = "http://purl.obolibrary.org/obo/IAO_0000115";
|
||||
public static final String EXAMPLE_ANNOT = "http://purl.obolibrary.org/obo/IAO_0000112";
|
||||
|
||||
|
|
|
@ -197,6 +197,7 @@ public class DataPropertyDaoJena extends PropertyDaoJena implements
|
|||
dp.setExample(getPropertyStringValue(op,EXAMPLE_ANNOT));
|
||||
dp.setDescription(getPropertyStringValue(op,DESCRIPTION_ANNOT));
|
||||
dp.setPublicDescription(getPropertyStringValue(op,PUBLIC_DESCRIPTION_ANNOT));
|
||||
dp.setEditing(getPropertyStringValue(op,EDITING));
|
||||
dp.setDisplayTier((getWebappDaoFactory()).getJenaBaseDao().getPropertyNonNegativeIntValue(op, DISPLAY_RANK_ANNOT));
|
||||
dp.setDisplayLimit((getWebappDaoFactory()).getJenaBaseDao().getPropertyNonNegativeIntValue(op, DISPLAY_LIMIT));
|
||||
|
||||
|
|
|
@ -51,6 +51,8 @@ public class JenaBaseDaoCon {
|
|||
protected AnnotationProperty DESCRIPTION_ANNOT = _constModel.createAnnotationProperty(VitroVocabulary.DESCRIPTION_ANNOT);
|
||||
protected AnnotationProperty PUBLIC_DESCRIPTION_ANNOT = _constModel.createAnnotationProperty(VitroVocabulary.PUBLIC_DESCRIPTION_ANNOT);
|
||||
protected AnnotationProperty SHORTDEF = _constModel.createAnnotationProperty(VitroVocabulary.SHORTDEF);
|
||||
|
||||
protected AnnotationProperty EDITING = _constModel.createAnnotationProperty(VitroVocabulary.EDITING);
|
||||
|
||||
protected DatatypeProperty MONIKER = _constModel.createDatatypeProperty(VitroVocabulary.MONIKER);
|
||||
protected OntClass CLASSGROUP = _constModel.createClass(VitroVocabulary.CLASSGROUP);
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue