Yes, you are right.
Thank you massimo
P.S. I love web2py!
On Jan 8, 11:06 pm, mdipierro wrote:
> Yes. It is possible to validate dependent fields as if you have a
> multi-column index.
> An example was discussed
> here:http://groups.google.com/group/web2py/browse_thread/thread/7551b50ef3...
The next logical step is creating, reading, updating, and deleting
other records from within the transaction, at which point the lambda
which is really a function, should not be stuck under the field=...
since it is now much more than a field.
Since the lambda is passed the entire record, perhaps
It is worth a try. I can help with debugging but have no time for
testing. Who wants to help?
Massimo
On Jan 9, 5:58 pm, "Phyo Arkar" wrote:
> Try to make web2py work on PyPy and we can port to al Runtime :)
>
> On Fri, Jan 9, 2009 at 11:44 PM, mdipierro wrote:
>
> > No but there is no rea
The more I think about this the more I like your solution.
We can provide both notations:
1) row.update_record(count=db.table.count+1)
2) row.update_record(count=lambda r: r.count+1)
and the lambda notation should work even without GAE.
If you send me the patch for GAE I can fix the non-gae.
perhaps it is time to again to run web2py to jython! who wants to
take the lead on this?
Massimo
Begin forwarded message:
> From: Frank Wierzbicki
> Date: January 9, 2009 3:37:38 PM CST
> To: Jython Developers ,
> userJython , "python-announce-
> l...@python.org"
> Subject: Jython 2.5 Bet
In trunk. See if it works as you suggested.
massimo
On Jan 9, 6:29 pm, mdipierro wrote:
> ok. I will change accept, we ca change T2 too. T2 does not need to
> keep backward compatibility. We can discuss this on Monday on the IRC.
> Thanks Robin.
>
> Massimo
>
> On Jan 9, 6:13 pm, Robin B wrote
let me think about this...
On Jan 9, 6:20 pm, Robin B wrote:
> > row.update_record(count=db.table.count+1)
>
> Nice, thats great syntax for incrementing counters, but you would need
> a lambda to do anything more complicated than arithmetic in a
> transaction.
>
> What about a more complex trans
ok. I will change accept, we ca change T2 too. T2 does not need to
keep backward compatibility. We can discuss this on Monday on the IRC.
Thanks Robin.
Massimo
On Jan 9, 6:13 pm, Robin B wrote:
> t2.create() already has onaccept= (it should have been called
> onsave= ) because it does not get c
> row.update_record(count=db.table.count+1)
Nice, thats great syntax for incrementing counters, but you would need
a lambda to do anything more complicated than arithmetic in a
transaction.
What about a more complex transaction like read a value and set it
based on rules (for creating a lock)?
t2.create() already has onaccept= (it should have been called
onsave= ) because it does not get called until after the record has
been created/updated within the form. You are right oncreate/onupdate
could be replaced with onsave, which does not need to be passed to the
SQLFORM.
Ideally, it shou
Try to make web2py work on PyPy and we can port to al Runtime :)
On Fri, Jan 9, 2009 at 11:44 PM, mdipierro wrote:
>
> No but there is no reason why not, just limited manpower.
> if you are interested in working on it you will have all our support.
>
> Massimo
>
> On Jan 9, 11:27 am, mikech
I think we have something like this without introducing a special
syntax for GAE based on lambda. In fact on non-gae you can now do
row.update_record(count=db.table.count+1)
The same could work on GAE with your code below.
massimo
On Jan 9, 1:11 pm, Robin B wrote:
> To perform certain actions
No but there is no reason why not, just limited manpower.
if you are interested in working on it you will have all our support.
Massimo
On Jan 9, 11:27 am, mikech wrote:
> I was just wondering is there any effort going on to see if web2py
> will work with IronPython?
>
> Mike
--~--~-~--
I was just wondering is there any effort going on to see if web2py
will work with IronPython?
Mike
--~--~-~--~~~---~--~~
You received this message because you are subscribed to the Google Groups
"web2py Web Framework" group.
To post to this group, send email to w
I can see the use for onaccept but why oncreate/onupdate. This would
be equivalent to putting the code after accepts(..) returns. Am I
missing something?
Massimo
On Jan 9, 3:33 pm, Robin B wrote:
> SQLFORM.accepts(...) could use hooks: onaccept, oncreate, onupdate.
>
> onaccept: called after FO
SQLFORM.accepts(...) could use hooks: onaccept, oncreate, onupdate.
onaccept: called after FORM.accept and immediately before create() or
insert()
oncreate: called after create()
onupdate: callled after update()
These hooks could be used by t2 and passed to SQLFORM:
t2.update(onaccept=...,onupda
On Jan 8, 9:30 pm, mdipierro wrote:
> Currently there is no mechinsm to enforce access control to the menu
> items, only to the content of those pages.
This is bad UI to present people with pages to which they don't have
access.
The solution within my app is to have the function which renders t
To perform certain actions on GAE you need transactions, eg.
atomically increment a counter.
This is what it would look like:
row.update_record(count=lambda r: r.count+1)
The GAE driver would check attributes for lambdas and invoke a
transaction when a lambda is present, the other SQL drivers c
Yes, maybe, I am a newbie in web app.
My suggestion is because in this moment i have a web app that uses t3.
This app has groups and each Group have diferent reports. But, if a
coordinator want to see reports of organizator, they can't because
they don't have access, and I show the message for t
Hi Massimo,
I am using T2 because I believe it's an easy way to manage users
rights.
I don't know how to use and where to put the following code:
t2.add_membership(person_id,group_id)
Normally , I think it's necessary only one time !
Is it possible to create a form to enable administrator to
On 9 jan, 15:07, mdipierro wrote:
> If the are app specific I would put them in a model file.
>
> I was not planning to extend the number of built-in validators but you
> raised a good issue. I think we need one more or one more parameter
> for IS_IN_DB.
>
Yes, I think it's a great idea !
The
Hi Massimo,
I don't think that the sharplus guys would like to distribute their
DLLs with an opensource package but I will ask them. On the other
hand, I am determined to get an ICU enabled version of sqlite compiled
with open source tools or at least linked with libraries that would
allow us to
Interesting. I could use some help with this. Will the license allow
redistribution?
On Jan 9, 7:36 am, Petros Diveris wrote:
> Ok,
>
> It seems that the version of sqlite shipped with Python versions 2.5
> to 3.0 for Windows has been compiled in a way as to not include what
> the sqlite guys ca
If the are app specific I would put them in a model file.
I was not planning to extend the number of built-in validators but you
raised a good issue. I think we need one more or one more parameter
for IS_IN_DB.
On Jan 9, 2:44 am, tknack wrote:
> Thank you, Massimo, it works fine
>
> But, i
Ok,
It seems that the version of sqlite shipped with Python versions 2.5
to 3.0 for Windows has been compiled in a way as to not include what
the sqlite guys call the ICU extension. The ICU is a little extension
that links sqlite with the ICU library (installed separately), thus
allowing it to pr
There has been a lot of discussion on HTML helpers. I think their main
shortcoming is actually that for novice web2py users it's hard to find
'the right amount' of them. Some tend to avoid them like yourself and
deprive themselves of some rapid prototyping/design options, while
some people overuse
Hmmm, I sent you the patch directly last night (after your 5:51pm)
post, and the link works for me... Too much romulan ale ? I'll resend
anyway :)
b...@odin:/var/tmp$ wget http://www.atombiztos.hu/cron-2009-01-08.patch
--11:50:13-- http://www.atombiztos.hu/cron-2009-01-08.patch
=> `cr
On Jan 8, 1:26 pm, mdipierro wrote:
> I liked the suggestion but I removed because of logical problems.
> While all other links from site link actions in the admin app, this
> link would link an action that belongs to the application. An
> application may have removed appadmin.py, renamed it, cha
Thank you, Massimo, it works fine
But, if I want to put these codes in the right files, which files
should I use and which imports should I do ?
have you as a project to expand the list of validators or to make the
DAL able to handle multi-column constraints ?
T.
On 8 jan, 18:32, mdipierro
29 matches
Mail list logo