Re: [web2py] json validation

2013-01-19 Thread Bill Thayer
wow I'd never have thought of that - Thanks! Valid JSON On Saturday, January 19, 2013 6:37:08 PM UTC-6, Jonathan Lundell wrote: > > On 19 Jan 2013, at 4:21 PM, Bill Thayer > > wrote: > > My app stores EDA information (cad programs for designing microchips) so > storing cell attributes in a j

[web2py] Re: smartgrid - display linked_tables link as a dropdown button instead

2013-01-19 Thread Simon Ashley
Its high on our list as well. That plus a denser edit/create/view layout similar to Scubism's Solid Form. --

Re: [web2py] Re: PowerFormWizard 0.1.4 - Bug Fixes and auto_validation (+ a new plugin for grids)

2013-01-19 Thread Bruno Rocha
it is only on https://bitbucket.org/rochacbruno/powerformwizard/src but not updated yet.. on my todo-list to work on this. On Sat, Jan 19, 2013 at 10:43 PM, Bill Thayer wrote: > Hi Bruno, > > Forgive me if I missed your updates. The link below does not work today. > Where can I find the latest

[web2py] Re: PowerFormWizard 0.1.4 - Bug Fixes and auto_validation (+ a new plugin for grids)

2013-01-19 Thread Bill Thayer
Hi Bruno, Forgive me if I missed your updates. The link below does not work today. Where can I find the latest information. Regards, Bill > >> *# Whats next? >> *working on a new plugin for the 'Power' family, it is a JSON based >> tableless grid (which is much more than a grid) >> hope to rel

Re: [web2py] json validation

2013-01-19 Thread Jonathan Lundell
On 19 Jan 2013, at 4:21 PM, Bill Thayer wrote: > My app stores EDA information (cad programs for designing microchips) so > storing cell attributes in a json object and taking advantage of json rpc > would be beneficial. I am trying out Alex's new 'json' data type and with the > serializer and

[web2py] Re: Exposing validators as JSON?

2013-01-19 Thread Bill Thayer
+1 would a 'json:reference mytable' field type similar to 'list:reference mytable' or perhaps a format=lambda row: row.json() be possible? -Bill On Tuesday, January 15, 2013 6:14:40 PM UTC-6, Derek wrote: > > That would be cool, perhaps you could add a class to the fields and key > off the

[web2py] json validation

2013-01-19 Thread Bill Thayer
My app stores EDA information (cad programs for designing microchips) so storing cell attributes in a json object and taking advantage of json rpc would be beneficial. I am trying out Alex's new 'json' data type and with the serializer and IS_JSON() validator. Using the controller function below

[web2py] Re: HOSTING FOR web2py ?

2013-01-19 Thread samuel bonilla
thanks bruno El viernes, 18 de enero de 2013 21:11:43 UTC-5, samuel bonilla escribió: > > I'm doing testing for my application in pythonanywhere.com, but I had > some problems with paypal and I could not buy a domain. > > someone can recommend another hosting web2py to not only accept paypal

Re: [web2py] unable to drop table

2013-01-19 Thread Bruno Rocha
Is it the web shell? (if yes, its buggy) --

[web2py] Re: unable to drop table

2013-01-19 Thread DenesL
It works for me. web2py 2.3.2 src on windows. On Saturday, January 19, 2013 5:48:49 PM UTC-5, greaneym wrote: > > Hi, > > I am using stable web2py, with sqlite db and trying to drop a table. In the > shell, I connect to the db, then > > In [6] : print db._uri > sqlite://storage.sqlite > > In [7]

[web2py] Re: BEAUTIFY broken in trunk

2013-01-19 Thread DenesL
That confirms my original suspicion, rev.4631, up to Massimo now. On Saturday, January 19, 2013 4:50:40 PM UTC-5, Alan Etkin wrote: > > > It works fine in 2.3.2, whether is rows or forms. > > The problem was introduced by changing gluon/html.py here: > > http://code.google.com/p/web2py/source/de

[web2py] unable to drop table

2013-01-19 Thread greaneym
Hi, I am using stable web2py, with sqlite db and trying to drop a table. In the shell, I connect to the db, then In [6] : print db._uri sqlite://storage.sqlite In [7] : print db._dbname sqlite In [8] : print db.tables ['auth_user', 'auth_group', 'auth_membership', 'auth_permission', 'auth_even

[web2py] Re: Auth login with Firefox

2013-01-19 Thread Ron McOuat
This happens if cookies are disabled in a browser but you mention the welcome app works okay for login so that wouldn't be the cause. On Friday, 18 January 2013 16:59:53 UTC-8, villas wrote: > > Can't figure it out so I shall rebuild the app on top of the latest > welcome. That seems to work ok

[web2py] Re: BEAUTIFY broken in trunk

2013-01-19 Thread Alan Etkin
> It works fine in 2.3.2, whether is rows or forms. I belive the problem was introduced by changing gluon/html.py here: http://code.google.com/p/web2py/source/detail?r=3fa5f8c16fe9437351e1e9ca2060471e9c73b16d --

[web2py] Re: BEAUTIFY broken in trunk

2013-01-19 Thread DenesL
It works fine in 2.3.2, whether is rows or forms. --

Re: [web2py] Re: Insert on multiple tables with SQLFORM.grid

2013-01-19 Thread Angelo Compagnucci
Thanks Anthoni, Great idea! That works for sure! Thanks! Il giorno 17/gen/2013 19:43, "Anthony" ha scritto: > The "create" action of the grid results in a URL that ends with args > /new/tablename, so you can do: > > if request.args and request.args[-2] == 'new': > tablename = request.args[-

[web2py] Re: how to select current id record for record updat

2013-01-19 Thread greaneym
Thank you very much for the help, Massimo. What this did was update all the records with the new invoice number. I re-read the chapter on DAL and see the info on the update_record. I still can't get it to select the database record I want and only update a record in memory, but I decided to ch

[web2py] Re: BEAUTIFY broken in trunk

2013-01-19 Thread Alan Etkin
>>> form = SQLFORM(db.auth_user) >>> b = BEAUTIFY(form) >>> b.xml() '' It seems it's a general problem with BEAUTIFY, not only with rows --

[web2py] Re: compute field doesn't work on update

2013-01-19 Thread palomar
I had the 2.1 and I've just updated to 2.3 (I hoped to solve the problem...) request.vars.id is the vars from the ajax call; it works, I'm sure, articolo.p_p is correctly updated Il giorno sabato 19 gennaio 2013 18:03:34 UTC+1, palomar ha scritto: > > Other users have the same problem and, sorr

[web2py] BEAUTIFY broken in trunk

2013-01-19 Thread DenesL
Rows are not serialized by BEAUTIFY in trunk v4636 (since v4631 I believe). --

[web2py] Re: compute field doesn't work on update

2013-01-19 Thread Massimo Di Pierro
Works for me: >>> db =DAL() >>> db.define_table('magazzino', ... Field('id_tipo', 'integer',default=0), ... Field('p_p','double', default=0.0), ... Field('pp_tot','double', writable=True, readable=True, compute=lambda r: r['id_tipo']==0 and r['p_p']*1 or r['p_p']*r['id_tipo']*-1), ..

Re: [web2py] If I upload a file manually does it check the validators?

2013-01-19 Thread Tito Garrido
Also I am using RESIZE validator from imageutils.py Not sure why it happens... anyway I was trying to use http://www.web2pyslices.com/slice/show/1576/html5-file-uploads-with-jquerywith RESIZE... I could use it uisng THUMB, but the RESIZE validator doesn't work for the main image... On Sat, Jan 1

[web2py] compute field doesn't work on update

2013-01-19 Thread palomar
Other users have the same problem and, sorry but I can't find my solution; i tried with readable=true and writable=true, to update all the field interested in the compute function, to comment the line in DAL.py, but nothing. I have this table: db.define_table('magazzino', Field('id_tipo',

Re: [web2py] If I upload a file manually does it check the validators?

2013-01-19 Thread Massimo Di Pierro
Now that you show more of your code, things are more clear ... fileApp=request.vars.pic filename=fileApp.filename.replace(' ', '') ... for you fileApp is None, while you expect a cgi.FieldStorage object. I do not know why that is. It would be "pic" is the fron var name. It co

[web2py] Re: Logging in with applications.

2013-01-19 Thread Massimo Di Pierro
Where do you read that comment? login_bare does login the user and returns the user record. On Saturday, 19 January 2013 00:31:00 UTC-6, encompass wrote: > > The last link was the one I was looking at first. Before this post. But > """ > login_bare returns user if the user exists and the passw

Re: [web2py] If I upload a file manually does it check the validators?

2013-01-19 Thread Anthony
> > aux=db.files.file_upload.store(fileApp, filename) #db.files.insert(file_upload=aux,title=filename) *# USING THIS LINE IT > WORKS * > > *db.files.validate_and_insert(file_upload=db.files.file_upload.store(fileApp, > filename),title=filename)* # *THIS LINE CAUSES THE ERROR* > Bu

Re: [web2py] Re: last_run_time as argument for a scheduled function

2013-01-19 Thread Martin Weissenboeck
ok, thank you. 2013/1/19 Niphlod > absolutely not clear what you want, but i guess a simple > > db(db.scheduler_task.function_name = > 'yourfunction').select(db.scheduler_task.next_run_time, > db.scheduler_task.last_run_time) > > will fetch the values to use in that function call you need. > >

Re: [web2py] If I upload a file manually does it check the validators?

2013-01-19 Thread Tito Garrido
On Sat, Jan 19, 2013 at 12:12 AM, Massimo Di Pierro < massimo.dipie...@gmail.com> wrote: > > filename=(fileApp.filename.repl**ace(' ', '') if fileApp else '') > > Interesting, I have tried it before but even it does not work... the error appears everytime that I enable the validation during the i

[web2py] Re: last_run_time as argument for a scheduled function

2013-01-19 Thread Niphlod
absolutely not clear what you want, but i guess a simple db(db.scheduler_task.function_name = 'yourfunction').select(db.scheduler_task.next_run_time, db.scheduler_task.last_run_time) will fetch the values to use in that function call you need. On Saturday, January 19, 2013 9:04:34 AM UTC+1, mw

Re: [web2py] Storing Python code in db?

2013-01-19 Thread Bruno Rocha
http://docs.python.org/2/library/pickle.html http://python.about.com/od/pythonstandardlibrary/a/pickle_intro.htm --

[web2py] last_run_time as argument for a scheduled function

2013-01-19 Thread Martin Weissenboeck
Hi, a question about the scheduler: The scheduler calls a function f() 12 times per hour. db.scheduler_task knows the last_run_time and next_run_time. I want to call the function f with these two values as arguments. Is there a simple way? Regards, Martin --