Hello list,

The trivial examples on the wiki work fine, but my attempt at using
<s:updownselect> fails when I try to use listKey and listValue:

<s:updownselect list="courseList" name="selectedCourses"
   allowMoveDown="true" allowMoveUp="true"
   label="Available Courses:"
   multiple="true" required="true"
   value="selectedCourses"
   allowSelectAll="true"/>

works, and it shows the results of my toString methods on the objects in
courseList.

Since I want data from specific fields in my objects, I added:

<s:updownselect list="courseList" name="selectedCourses"
   allowMoveDown="true" allowMoveUp="true"
   label="Available Courses:"
   multiple="true" required="true"
   value="selectedCourses"
   allowSelectAll="true"
   listKey="uuid" listValue="displayName" />

and instead of a very nice selection page, I get a runtime error:

[OLT] ERROR [http-8080-Processor25] runtime.error(96) |
Expected number, date, or string. parameters.nameValue evaluated instead to
freemarker.ext.beans.ArrayModel on line 60, column 101 in
template/simple/select.ftl.
The problematic instruction:
----------
==> if tag.contains(parameters.nameValue, itemKey) == true || (
parameters.nameValue?exists && parameters.nameValue?string == itemKey) [on
line 60, column 9 in template/simple/select.ftl]
in user-directive s.iterator [on line 40, column 1 in
template/simple/select.ftl]
in include "/${templateDir}/simple/select.ftl" [on line 7, column 1 in
template/simple/updownselect.ftl]
in include "/${parameters.templateDir}/simple/updownselect.ftl" [on line 3,
column 1 in template/css_xhtml/updownselect.ftl]
----------

Java backtrace for programmers:
----------
freemarker.template.TemplateException: Expected number, date, or string.
parameters.nameValue evaluated instead to freemarker.ext.beans.ArrayModel on
line 60, column 101 in template/simple/select.ftl.
(etc)

Has anyone had any luck with using updownselect tags in 2.0.6?  I didn't
have this problem in 2.0.5, so I'm hoping it's a simple fix.

Thanks!

-Brian

Reply via email to