Uploaded image for project: 'ZK'
  1. ZK
  2. ZK-1361

checkbox in grid template causes ZUL binding error

XMLWordPrintable

    • Icon: Bug Bug
    • Resolution: Invalid
    • Icon: Major Major
    • None
    • 6.0.2
    • None

      Having recently upgraded a project from ZK R6 to R6.02 I've detected a bug with having a checkbox element in a grid template.

      <grid id="scenarios"
      model="@load(vm.scenarioModel)
      @save(vm.scenarioModel,before='compareScenarios')">
      <auxhead>
      <auxheader colspan="4">
      <button label="Compare scenarios" disabled="@load(vm.cannotCompare)" onClick="@command('compareScenarios')"/>
      <space />
      <button label="Change existing scenarios" />
      <space />
      <button label="Add new scenario" onClick="@command('addScenario')"/>
      </auxheader>
      </auxhead>
      <columns>
      <column label="Compare" width="90px" align="center"/>
      <column label="Scenario name" />
      <column label="Links" />
      <column label="Evaluation state" />
      </columns>
      <template name="model" var="item">
      <row>
      <checkbox check="@bind(item.selected)" onCheck="@command('selectionChange',state=self.checked, scenarioID=item.ID)"/>
      <a label="@load(item.title)" />
      <a label="@load(item.links)" />
      <a label="@load(item.evaluationState)" />
      </row>
      </template>
      </grid>

      Take out the check="@bind(item.selected)" attribute setting and it works fine in R6.0.2. This code worked fine in R6.

      The following error is reported:
      19-Sep-2012 06:02:33 org.zkoss.zk.ui.impl.UiEngineImpl handleError:1351
      SEVERE: >>org.zkoss.zel.PropertyNotFoundException: Property 'check' not found on type org.zkoss.zul.Checkbox
      >> at org.zkoss.zel.BeanELResolver$BeanProperties.get(BeanELResolver.java:304)
      >> at org.zkoss.zel.BeanELResolver$BeanProperties.access$400(BeanELResolver.java:255)
      >> at org.zkoss.zel.BeanELResolver.property(BeanELResolver.java:429)
      >> at org.zkoss.zel.BeanELResolver.getType(BeanELResolver.java:115)
      >> at org.zkoss.zel.CompositeELResolver.getType(CompositeELResolver.java:131)
      >> at org.zkoss.zel.CompositeELResolver.getType(CompositeELResolver.java:131)
      >> at org.zkoss.xel.zel.XelELResolver.getType(XelELResolver.java:95)
      >> at org.zkoss.zel.impl.parser.AstValue.setValue(AstValue.java:210)
      >> at org.zkoss.zel.impl.ValueExpressionImpl.setValue(ValueExpressionImpl.java:256)
      >> at org.zkoss.xel.zel.ELXelExpression.setValue(ELXelExpression.java:50)
      >> at org.zkoss.bind.impl.BindEvaluatorXImpl.setValue(BindEvaluatorXImpl.java:50)
      >> at org.zkoss.bind.impl.LoadPropertyBindingImpl.load(LoadPropertyBindingImpl.java:81)
      >> at org.zkoss.bind.impl.PropertyBindingHandler.doLoadBinding(PropertyBindingHandler.java:171)
      >> at org.zkoss.bind.impl.PropertyBindingHandler.doLoad(PropertyBindingHandler.java:372)
      >> at org.zkoss.bind.impl.BinderImpl.loadComponentProperties(BinderImpl.java:1800)
      >> at org.zkoss.bind.impl.BinderImpl.loadComponent(BinderImpl.java:1777)
      >> at org.zkoss.bind.impl.BinderImpl.loadComponent(BinderImpl.java:1780)
      >> at org.zkoss.bind.tracker.impl.BindUiLifeCycle$1.onEvent(BindUiLifeCycle.java:69)
      >> at org.zkoss.zk.ui.AbstractComponent.onEvent(AbstractComponent.java:2736)
      >> at org.zkoss.zk.ui.AbstractComponent.service(AbstractComponent.java:2685)
      >> at org.zkoss.zk.ui.AbstractComponent.service(AbstractComponent.java:2648)
      >> at org.zkoss.zk.ui.impl.EventProcessor.process(EventProcessor.java:136)
      >> at org.zkoss.zk.ui.impl.UiEngineImpl.processEvent(UiEngineImpl.java:1709)
      >> at org.zkoss.zk.ui.impl.UiEngineImpl.process(UiEngineImpl.java:1494)
      >> at org.zkoss.zk.ui.impl.UiEngineImpl.execNewPage0(UiEngineImpl.java:463)
      >> at org.zkoss.zk.ui.impl.UiEngineImpl.execNewPage(UiEngineImpl.java:316)
      >> at org.zkoss.zk.ui.http.DHtmlLayoutServlet.process(DHtmlLayoutServlet.java:215)
      >> at org.zkoss.zk.ui.http.DHtmlLayoutServlet.doGet(DHtmlLayoutServlet.java:135)
      >> at javax.servlet.http.HttpServlet.service(HttpServlet.java:690)
      >> at javax.servlet.http.HttpServlet.service(HttpServlet.java:803)
      >> at org.apache.catalina.core.ApplicationFilterChain.internalDoFilter(ApplicationFilterChain.java:290)
      >> at org.apache.catalina.core.ApplicationFilterChain.doFilter(ApplicationFilterChain.java:206)
      >> at org.apache.catalina.core.ApplicationDispatcher.invoke(ApplicationDispatcher.java:654)
      >> at org.apache.catalina.core.ApplicationDispatcher.processRequest(ApplicationDispatcher.java:445)
      >> at org.apache.catalina.core.ApplicationDispatcher.doForward(ApplicationDispatcher.java:379)
      >> at org.apache.catalina.core.ApplicationDispatcher.forward(ApplicationDispatcher.java:292)
      >> at org.zkoss.web.servlet.Servlets.forward(Servlets.java:837)
      >> at org.zkoss.zk.ui.http.ExecutionImpl.forward(ExecutionImpl.java:277)
      >> at org.zkoss.zk.ui.http.ExecutionImpl.forward(ExecutionImpl.java:286)
      >> at org.zkoss.zk.ui.impl.UiEngineImpl.execNewPage0(UiEngineImpl.java:392)
      >> at org.zkoss.zk.ui.impl.UiEngineImpl.execNewPage(UiEngineImpl.java:316)
      >> at org.zkoss.zk.ui.http.DHtmlLayoutServlet.process(DHtmlLayoutServlet.java:215)
      >> at org.zkoss.zk.ui.http.DHtmlLayoutServlet.doGet(DHtmlLayoutServlet.java:135)
      >> at javax.servlet.http.HttpServlet.service(HttpServlet.java:690)
      >> at javax.servlet.http.HttpServlet.service(HttpServlet.java:803)
      >> at org.apache.catalina.core.ApplicationFilterChain.internalDoFilter(ApplicationFilterChain.java:290)
      >> at org.apache.catalina.core.ApplicationFilterChain.doFilter(ApplicationFilterChain.java:206)
      >> at org.springframework.security.web.FilterChainProxy$VirtualFilterChain.doFilter(FilterChainProxy.java:368)
      >> at org.springframework.security.web.access.intercept.FilterSecurityInterceptor.invoke(FilterSecurityInterceptor.java:109)
      >> at org.springframework.security.web.access.intercept.FilterSecurityInterceptor.doFilter(FilterSecurityInterceptor.java:83)
      >> at org.springframework.security.web.FilterChainProxy$VirtualFilterChain.doFilter(FilterChainProxy.java:380)
      >> at org.springframework.security.web.access.ExceptionTranslationFilter.doFilter(ExceptionTranslationFilter.java:97)
      >> at org.springframework.security.web.FilterChainProxy$VirtualFilterChain.doFilter(FilterChainProxy.java:380)
      >> at org.springframework.security.web.session.SessionManagementFilter.doFilter(SessionManagementFilter.java:100)
      >> at org.springframework.security.web.FilterChainProxy$VirtualFilterChain.doFilter(FilterChainProxy.java:380)
      >> at org.springframework.security.web.authentication.AnonymousAuthenticationFilter.doFilter(AnonymousAuthenticationFilter.java:78)
      >> at org.springframework.security.web.FilterChainProxy$VirtualFilterChain.doFilter(FilterChainProxy.java:380)
      >> at org.springframework.security.web.authentication.rememberme.RememberMeAuthenticationFilter.doFilter(RememberMeAuthenticationFilter.java:119)
      >> at org.springframework.security.web.FilterChainProxy$VirtualFilterChain.doFilter(FilterChainProxy.java:380)
      >> at org.springframework.security.web.servletapi.SecurityContextHolderAwareRequestFilter.doFilter(SecurityContextHolderAwareRequestFilter.java:54)
      >> at org.springframework.security.web.FilterChainProxy$VirtualFilterChain.doFilter(FilterChainProxy.java:380)
      >> at org.springframework.security.web.savedrequest.RequestCacheAwareFilter.doFilter(RequestCacheAwareFilter.java:35)
      >> at org.springframework.security.web.FilterChainProxy$VirtualFilterChain.doFilter(FilterChainProxy.java:380)
      >> at org.springframework.security.web.authentication.AbstractAuthenticationProcessingFilter.doFilter(AbstractAuthenticationProcessingFilter.java:187)
      >> at org.springframework.security.web.FilterChainProxy$VirtualFilterChain.doFilter(FilterChainProxy.java:380)
      >> at org.springframework.security.web.authentication.logout.LogoutFilter.doFilter(LogoutFilter.java:105)
      >> at org.springframework.security.web.FilterChainProxy$VirtualFilterChain.doFilter(FilterChainProxy.java:380)
      >> at org.springframework.security.web.context.SecurityContextPersistenceFilter.doFilter(SecurityContextPersistenceFilter.java:79)
      >> at org.springframework.security.web.FilterChainProxy$VirtualFilterChain.doFilter(FilterChainProxy.java:380)
      >> at org.springframework.security.web.FilterChainProxy.doFilter(FilterChainProxy.java:169)
      >> at org.springframework.web.filter.DelegatingFilterProxy.invokeDelegate(DelegatingFilterProxy.java:237)
      >> at org.springframework.web.filter.DelegatingFilterProxy.doFilter(DelegatingFilterProxy.java:167)
      >> at org.apache.catalina.core.ApplicationFilterChain.internalDoFilter(ApplicationFilterChain.java:235)
      >> at org.apache.catalina.core.ApplicationFilterChain.doFilter(ApplicationFilterChain.java:206)
      >> at org.apache.catalina.core.StandardWrapperValve.invoke(StandardWrapperValve.java:230)
      >> at org.apache.catalina.core.StandardContextValve.invoke(StandardContextValve.java:175)
      >> at org.apache.catalina.core.StandardHostValve

            Unassigned Unassigned
            davout davout
            Votes:
            0 Vote for this issue
            Watchers:
            0 Start watching this issue

              Created:
              Updated:
              Resolved: