Hi!
In my @InitBinder method I call binder.setDisallowedFields(). Which fields that should be included here depends on the state of the command Object.
I tried to get access to the command object with the follwing code:
which gave me the following errormessage: @ModelAttribute is not supported on @InitBinder methodsCode:@InitBinder public void initBinder(@ModelAttribute("myCommand") final MyCommand myCommand, final HttpServletRequest request, final ServletRequestDataBinder binder) throws Exception { }
I could let both this methond and my @ModelAttribute method delegate the job of getting the command object based on the request but would just like to ask here if someone has found a more elegant solution
We are using Spring 3.0.5.RELEASE.
TIA!
-Kaj![]()



Reply With Quote
