I'm trying to implement what I thought would be a very simple action with the Stripes framework. I used the @Wizard annotation to perform my "Create" action and it works well but when I try to use this for the edit action (ie. pass in the ID of the object to edit), I get the following error:
"Submission of a wizard form in Stripes absolutely requires that the hidden field Stripes writes containing the names of the fields present on the form is present and encrypted (as Stripes write it). This is necessary to prevent a user from spoofing the system and getting around any security/data checks."
Does anyone know a way around this? I'd love to keep using wizard as there are a LOT of inputs in my create/edit actions and it handles a lot of the hard work ;)
I'm still having a little trouble with my edit action though.
For starters, my edit action is for a model which references other objects. Although your Stripes book says "If your model objects use other model objects, that’s no problem either—Stripes happily uses deeply nested properties," I can't find an example into how this is implemented.
What I'm trying to do is the following:
And then in the jsp, I'd like to do the following:
The above jsp code is used for both the create and edit actions (same code, but different files if you know what I mean). However, the values for Manufacturer id or the product categories will not get passed through this way. But when I change the above code to look like this:
They will get passed through. Unfortunately, when I go to edit my product the product name and description get populated but the other fields do not (ie. the dropdown defaults to the first option and the multi-select box does not highlight any of the previous entries.
I'd really appreciated it if you could help me out here.
posted 9 years ago
Ger, could you paste the Product class and the rest of your action bean? It will be easier to try and determine why it's not working.