struts-user mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From Ashish Kulkarni <kulkarni_ash1...@yahoo.com>
Subject how do know if the validtor function is called or not
Date Mon, 31 Oct 2005 21:15:24 GMT
Hi
I want to validate 1 field from jsp, if other field
value is '3'.
so i added the following validation in validation.xml
<form name="POApprovalForm">
 <field property="comment" depends="validwhen">
  <arg0 key="errors.comment" />
	<var>
   	 <var-name>ttype</var-name>
	 <var-value>2</var-value>
	</var>
 </field>
</form>
but it seems it is not working, here is what i have
defined in my struts-config.xml file
<action name="POApprovalForm"		
type="com.pfizer.maps.action.purchase.POApprovalAction"
validate="true" input="/pages/ApprovalDataDisplay.jsp"
scope="request"
path="/pages/purchase/POApprovalAction">
<forward name="success"
path="/pages/approvals/ApprovalDataDispatchAction.do?nextpage=home"
/>
<forward name="all"
path="/pages/approvals/ApprovalDataDispatchAction.do?nextpage=all"
/>
<forward name="error"
path="/pages/purchasing/po.jsp" />
</action>

And this is how i have defined it in my jsp
function submitResubmit()
{
document.POApprovalForm.ttype.value="2";
document.POApprovalForm.submit();
}
<html:form action="pages/purchase/POApprovalAction"
focus="comment">

How do i find out why it is not working, is is
possible to debug this issue

Ashish


		
__________________________________ 
Yahoo! FareChase: Search multiple travel sites in one click.
http://farechase.yahoo.com

---------------------------------------------------------------------
To unsubscribe, e-mail: user-unsubscribe@struts.apache.org
For additional commands, e-mail: user-help@struts.apache.org


Mime
View raw message