[web2py] Class in the session

2011-03-24 Thread NewBeen
Hello guys, I have this class in a model, Class Order: def __init__(self): self.basket={product:{},quantity:{}} def addProduct(self, Item): self.basket[product][name]=item[name] session.order=Order() So far so good, but when I execute this, the class is always been

[web2py:23584] Crud.create and Keep values

2009-06-08 Thread NewBeen
Greetings, How can i do this put keepvalues=True when i use the function crud.create() i already try: ### CODE ### form = crud.create('databasedp',onvalidation=lambda form:r(form)) def r(form): if form.accepts(request.vars,session,keepvalues=True): response.flash=Accept form ###

[web2py:23591] Re: Crud.create and Keep values

2009-06-08 Thread NewBeen
'}) ### But work fine in before this last update! On 8 Jun, 12:45, mdipierro mdipie...@cs.depaul.edu wrote: in thunk in 5 minutes crud.settings.keepvalues=True before calling crud.update() On Jun 8, 5:14 am, NewBeen rui.t...@gmail.com wrote: Greetings, How can i do this put keepvalues=True when

[web2py:23313] UnicodeDecodeError: 'ascii' codec can't decode byte 0xf0 in position 299: ordinal not in range(128)

2009-06-04 Thread NewBeen
Hi, Its me again, now when I put the code in the production(Linux box) server i get this error, but in the computer i use to develop(Windows xp) this don't happen. Here i leave the error some idea?? PS: I double check the charset in the database 10 time already :S # ERROR

[web2py:23103] Re: SyntaxError: Object exists and cannot be redefined

2009-06-02 Thread NewBeen
cannot find the incrimiating line. Can you post the content of the filed: h:\python\web2py_win\web2py_source\svn\applications\Dominos_Times/ views/default/list_all.html and its associated action On May 29, 10:30 am, NewBeen rui.t...@gmail.com wrote: the output i get

[web2py:22889] SyntaxError: Object exists and cannot be redefined

2009-05-29 Thread NewBeen
This is working fine but when i update to the last version in the svn start give this error Error traceback # Traceback (most recent call last): File H:\python\web2py_win\web2py_source\svn\gluon\restricted.py, line 107, in restricted exec ccode in environment File

[web2py:22892] Re: SyntaxError: Object exists and cannot be redefined

2009-05-29 Thread NewBeen
! On May 29, 2:38 pm, mdipierro mdipie...@cs.depaul.edu wrote: Just so that I understand, this works fine with 1.63 stable but not 1.63 intrunk? Seems like an odd error, can you email me your code so that I can do some debugging? Massimo On May 29, 9:21 am, NewBeen rui.t...@gmail.com wrote

[web2py:22895] Re: SyntaxError: Object exists and cannot be redefined

2009-05-29 Thread NewBeen
looks like. It would also be useful to know with some confidence if a change in web2py triggered the error or a change in your code did it. Massimo On May 29, 9:52 am, NewBeen rui.t...@gmail.com wrote: Sorry im testing with version 1.62 and don´t work to, i don't get why this just stop

[web2py:22422] crud.create() get the id of last create record

2009-05-22 Thread NewBeen
I'm using the crud.create() function but i can not get the id of the last create record, I try to do like this in the controller ### CODE ### response.flash='last id is %s' % form.vars.id # Always return None --~--~-~--~~~---~--~~ You received this

[web2py:22424] Re: crud.create() get the id of last create record

2009-05-22 Thread NewBeen
On Fri, May 22, 2009 at 1:18 PM, NewBeen rui.t...@gmail.com wrote: I'm using the crud.create() function but i can not get the id of the last create record, I try to do like this in the controller ### CODE ### response.flash='last id is %s' % form.vars.id # Always return None

[web2py:21266] Re: crud problems log events

2009-05-06 Thread NewBeen
Any news about this 8-) Thanks in advance Rui Gomes On 5 Maio, 16:16, mdipierro mdipie...@cs.depaul.edu wrote: It may be a bug. I will look into it and fix it tonight. On May 5, 10:21 am, NewBeen rui.t...@gmail.com wrote: Greetings I'm trying to log the events when a create a table

[web2py:21230] crud problems log events

2009-05-05 Thread NewBeen
Greetings I'm trying to log the events when a create a table with crud but i always get the same error my code is in the model crud.settings.logger=auth in the controller i try already @auth.requires_login() def customcreate(): form = crud.create('databasedp', log='Record %(id)s