I am new to Kendo and I am testing out the grid functionality using the JSP tag library with the Grid control.
In my Java code I am building up a List<Employees> and setting it as an attibute in the request. The Employee class is simple, being
private int EmployeeID;
private int ManagerID;
private String LastName;
private String FirstName;
with accompanying getters and setters.
I am sending it to the JSP page using
request.setAttribute( "theData", employees);
I have successfully displayed the grid using the following tags in my JSP page.
<kendo:grid name="grid1" id="grid1"
sortable="true"
groupable="true">
<kendo:grid-pageable buttonCount="5" pageSize="5" info="true">
</kendo:grid-pageable>
<kendo:dataSource data="${theData}">
</kendo:dataSource>
<kendo:grid-columns>
<kendo:grid-column field="firstName" title="First Name" width="80px" />
<kendo:grid-column field="lastName" title="Last Name" width="80px"/>
<%-- <kendo:grid-column field="employeeID" title="Employee ID" /> --%>
<%-- <kendo:grid-column field="managerID" title="Manager ID" /> --%>
</kendo:grid-columns>
</kendo:grid>
I have also sucesfully displayed the grid if I remove the entire kendo:grid-columns tag. Therefore I know that my data path is wired up correctly.
If I uncomment out either of the grid-columns (employeeID or managerID) the page throws a NullException error at
at com.kendoui.taglib.BaseTag.setProperty(BaseTag.java:67)
at com.kendoui.taglib.grid.ColumnTag.setField(ColumnTag.java:137)
...
Any combination of two data columns displays as expected but adding a third or fourth one cases the exception. Is this something I am doing wrong? Is this a known issue with the JSP tag libraries?
Thanks for any help you can provide.
Steven
In my Java code I am building up a List<Employees> and setting it as an attibute in the request. The Employee class is simple, being
private int EmployeeID;
private int ManagerID;
private String LastName;
private String FirstName;
with accompanying getters and setters.
I am sending it to the JSP page using
request.setAttribute( "theData", employees);
I have successfully displayed the grid using the following tags in my JSP page.
<kendo:grid name="grid1" id="grid1"
sortable="true"
groupable="true">
<kendo:grid-pageable buttonCount="5" pageSize="5" info="true">
</kendo:grid-pageable>
<kendo:dataSource data="${theData}">
</kendo:dataSource>
<kendo:grid-columns>
<kendo:grid-column field="firstName" title="First Name" width="80px" />
<kendo:grid-column field="lastName" title="Last Name" width="80px"/>
<%-- <kendo:grid-column field="employeeID" title="Employee ID" /> --%>
<%-- <kendo:grid-column field="managerID" title="Manager ID" /> --%>
</kendo:grid-columns>
</kendo:grid>
I have also sucesfully displayed the grid if I remove the entire kendo:grid-columns tag. Therefore I know that my data path is wired up correctly.
If I uncomment out either of the grid-columns (employeeID or managerID) the page throws a NullException error at
at com.kendoui.taglib.BaseTag.setProperty(BaseTag.java:67)
at com.kendoui.taglib.grid.ColumnTag.setField(ColumnTag.java:137)
...
Any combination of two data columns displays as expected but adding a third or fourth one cases the exception. Is this something I am doing wrong? Is this a known issue with the JSP tag libraries?
Thanks for any help you can provide.
Steven