. castable as xs:date
自从我们从 ORBEON 3.9 更新到 ORBEON 4.1 后不起作用。在xforms:output
标签中(在 ref 和 value 属性中)。
关联字段使用 xsd 文件定义为 xs:date,字段本身具有值 ''(空字符串)。
例外是:
org.orbeon.oxf.common.ValidationException: line 1136 of file:///D:/oracle/wls10.3.3/domains/gacr/ (evaluating XPath expression: expression='datumUkonceni castable as xs:date'): null file:///D:/oracle/wls10.3.3/domains/gacr/, line 1136, column -1: null
at org.orbeon.oxf.common.ValidationException.wrapException(ValidationException.java:126)
at org.orbeon.oxf.util.XPath$.handleXPathException(XPath.scala:170)
at org.orbeon.oxf.util.XPathCache$.withEvaluation(XPathCache.scala:516)
at org.orbeon.oxf.util.XPathCache$.evaluateAsString(XPathCache.scala:312)
at org.orbeon.oxf.xforms.control.ControlXPathSupport$class.evaluateAsString(ControlXPathSupport.scala:86)
at org.orbeon.oxf.xforms.control.XFormsControl.evaluateAsString(XFormsControl.scala:47)
at org.orbeon.oxf.xforms.control.controls.XFormsOutputControl.evaluateValue(XFormsOutputControl.scala:75)
at org.orbeon.oxf.xforms.control.XFormsValueControl$class.evaluateImpl(XFormsValueControl.scala:80)
at org.orbeon.oxf.xforms.control.controls.XFormsOutputControl.evaluateImpl(XFormsOutputControl.scala:58)
at org.orbeon.oxf.xforms.control.XFormsControl.evaluate(XFormsControl.scala:204)
at org.orbeon.oxf.xforms.control.ControlBindingSupport$class.setBindingContext(ControlBindingSupport.scala:102)
at org.orbeon.oxf.xforms.control.XFormsControl.setBindingContext(XFormsControl.scala:47)
at org.orbeon.oxf.xforms.control.ControlBindingSupport$class.evaluateBindingAndValues(ControlBindingSupport.scala:59)
at org.orbeon.oxf.xforms.control.XFormsControl.evaluateBindingAndValues(XFormsControl.scala:47)
.... stack continued
当我在 properties-local.xml 中使用此构造时<property as="xs:string" name="oxf.xforms.format.output.date" value="if (. castable as xs:date)
then format-date(xs:date(.), '[D01].[M01].[Y0001]', xxforms:lang(), (), ()) else ."/>
,会按预期处理 castable ...