On 12/22/05, Leandro Lucarella <[EMAIL PROTECTED]> wrote:
> Great devcasts!

Thanks!

> What about moving (or at least giving the option) form_order to
> sqlwidgets(sqlclass, form_order=None), so you can avoid mixing up the
> model and controller. You can add the extra parameter to DataController
> too. I know sometimes (when you use the form in several places) it could
> be much more comfortable to specify it directly in the model, but when you
> just add a DataController, you can perfectly put the form_order there
> (once).

Looks like a good suggestion! Can you open a ticket on this idea?

>
> And maybe it could be even better to have an option to set the order
> directly in the template (because after all this is a view issue). I don't
> really know how to implement it, but I think the form.insert() would be
> the perfect place (like ${form.insert(widget_order=('pageName', 'data'))}).
>
> This could be used too to use declarative forms, this way you don't care
> about the widget ordering in a form and you can do something like:
>
> class MyForm(TableForm):
>         pageName = TextField()
>         data = TextField()
>
> MyForm.__dict__ would still be unordered but that's fine, because you just
> type form.insert(widget_order=('pageName', 'data')) in the template and
> get it ordered.
>
> And this way you get the view, model and controller well separated (I
> don't really care how the widgets are orderen in the form, that's the user
> interface designer problem ;)

This seems too painful, because you may end up repeating that
information on multiple templates.

Kevin

Reply via email to