[web2py] Re: eliminated repeat values

2010-06-09 Thread kike
I forget mention I'm cuban, and in my country I not access to googlecode On Jun 9, 4:37 pm, kike wrote: > the same problems I not permission. and now what > > On Jun 9, 4:12 pm, mdipierro wrote: > > > you should just type: > > > hg clonehttps://web2py.googlecode.com/hg/web2py > > > in your s

[web2py] Re: eliminated repeat values

2010-06-09 Thread kike
the same problems I not permission. and now what On Jun 9, 4:12 pm, mdipierro wrote: > you should just type: > > hg clonehttps://web2py.googlecode.com/hg/web2py > > in your shell and it will donwload a copy > > On Jun 9, 3:08 pm, kike wrote: > > > let my explain, in the addresshttp://web2py.

[web2py] Re: eliminated repeat values

2010-06-09 Thread mdipierro
you should just type: hg clone https://web2py.googlecode.com/hg/ web2py in your shell and it will donwload a copy On Jun 9, 3:08 pm, kike wrote: > let my explain, in the addresshttp://web2py.com/examples/default/download > in the trunk part are two link, the first mercurial repository in the >

[web2py] Re: eliminated repeat values

2010-06-09 Thread kike
let my explain, in the address http://web2py.com/examples/default/download in the trunk part are two link, the first mercurial repository in the section http://code.google.com/p/web2py/downloads/list they show me the error 403 Forbidden and tell me my client not have permission to get that url, and

[web2py] Re: eliminated repeat values

2010-06-09 Thread mdipierro
what do you mean "no permission" You do not need permission. On Jun 9, 2:36 pm, kike wrote: > What version of web2py I need use to try that, I download right now > a 1.79.2 version from home site and in that version don't work that > modification, and I not permission to download a trunk version.

[web2py] Re: eliminated repeat values

2010-06-09 Thread mdipierro
sorry. Trunk version only On Jun 9, 2:36 pm, kike wrote: > What version of web2py I need use to try that, I download right now > a 1.79.2 version from home site and in that version don't work that > modification, and I not permission to download a trunk version. > > On Jun 9, 12:30 am, mdipierro

[web2py] Re: eliminated repeat values

2010-06-09 Thread kike
What version of web2py I need use to try that, I download right now a 1.79.2 version from home site and in that version don't work that modification, and I not permission to download a trunk version. On Jun 9, 12:30 am, mdipierro wrote: > I changed the validator in trunk IS_IN_DB. Now it should b

[web2py] Re: eliminated repeat values

2010-06-08 Thread mdipierro
I changed the validator in trunk IS_IN_DB. Now it should be automatically grouping similar items. Optionally you can specify IS_IN_DB(...,groupby=...) Give it a try. On Jun 8, 11:07 pm, "mr.freeze" wrote: > Actually, that will not work since it modifies the collection in a > loop. Try this: > > d

[web2py] Re: eliminated repeat values

2010-06-08 Thread mr.freeze
Actually, that will not work since it modifies the collection in a loop. Try this: def unique_items_widget(f,v): inp = SQLFORM.widgets.options.widget(f,v) options = inp.elements('option') vals = [] inp.components = [] for opt in options: val = opt['_value'] if n

[web2py] Re: eliminated repeat values

2010-06-08 Thread mr.freeze
mdpierro is just saying that a simple patch needs to be made to IS_IN_DB. Until then, you can create a widget to remove duplicates: def unique_items_widget(f,v): inp = SQLFORM.widgets.options.widget(f,v) vals = [] for k, opt in enumerate(inp): if not opt['_value'] in vals:

[web2py] Re: eliminated repeat values

2010-06-08 Thread kike
In what part of the sentence vul.authors.name.requires=IS_IN_DB(vul,vul.authors.name) I need aggregate a groupby option to work, because in that sentence that parameter is incorrect and if I aggregate a groupby parameter in f=SQLFORM.factory(vul.authors.name) nothing append. How I can fixed that th

[web2py] Re: eliminated repeat values

2010-06-07 Thread mdipierro
haha. I think we need to add a groupby option to IS_IN_DB. On Jun 7, 5:16 pm, kike wrote: > Hi I need a form to search, and in that form a field with some > database values, I wrote the following > > vul.authors.name.requires=IS_IN_DB(vul,vul.authors.name) >         f=SQLFORM.factory(vul.authors.