On 21/03/2006, at 8:37, Michele Cella wrote:

>
> Hi,
>
> Ok, I've just said to Ronald that widgets are almost stable now, I've
> forgot to mention the last thing that *may* happen but that should be
> totally user invisible, it's just an internal reorganization to make
> things more clear and move some other things where they belong.
>
> The problem is that since the initial re-design many form related
> details have found their way inside base.py again, for example the  
> path
> managing (update_path, path, name_path), is_validate, the validate
> method and so on... this is not a big problem but it's not a nice  
> thing
> from an OOP POV but does not reflect the intended usage in a clean  
> way.
>
> The idea is to move all these things inside forms.py to make it clear
> that Widget is not a form specific component (this will also help  
> us to
> remove the "in_path" attribute) and that TG uses it to manage forms  
> but
> you can use it to do other nifty things totally unrelated to forms.
>
> What I want to ask is:
>
> 1) Opinions?
> 2) I would like to also remove (given the previous discussion about
> layouts and widgets) CompoundWidget and RepeatingWidget (the latter is
> very form related) from there, is someone using CompoundWidget to do
> something other outside of form things?

Yep, I think CompoundWidget has a place outside forms too, for  
example, the to-be-released AjaxGrid with pagination, filtering,  
etc... It will probably combine buttons, select fields, textfields,  
ajaxgrid, etc. into something like:

smart_list {
     search_form {
          ....
     }
    ajaxgrid
}

I could place the grid inside the form but I don't think it belongs  
there really. IMO it's really a compound widget with a form (that  
GETs instead of POSTs) and an ajaxgrid that shows the results as  
children.

I don't think its sole layout either because there could be many of  
these in just one page. I's much cleaner to insert n of these in a  
page than to put n forms + n grids in the same page template (and  
sync their ids and various params so the JS knows which grid to  
update and where to load the JSON from).

Alberto


--~--~---------~--~----~------------~-------~--~----~
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