enable check for creating new individual to get faux property information correctly
This commit is contained in:
parent
d3f6af6981
commit
35251e89f4
2 changed files with 6 additions and 1 deletions
|
@ -56,7 +56,10 @@ public class DefaultAddMissingIndividualFormGenerator implements EditConfigurati
|
|||
public static boolean isCreateNewIndividual(VitroRequest vreq, HttpSession session) {
|
||||
String command = vreq.getParameter("cmd");
|
||||
String predicateUri = EditConfigurationUtils.getPredicateUri(vreq);
|
||||
ObjectProperty objProp = vreq.getWebappDaoFactory().getObjectPropertyDao().getObjectPropertyByURI(predicateUri);
|
||||
//This method also looks at domain and range uris and so is different than just getting the
|
||||
//object property based on predicate uri alone
|
||||
ObjectProperty objProp = EditConfigurationUtils.getObjectPropertyForPredicate(vreq,
|
||||
predicateUri);
|
||||
if(objProp != null) {
|
||||
return(objProp.getOfferCreateNewOption() &&
|
||||
(
|
||||
|
|
|
@ -17,6 +17,8 @@
|
|||
<input type="hidden" value="${editConfiguration.subjectUri}" name="subjectUri" role="input" />
|
||||
<input type="hidden" value="${editConfiguration.predicateUri}" name="predicateUri" role="input" />
|
||||
<input type="hidden" value="${objectUri}" name="objectUri" role="input" />
|
||||
<input type="hidden" name="domainUri" value="${editConfiguration.domainUri!}"/>
|
||||
<input type="hidden" name="rangeUri" value="${editConfiguration.rangeUri!}"/>
|
||||
<input type="hidden" value="create" name="cmd" role="input" />
|
||||
|
||||
<select id="typeOfNew" name="typeOfNew" role="selection">
|
||||
|
|
Loading…
Add table
Reference in a new issue