Details
-
Bug
-
Status: Closed
-
Major
-
Resolution: Fixed
-
2.0.11
-
None
-
Tomcat 6, XWork 2.0.4
Description
I have an action that has a "selectedPageItems" element of type List<Long>. Using a JSp containing several checkboxes with value attributes of type Long, I receive an "Invalid field value for field" error when no items are selected.
The CheckboxInterceptor class has the following code block:
// is this checkbox checked/submitted?
if (!parameters.containsKey(name))
This causes a single boolean (or String) value to be added to the parameter list when no values are selected. This works fine if the Collection holds String or boolean values. However, in my situation the value can not be assigned to the Collection, giving the error.