corrected validators and error messaging

This commit is contained in:
tworrall 2011-11-17 22:40:35 +00:00
parent 3465cf2393
commit f218cc8d24
2 changed files with 9 additions and 9 deletions

View file

@ -31,10 +31,10 @@
Please enter a First Name for this person. Please enter a First Name for this person.
<#elseif errorFieldName == "lastName"> <#elseif errorFieldName == "lastName">
Please enter a Last Name for this person. Please enter a Last Name for this person.
<#elseif errorFieldName == "lastName"> <#elseif errorFieldName == "label">
${submissionErrors[errorFieldName]} Please enter a value in the name field.
</#if> </#if>
<br />${errorFieldName} <br />
</#list> </#list>
</p> </p>
</section> </section>

View file

@ -109,15 +109,15 @@ public class PersonHasPositionHistoryGenerator extends VivoBaseGenerator impleme
conf.addField( new FieldVTwo(). conf.addField( new FieldVTwo().
setName("positionTitle") setName("positionTitle")
.setRangeDatatypeUri( XSD.xstring.toString() ) .setRangeDatatypeUri( XSD.xstring.toString() ).
// .setValidators("[nonempty]") setValidators( list("nonempty") )
); );
conf.addField( new FieldVTwo(). conf.addField( new FieldVTwo().
setName("positionType"). setName("positionType").
setOptionsType(FieldVTwo.OptionsType.CHILD_VCLASSES_WITH_PARENT). setOptionsType(FieldVTwo.OptionsType.CHILD_VCLASSES_WITH_PARENT).
setObjectClassUri(positionClass) setObjectClassUri(positionClass).
//setValidators( ["nonempty"]) setValidators( list("nonempty") )
); );
conf.addField( new FieldVTwo(). conf.addField( new FieldVTwo().
@ -128,8 +128,8 @@ public class PersonHasPositionHistoryGenerator extends VivoBaseGenerator impleme
conf.addField( new FieldVTwo(). conf.addField( new FieldVTwo().
setName("orgLabel"). setName("orgLabel").
setRangeDatatypeUri(XSD.xstring.toString()) setRangeDatatypeUri(XSD.xstring.toString() ).
// .setValidators("[nonempty]") setValidators( list("nonempty") )
); );
conf.addField( new FieldVTwo(). conf.addField( new FieldVTwo().