Re: [web2py] Re: form / subform / adding row (field)...

2011-02-04 Thread Richard Vézina
Here a other design I would implement... http://developer.android.com/resources/articles/contacts.html Maybe not the MIME type, but to normalize the relation in : Entity : Master result Repeated result Relation Master result one2man

Re: [web2py] Re: form / subform / adding row (field)...

2011-02-02 Thread Richard Vézina
Ref about my search on this topic : RANDOM : NO ORDER Here the funding thread of WTForms FormBase : http://groups.google.com/group/wtforms/browse_frm/thread/c8b5f5d98c41a6d2/6e69c5c4e820fd7b?lnk=gst&q=subform#6e69c5c4e820fd7b

Re: [web2py] Re: form / subform / adding row (field)...

2011-02-02 Thread Richard Vézina
The app I had attached in the preceding email works, but it broke the workflow. I can't get the added inputs values in form.vars, so I take them from request.vars or somewhere else don't remember... There is also an other problem with this hack... It not uses de validators for all the inputs... So

[web2py] Re: form / subform / adding row (field)...

2011-02-02 Thread Massimo Di Pierro
I am not sure what the Django doce does. Did you look into Field('items','list:string')? Is that any close? On Feb 2, 5:40 pm, skwasha wrote: > I'm curious if you ever got this all figured out? I wanna do something > similar (essentially allow people to build up lists of things with > arbitrary

[web2py] Re: form / subform / adding row (field)...

2011-02-02 Thread skwasha
I'm curious if you ever got this all figured out? I wanna do something similar (essentially allow people to build up lists of things with arbitrary list length.) If you had something complete I'd love to see it if possible. Very new to web2py myself. On Jan 24, 11:27 am, Richard Vézina wrote: > F

[web2py] Re: form / subform / adding row (field)...

2011-02-02 Thread skwasha
I'm curious if you ever got this all figured out? I wanna do something similar (allow users to create lists of things of arbitrary list length.) I'm new to web2py myself, so if you had something working you'd be willing to share it'd be of great interest/help. thanx On Jan 24, 11:27 am, Richard V

Re: [web2py] Re: form / subform / adding row (field)...

2011-01-24 Thread Richard Vézina
Found this : http://code.google.com/p/django-dynamic-formset/ Richard On Fri, Jan 21, 2011 at 3:34 PM, Richard Vézina wrote: > Hello, > > Here a version 0.1 pre pre before alpha [?] > (see attachement) > > But it works... > > There is code

Re: [web2py] Re: form / subform / adding row (field)...

2011-01-19 Thread Richard Vézina
If you move the script into the layout.html in the head it still works... You can then remove the view /view/default/register.html_ So you get access to admin, request, session, response button to see what going. You can see that city2 vars is store in session for example. Richard On Wed, Jan 19

Re: [web2py] Re: form / subform / adding row (field)...

2011-01-19 Thread Richard Vézina
For now only adding and removing city input. I clone city input retag id='city' to id='city2' for the first clone and so on. I change all the id attribute of other tag cloned like divs. I had a garbage can icon and make it mouseover. That it for now. Since I change the id of input to city2, city3

[web2py] Re: form / subform / adding row (field)...

2011-01-19 Thread mart
Excellent! je prends le train, direction MTL, a tous les quelques mois pour me rendre au bureau (peut-etre un peu moins souvent l'hiver ;) ) SO, I have a question: Once, I use the button to add a field (which does work well), what should be the expected back-end result? does one of the tables get

Re: [web2py] Re: form / subform / adding row (field)...

2011-01-19 Thread Richard Vézina
;-) Originellement oui... I would tell you on the orther thread that I post this one... I will do it just for the one that fall on the orther thread so they could keep track... I continue today working on this. Richard On Wed, Jan 19, 2011 at 12:30 AM, mart wrote: > Hey, es-tu de Montreal? >

[web2py] Re: form / subform / adding row (field)...

2011-01-18 Thread mart
Hey, es-tu de Montreal? On Jan 18, 7:08 pm, Richard Vézina wrote: > I forgot to paste : > > def register(): >     form=SQLFORM.factory(db.client, db.address, formstyle = 'divs') #, > table_name='dummy_name') >     if form.accepts(request.vars): >         id = db.client.insert(**db.client._filter_

[web2py] Re: form / subform / adding row (field)...

2011-01-18 Thread mart
I'm going to try this :) sorry, I mean to try your code from yesterday. I think sub-forms would be an awesome addition. Anyways, if it helps, I'll test and provide what i can :) Mart On Jan 18, 7:08 pm, Richard Vézina wrote: > I forgot to paste : > > def register(): >     form=SQLFORM.factory(db

[web2py] Re: form / subform / adding row (field)...

2011-01-18 Thread Richard Vézina
I forgot to paste : def register(): form=SQLFORM.factory(db.client, db.address, formstyle = 'divs') #, table_name='dummy_name') if form.accepts(request.vars): id = db.client.insert(**db.client._filter_fields(form.vars)) form.vars.client=id id = db.address.insert(**d