212 <map:act type="mod-db-sel-email" src="optional src" >
213 <map:parameter name="descriptor" value="db_email.xml"/>
214 <map:parameter name="table-set" value="MAILLIST-add"/>
215 <map:act type="session-propagator">
216 <map:parameter name="violation" value="That email address is already in the database."/>
217 </map:act>
218 <map:call resource="ListAction"/>
219 </map:act>
188 //At this point violation is going to act as an error holder
189 if ( ( getSession( false ).getAttribute( "violation" ) != null ) &&
190 ( getSession( false ).getAttribute( "violation" ).toString().length() > 0 ) )
191 {
192
193 getLogger().debug( "ListAction Error: violation: " + getSession( false ).getAttribute( "violation" ).toString() );
194 195 Violation v = new Violation();
196 v.setPath( "Test" );
197 v.setMessage( getSession( false ).getAttribute( "violation" ).toString() );
198 Violation[] va = { v };
199 getForm().addViolations( Arrays.asList( (Object[])va ) );
200 }
Rob Johnston wrote:
Is it possible to do some validation on input (outside the scope of
schematron) in the WizardAction class, and if this validation fails, add
a new violation so that the xmlform transformer will properly add in
xf:violation tags and flow will halt until the violation is cleared up?
thanks,
rob
---------------------------------------------------------------------
Please check that your question has not already been answered in the
FAQ before posting. <http://xml.apache.org/cocoon/faq/index.html>
To unsubscribe, e-mail: <[EMAIL PROTECTED]>
For additional commands, e-mail: <[EMAIL PROTECTED]>
-- Robert J. (Bobby) Mitchell Systems Administrator NASA Institute for Advanced Concepts 555A 14th St Atlanta, Ga. 30318 Phone: (404)347-9633 Fax: (404)347-9638
--------------------------------------------------------------------- Please check that your question has not already been answered in the FAQ before posting. <http://xml.apache.org/cocoon/faq/index.html> To unsubscribe, e-mail: <[EMAIL PROTECTED]> For additional commands, e-mail: <[EMAIL PROTECTED]>
