What is the proper way to pass a model object used in Spring Web Flow to a Controller?
My use case is as follows:
I have a flow and the end state displays a model object that contains some calculated results. That works good. I also have a link on the page to generate a pdf to display the results. That too works fine if I manually set the model object.
So how do I get the model object used in the flow to the controller? Or is there a cleaner way to view pdfs using webflow?
Thanks
@John V. thank you your post did help me in the right direction. This is what I have working now:
in my flow.xml
in my webflowContext.xml file
PrintPDF.class
in my controller
PDF is defined as a bean in my spring-pdf-views.xml file
That class contains the following:
and finally the jsp has a link like
I hope that can help someone else. I am not sure if that is the most efficient way of doing it but I am open to any suggestions.