You are viewing a plain text version of this content. The canonical link for it is here.
Posted to issues@struts.apache.org by "Niall Pemberton (JIRA)" <ji...@apache.org> on 2006/11/29 16:19:58 UTC
[jira] Resolved: (STR-2955) extending action does not pick up the
correct validate attribute
[ http://issues.apache.org/struts/browse/STR-2955?page=all ]
Niall Pemberton resolved STR-2955.
----------------------------------
Fix Version/s: 1.3.6
Resolution: Fixed
Assignee: Niall Pemberton
Fixed, thanks for reporting this!
http://svn.apache.org/viewvc?view=rev&revision=480593
> extending action does not pick up the correct validate attribute
> ----------------------------------------------------------------
>
> Key: STR-2955
> URL: http://issues.apache.org/struts/browse/STR-2955
> Project: Struts 1
> Issue Type: Bug
> Components: Core
> Reporter: Mark Shifman
> Assigned To: Niall Pemberton
> Priority: Minor
> Fix For: 1.3.6
>
>
> Given the actions below, with validate set to false on PrimaryAction the validate for ExtendedAction is not set to true in the ActionConfig object and validation doesn't occure.
> <action path="/ExtendendedAction" extends="/PrimaryAction" type="ExtendedAction"
> name="ExtendedForm" validate="true" scope="request" input="/WEB-INF/jsp/extended_input.jsp"
> parameter="ExtendParam">
> <forward name="success" path="/WEB-INF/jsp/extendedView.jsp" />
> </action>
> <action path="/PrimaryAction" type="PrimaryAction"
> name="PrimaryForm" validate="false" scope="request" input="/WEB-INF/jsp/primary_inputjsp"
> parameter="primaryParam">
> <forward name="success" path="/WEB-INF/jsp/primaryView.jsp" />
> </action>
> If the PrimaryAction's validate is set to true or isn't there (default is validate=true) and ExtendedAction is set to false it works correctly.
> looking at
> public void inheritFrom(ActionConfig config) in ActionConfig
> ...
> if (getValidate()) {
> setValidate(config.getValidate());
> }
> The validate would not be set if the baseConfig was set to false.
> Perhaps this is the semantics that is wanted, but it seems reasonable to be able to overide this attribute in either direction.
--
This message is automatically generated by JIRA.
-
If you think it was sent incorrectly contact one of the administrators: http://issues.apache.org/struts/secure/Administrators.jspa
-
For more information on JIRA, see: http://www.atlassian.com/software/jira