javax.el.PropertyNotFoundException: Property 'key'

出現次錯誤,本人歸集有: java

一、確實沒有該字段 ui

二、用了集合存儲,而直接用集合調用,即:(集合.字段名) this

三、用標籤時,沒寫標籤,直接上集合名,調用 spa

以上幾種狀況多是可能出現的比較廣泛的狀況,也是出現這個錯誤最可能的狀況; code

不過我本人遇到的這種錯誤是另一種狀況,以前一直是其餘方面的問題,最後才發現是我用到了多層的標籤遍歷, orm

使用多層標籤遍歷本無錯,錯就錯在取名字不注意: ip

<s:iterator value="othersVo.buttonList" var="item" status="status">
       <s:if test="#status.count%8 ==0">
        <span> <input class="ui-custom-process-check" type="checkbox" value="${item.key }"
          id="${item.key }" />${item.name}<input type="hidden"
          value="${item.selected }" /> <br /> </span>
       </s:if> 
       <s:else>
        <span> <input class="ui-custom-process-check" type="checkbox" value="${item.key }"
          id="${item.key }" />${item.name}<input type="hidden"
          value="${item.selected }" /> <br />
         <c:if test='${item.key eq "processBack"}'>
          <div id="selected" class="ui-custom-process-div" name="selected">
           <table width="100%" border="0" cellspacing="0" class="grid_biserial">
            <tr>
             <td>
              前置節點
             </td>
             <td>
          
              &nbsp;
             </td>
             <td>
              回退節點
             </td>
            </tr>
            <tr>
             <td width="45%" >
              <select name="LeadNode" ondblclick="moveOver();" size="10"
               multiple="multiple" style="width: 100%;">
               <c:forEach items="${designVo.forwardNodes}" var="item1"
                varStatus="status">
                <option>
                 ${item1}
                </option>
               </c:forEach>
              </select>
              &nbsp;
             </td>
             <td style="text-align: center;">
              <p style="margin-bottom: 5px; margin-top: -20px;">
               <input type="button"
                onclick="moveToRight(this.form.LeadNode,this.form.backNode);"
                class="buttonPro" style='width:30px'  value="&gt;" />
              </p>
              <p style="margin-bottom: 5px;">
               <input type="button"
                onclick="moveAll(this.form.LeadNode,this.form.backNode);"
                class="buttonPro" style='width:30px' 
                value="&gt;&gt;" />
              </p>
              <p style="margin-bottom: 5px;">
               <input type="button" onclick="removeMe();" 
                class="buttonPro" style='width:30px'   value="&lt;" />
              </p>
              <p>
               <input type="button" onclick="reMoveAll('0');" 
                class="buttonPro" style='width:30px'  value="&lt;&lt;" />
              </p>
      
             </td>
             <td width="45%">
              <select name="backNode" id="backNode"
               ondblclick="removechild(this)" size="10" multiple="multiple"
               style="width: 100%">
               <s:iterator value="designVo.backNodes" status="status"
                var="item">

以上第一行和最後一行中的var="item"就是出錯的根源,若是都叫item也會報錯:javax.el.PropertyNotFoundException: Property 'key' not found on type java.lang.String ci

相關文章
相關標籤/搜索