org.zkoss.zel.ELException: Error reading 'allAccount' on type com.accounts.controller.AccountController

ZK-Tracker | liferay2012 | 5 years ago
  1. 0

    将ZK官方Tree组件示例用ZKUI改写时碰到的问题

    GitHub | 4 years ago | evanzeng
    org.zkoss.zel.ELException: Cannot convert demo.getting_started.Category@7dc999c4 of type class demo.getting_started.tree.CategoryTreeNode to class demo.getting_started.Category
  2. Speed up your debug routine!

    Automated exception search integrated into your IDE

  3. 0

    {code:xml} <zk> <window apply="org.zkoss.bind.BindComposer" viewModel="@id('vm') @init('issues.TestModel')"> <listbox model="@bind(vm.selBox)" mold="select" selectedIndex="@bind(vm.selIndex)"> <template name="model" var="item"> <listitem label="@bind(item)"/> </template> </listbox> <intbox value="@bind(vm.selIndex)" /> </window> </zk> {code} {code:java} public class TestModel { int selIndex; ListModelList<String> selBox; public TestModel(){ selIndex = 0; selBox = new ListModelList<String>(); selBox.add("A"); selBox.add("B"); selBox.add("C"); selBox.add("D"); selBox.add("E"); } public int getSelIndex() { return selIndex; } @NotifyChange public void setSelIndex(int selIndex) { this.selIndex = selIndex; } public ListModelList<String> getSelBox() { return selBox; } } {code} will get {code:none} org.zkoss.zel.ELException: Error writing 'selectedIndex' on type org.zkoss.zul.Listbox at org.zkoss.zel.BeanELResolver.setValue(BeanELResolver.java:142) at org.zkoss.zel.CompositeELResolver.setValue(CompositeELResolver.java:83) at org.zkoss.zel.CompositeELResolver.setValue(CompositeELResolver.java:83) at org.zkoss.xel.zel.XelELResolver.setValue(XelELResolver.java:110) at org.zkoss.bind.xel.zel.BindELResolver.setValue(BindELResolver.java:68) at org.zkoss.zel.impl.parser.AstValue.setValue(AstValue.java:215) 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:48) at org.zkoss.bind.impl.LoadPropertyBindingImpl.load(LoadPropertyBindingImpl.java:64) at org.zkoss.bind.impl.PropertyBindingHelper.loadComponentProperties(PropertyBindingHelper.java:350) at org.zkoss.bind.impl.BinderImpl.loadComponentProperties(BinderImpl.java:1439) at org.zkoss.bind.impl.BinderImpl.loadComponent(BinderImpl.java:1423) at org.zkoss.bind.impl.BinderImpl.loadComponent(BinderImpl.java:1425) at org.zkoss.bind.BindComposer.doAfterCompose(BindComposer.java:105) {code}

    ZK-Tracker | 5 years ago | dennis
    org.zkoss.zel.ELException: Error writing 'selectedIndex' on type org.zkoss.zul.Listbox
  4. 0

    {code:xml} <zk> <window apply="org.zkoss.bind.BindComposer" viewModel="@id('vm') @init('issues.TestModel')"> <listbox model="@bind(vm.selBox)" mold="select" selectedIndex="@bind(vm.selIndex)"> <template name="model" var="item"> <listitem label="@bind(item)"/> </template> </listbox> <intbox value="@bind(vm.selIndex)" /> </window> </zk> {code} {code:java} public class TestModel { int selIndex; ListModelList<String> selBox; public TestModel(){ selIndex = 0; selBox = new ListModelList<String>(); selBox.add("A"); selBox.add("B"); selBox.add("C"); selBox.add("D"); selBox.add("E"); } public int getSelIndex() { return selIndex; } @NotifyChange public void setSelIndex(int selIndex) { this.selIndex = selIndex; } public ListModelList<String> getSelBox() { return selBox; } } {code} will get {code:none} org.zkoss.zel.ELException: Error writing 'selectedIndex' on type org.zkoss.zul.Listbox at org.zkoss.zel.BeanELResolver.setValue(BeanELResolver.java:142) at org.zkoss.zel.CompositeELResolver.setValue(CompositeELResolver.java:83) at org.zkoss.zel.CompositeELResolver.setValue(CompositeELResolver.java:83) at org.zkoss.xel.zel.XelELResolver.setValue(XelELResolver.java:110) at org.zkoss.bind.xel.zel.BindELResolver.setValue(BindELResolver.java:68) at org.zkoss.zel.impl.parser.AstValue.setValue(AstValue.java:215) 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:48) at org.zkoss.bind.impl.LoadPropertyBindingImpl.load(LoadPropertyBindingImpl.java:64) at org.zkoss.bind.impl.PropertyBindingHelper.loadComponentProperties(PropertyBindingHelper.java:350) at org.zkoss.bind.impl.BinderImpl.loadComponentProperties(BinderImpl.java:1439) at org.zkoss.bind.impl.BinderImpl.loadComponent(BinderImpl.java:1423) at org.zkoss.bind.impl.BinderImpl.loadComponent(BinderImpl.java:1425) at org.zkoss.bind.BindComposer.doAfterCompose(BindComposer.java:105) {code}

    ZK-Tracker | 5 years ago | dennis
    org.zkoss.zel.ELException: Error writing 'selectedIndex' on type org.zkoss.zul.Listbox

    Not finding the right solution?
    Take a tour to get the most out of Samebug.

    Tired of useless tips?

    Automated exception search integrated into your IDE

    Root Cause Analysis

    1. org.zkoss.zel.ELException

      Error reading 'allAccount' on type com.accounts.controller.AccountController

      at org.zkoss.zel.BeanELResolver.getValue()
    2. The ZK EL Library
      CompositeELResolver.getValue
      1. org.zkoss.zel.BeanELResolver.getValue(BeanELResolver.java:93)
      2. org.zkoss.zel.CompositeELResolver.getValue(CompositeELResolver.java:67)
      2 frames
    3. The ZKoss Common Library
      XelELResolver.getValue
      1. org.zkoss.xel.zel.XelELResolver.getValue(XelELResolver.java:71)
      1 frame
    4. The ZK EL Library
      ValueExpressionImpl.getValue
      1. org.zkoss.zel.impl.parser.AstValue.getValue(AstValue.java:179)
      2. org.zkoss.zel.impl.ValueExpressionImpl.getValue(ValueExpressionImpl.java:189)
      2 frames