-
Bug
-
Resolution: Fixed
-
Later
-
7.0.7, 8.0.1.1
-
None
-
Security Level: Jimmy
-
None
-
ZK 8.0.2 S2
-
None
Steps to reproduce
- run the attached code with zk-label.properties
actual result
2016-04-13 12:19:19 ERROR UiEngineImpl:1468 -
org.zkoss.zel.PropertyNotFoundException: Property 'fieldname' not found on type support.issue.T3119VM$Person_$$_jvst91c_0
at org.zkoss.zel.BeanELResolver$BeanProperties.get(BeanELResolver.java:442)
at org.zkoss.zel.BeanELResolver$BeanProperties.access$300(BeanELResolver.java:392)
at org.zkoss.zel.BeanELResolver.property(BeanELResolver.java:565)
at org.zkoss.zel.BeanELResolver.getValue(BeanELResolver.java:100)
at org.zkoss.zel.CompositeELResolver.getValue(CompositeELResolver.java:66)
at org.zkoss.xel.zel.XelELResolver.getValue(XelELResolver.java:99)
at org.zkoss.zel.CompositeELResolver.getValue(CompositeELResolver.java:66)
at org.zkoss.zel.impl.parser.AstValue.getValue(AstValue.java:188)
at org.zkoss.zel.impl.ValueExpressionImpl.getValue(ValueExpressionImpl.java:184)
at org.zkoss.xel.zel.ELXelExpression.evaluate(ELXelExpression.java:41)
at org.zkoss.util.resource.impl.LabelLoaderImpl$ExValue.getValue(LabelLoaderImpl.java:413)
at org.zkoss.util.resource.impl.LabelLoaderImpl$1.filter(LabelLoaderImpl.java:91)
at org.zkoss.util.FilterMap.get(FilterMap.java:62)
at org.zkoss.zel.MapELResolver.getValue(MapELResolver.java:66)
at org.zkoss.zel.CompositeELResolver.getValue(CompositeELResolver.java:66)
at org.zkoss.xel.zel.XelELResolver.getValue(XelELResolver.java:99)
at org.zkoss.zel.CompositeELResolver.getValue(CompositeELResolver.java:66)
at org.zkoss.zel.impl.parser.AstValue.getValue(AstValue.java:188)
at org.zkoss.zel.impl.ValueExpressionImpl.getValue(ValueExpressionImpl.java:184)
at org.zkoss.xel.zel.ELXelExpression.evaluate(ELXelExpression.java:41)
at org.zkoss.zk.xel.impl.SimpleEvaluator.evaluate(SimpleEvaluator.java:72)
at org.zkoss.zk.ui.metainfo.AbstractEvalRef.evaluate(AbstractEvalRef.java:48)
at org.zkoss.zk.xel.ExValue.getValue(ExValue.java:109)
at org.zkoss.zk.ui.metainfo.Property.getValue(Property.java:136)
at org.zkoss.zk.ui.metainfo.Property.assign0(Property.java:203)
at org.zkoss.zk.ui.metainfo.Property.assign(Property.java:171)
at org.zkoss.zk.ui.metainfo.ComponentInfo.applyProperties(ComponentInfo.java:732)
at org.zkoss.zk.ui.impl.AbstractUiFactory.newComponent(AbstractUiFactory.java:136)
at org.zkoss.zk.ui.impl.UiEngineImpl.execCreateChild0(UiEngineImpl.java:908)
at org.zkoss.zk.ui.impl.UiEngineImpl.execCreateChild(UiEngineImpl.java:877)
at org.zkoss.zk.ui.impl.UiEngineImpl.execCreate0(UiEngineImpl.java:748)
at org.zkoss.zk.ui.impl.UiEngineImpl.execCreate(UiEngineImpl.java:709)
at org.zkoss.zk.ui.impl.UiEngineImpl.execCreateChild0(UiEngineImpl.java:923)
at org.zkoss.zk.ui.impl.UiEngineImpl.execCreateChild(UiEngineImpl.java:877)
at org.zkoss.zk.ui.impl.UiEngineImpl.execCreate0(UiEngineImpl.java:748)
at org.zkoss.zk.ui.impl.UiEngineImpl.access$800(UiEngineImpl.java:128)
at org.zkoss.zk.ui.impl.UiEngineImpl$TemplateImpl.create(UiEngineImpl.java:2292)
at org.zkoss.bind.impl.BindRowRenderer.render(BindRowRenderer.java:81)
at org.zkoss.zul.Grid$Renderer.render(Grid.java:1095)
at org.zkoss.zul.Grid.doInitRenderer(Grid.java:980)
at org.zkoss.zul.Grid.onInitRender(Grid.java:938)
at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
at sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:57)
at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:43)
at java.lang.reflect.Method.invoke(Method.java:606)
at org.zkoss.zk.ui.AbstractComponent.service(AbstractComponent.java:3012)
at org.zkoss.zk.ui.AbstractComponent.service(AbstractComponent.java:2942)
at org.zkoss.zk.ui.impl.EventProcessor.process(EventProcessor.java:136)
at org.zkoss.zk.ui.impl.UiEngineImpl.processEvent(UiEngineImpl.java:1826)
at org.zkoss.zk.ui.impl.UiEngineImpl.process(UiEngineImpl.java:1611)
at org.zkoss.zk.ui.impl.UiEngineImpl.execNewPage0(UiEngineImpl.java:522)
at org.zkoss.zk.ui.impl.UiEngineImpl.execNewPage(UiEngineImpl.java:358)
at org.zkoss.zk.ui.http.DHtmlLayoutServlet.process(DHtmlLayoutServlet.java:217)
at org.zkoss.zk.ui.http.DHtmlLayoutServlet.doGet(DHtmlLayoutServlet.java:136)
expected result
the label inside a template is resolved as a label instead of a form object
debug info
- Please notice that the label key in a <template> outside of a Grid is resolved as a label instead of a form object. This is an inconsistent resolving from the label key in a <template> inside a Grid in the same zul.
<template name="template2"> <label value="${labels.myscreen.form.field.name }"/> </template>
- In 7.0.7, I can reproduce a similar error below:
SEVERE:
org.zkoss.zel.PropertyNotFoundException: Property 'fieldname' not found on type org.zkoss.bind.SimpleForm - EL expression is allowed in a zk-label.properties: http://books.zkoss.org/wiki/ZK_Developer%27s_Reference/Internationalization/Labels/The_Format_of_Properties_Files