vendredi 13 mars 2015

Understanding WebFlow on Grails

I'm using Spring Web Flow on Grails (2.0.8.1 on grails 2.3.11). I've created all dir under views and this is my little flow:



def registrazioneUtenteFlow = {

log.info("Registrazione Flow")

step1_informazioni_personali {
on("next").to("step2_informazioni_personali")
}

step2_informazioni_personali {
on("submit").to "step3_informazioni_personali"
on("return").to "step1_informazioni_personali"
}

step3_informazioni_personali {

}
}


I created three gsp under controllerName/flowName. Inside each JSP there is a form with a submit button. Ex. for first GSP:



<g:form action="registrazioneUtente">
<g:submitButton name="next" value="NEXT" />
</g:form>


Now.. If i put inside the state the "on" rule, I have an 404 with this url



registrazioneUtente?execution=e8s1&format=


But if I leave this from step1_informazioni_personali, I can see the page.


Why?!?


Thanks in advance


Aucun commentaire:

Enregistrer un commentaire