You are viewing a plain text version of this content. The canonical link for it is here.
Posted to user@struts.apache.org by Coby <no...@gmail.com> on 2007/08/30 10:40:22 UTC
can't work with validation, please help
Hi, I got a strange validation problem with the list which I retrieved from
an action:
the following form works perfectly fine without using validation,
<s:form action="saveClub" method="post">
<s:textfield label="Club name" name="club.clubName"
value="%{club.clubName}"></s:textfield>
<s:action name="listLeague" id="lgs"></s:action>
<s:select label="League" list="#lgs.leagues" name="club.league.id"
value="%{club.league.id}" listKey="id" listValue="leagueName"
headerKey="" headerValue="---Pls select---">
</s:select>
..........
..........
but after adding ClubAction-validation.xml, I got this error while
submitting the form: tag 'select', field 'list', name 'club.league.id': The
requested list key '#lgs.leagues' could not be resolved as a
collection/array/map/enumeration/iterator type. Example: people or
people.{name}.
Note: "leagues" is exactly a List which I defined in LeagueAction.
I am using paramsPrepareParamsStack interceptor for the saveClub action, and
defaultStack interceptor for listLeague action.
I tried all the ways to solve this problem but always failed... Anyone can
help with this issue? Thanks in advance!
--
View this message in context: http://www.nabble.com/%3Cs%3Aselect%3E-can%27t-work-with-validation%2C-please-help-tf4352582.html#a12402482
Sent from the Struts - User mailing list archive at Nabble.com.
---------------------------------------------------------------------
To unsubscribe, e-mail: user-unsubscribe@struts.apache.org
For additional commands, e-mail: user-help@struts.apache.org