On Sunday, July 10, 2016 at 10:09:55 PM UTC-4, Michael Beller wrote:
>
> For n2, you could try only updating if n2 was not empty.  This is not 
> tested but something like ...
>
> Field('n2', 'integer', compute=lambda r: r.start_number if not r.n2 else 
> None)
>

That won't work because (a) the current value of n2 will not be included in 
r, and (b) even if it were, you would not want to set the value of n2 to 
None.

Anthony

-- 
Resources:
- http://web2py.com
- http://web2py.com/book (Documentation)
- http://github.com/web2py/web2py (Source code)
- https://code.google.com/p/web2py/issues/list (Report Issues)
--- 
You received this message because you are subscribed to the Google Groups 
"web2py-users" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to web2py+unsubscr...@googlegroups.com.
For more options, visit https://groups.google.com/d/optout.

Reply via email to