Alberto Valverde wrote:
>
> Hmmm, you mean at the validate decorator, right? Remember all the
> troubles we had regarding the method's signature. I f the form is FQ
> then the controller will receive just one arg unless we hack it at
> the decoding filter (which we already considered a bad hack).
> Normalizing the variables at the decorator is not possible because
> it's too late, the method's sig wont match.
>
> Maybe I missed your point, if so please clarify... :)
>

Yep, my idea is different but now I've another idea that's even more
easier and less obtrusive, we just need to signal what's the form
that's been validated and put that into for example
cherrypy.request.validated_form, now when a form or field wants to read
c.p.input_values or c.p.validation_errors it just checks that it's name
is the same as the validated form (or better the instance is the same)
otherwise it should not use those values, no need of a fqf form and
everyone is happy. ;-)


>
> Replied above, to have a FQF transparent to the user (having a normal
> controller method which receives the form's fields, not the form
> itself) we need to hack that at the filter :/

Nope, the trick is that you can validate only one form at once hence
you don't need to fully qualify it on the HTML page, hence no need to
pop it from the nested dict into params.

>
> Maybe I'm wrong, a working example will surely prove it :)

Now I'm at the uni, I will prepare a final patch that removes fqf,
addresses display_field_for and required_fields along with more than
one form in the same page and post it for discussion today, it's all
here in my mind but now I need a break and start doing the thing I'm
supposed to do. ;-)

Ciao
Michele


--~--~---------~--~----~------------~-------~--~----~
You received this message because you are subscribed to the Google Groups 
"TurboGears Trunk" group.
To post to this group, send email to [email protected]
To unsubscribe from this group, send email to [EMAIL PROTECTED]
For more options, visit this group at 
http://groups.google.com/group/turbogears-trunk
-~----------~----~----~----~------~----~------~--~---

Reply via email to