2011-07-11 60 views
0

我需要在顯示標記表中添加複選框,雖然我做了它但仍然無法使其工作。顯示標記和複選框

  1. 一旦我檢查了頭複選框,然後就應該生效的所有表格中的行
  2. 也選擇各行
  3. 選擇的同時點擊刪除按鈕,包括從數據庫中應該被刪除。
<display:table name="sessionScope.results" decorator="com.jobapp.TableDecorator" pagesize="10" requestURI="<%=\"JobServlet?_id=\"+Math.round(Math.random()*1000000)%>"> 

    <display:column title="<input type='checkbox' name='selectall'/>"> 
     <input type="checkbox" name="select" style="margin: 0 0 0 4px" /> 
    </display:column> 

    <display:column property="applicationId" title="Ref. Id" style="width=40px" /> 
    <display:column property="fullName" title="Full Name" style="width=120px"/> 
    <display:column property="dob" title="DOB" style="width=85px"/> 

    <display:column property="currentCountry" title="Current Location" style="width=85px"/> 
    <display:column property="nationality" title="Nationality" style="width=85px"/> 
    <display:column property="email" title="Email" autolink="true"/> 
    <display:column property="dateApplied" title="Date Applied" style="width=70px" /> 
    <display:column property="applicationStatus" title="Status"/> 
</display:table> 

預期與組件,但邏輯如何實現

回答

0

無論其顯示標籤1.1或1.2,如果它的1.2可以使用checkboxdecorator類包括複選框搞清楚該頁面顯示