Hi,

I found that custom.form stuff earlier, but I did not know what to
make from that. Is anybody here who can explain that for a beginner
and how it works in the controller, view, controller perspective ?

web2py rookie asking here, I can't really understand you specialists
as long as you stay that brief.
So with SQLFORM.factory I seem to be able to create one form from two
tables, even that means I have to composite a lot of fields in this
call there is a solution.
How can I access these fields the in the view ? How do I get the
default values from the database filled in (oops I forgot to mention
that the controller is an edit_user function which means the form
needs to be prefilled)

Anyway how can I access the fields inside the view and how do I
trigger the update of the table in case some values got changed.

Any example for this case ?

best
Stefan
On 24 Okt., 20:35, mdipierro <mdipie...@cs.depaul.edu> wrote:
> What is wrong with this?
>
> form=SQLFORM.factory(db.table1.field1,db.table2.field2)
>
> On Oct 24, 1:28 pm, Thadeus Burgess <thade...@thadeusb.com> wrote:
>
> > As far as [1], use custom form
>
> >http://web2py.com/AlterEgo/default/show/205
>
> > As far as [2], you could use SQLFORM.factory() or just a straight FORM()
> > object, and populate their default from the database, and on accepts you
> > would have to insert them seperately into the database.
>
> > I think this is a limitation of web2py that needs some work, Too often do I
> > have to break DRY just to get data from two tables into one form, its not
> > pretty, and difficult to maintain.
>
> > I find myself, almost not even using SQLFORM or CRUD anymore, just because I
> > need specific fine grained control.
>
> > -Thadeus
>
> > On Sat, Oct 24, 2009 at 1:22 PM, znafets <znaf...@googlemail.com> wrote:
> > > ot a table with user data and a table with address data referencing
> > > the user
> > > Now I would like to cre
--~--~---------~--~----~------------~-------~--~----~
You received this message because you are subscribed to the Google Groups 
"web2py-users" group.
To post to this group, send email to web2py@googlegroups.com
To unsubscribe from this group, send email to 
web2py+unsubscr...@googlegroups.com
For more options, visit this group at 
http://groups.google.com/group/web2py?hl=en
-~----------~----~----~----~------~----~------~--~---

Reply via email to