so, if you add update=False to the field definition, shouldn't the
unchecked checkbox put in a value of false in the db? because i am still
getting errors upon updating. lucas
--
Resources:
- http://web2py.com
- http://web2py.com/book (Documentation)
- http://github.com/web2py/web2py (Source
On Sunday, 23 June 2013 10:27:22 UTC+10, Anthony wrote:
>
> On Saturday, June 22, 2013 4:55:02 PM UTC-4, lucas wrote:
>
>> it works fine, but only as long as "requires=IS_NOT_EMPTY()" is not also
>> included in the options.
>
>
> Yes, the IS_NOT_EMPTY validator doesn't really make sense with a
To be clear, in this example, I used update=False because the field is
boolean, but the "update" argument is not simply a boolean argument (i.e.,
it does not mean "update or don't update") -- it can take any value (or
callable) appropriate for the type of field.
Anthony
On Sunday, June 23, 201
>
> It's hard to keep up with web2py new features. What is exactly,
> update=False?
True, but that's not a new feature (been there as long as I can remember).
The "update" argument sets the value the field should take upon update if
no value is specified (much like "default" works for insert
It's hard to keep up with web2py new features. What is exactly,
update=False?
Thanks.
On Saturday, June 22, 2013 3:33:28 PM UTC-5, Anthony wrote:
>
> Does this work:
>
> Field('report_motion', 'boolean', default=False, update=False),
>
> Anthony
>
> On Saturday, June 22, 2013 4:16:22 PM U
On Saturday, June 22, 2013 4:55:02 PM UTC-4, lucas wrote:
> it works fine, but only as long as "requires=IS_NOT_EMPTY()" is not also
> included in the options.
Yes, the IS_NOT_EMPTY validator doesn't really make sense with a checkbox,
as there is no way to distinguish between "I'm deliberate
it works fine, but only as long as "requires=IS_NOT_EMPTY()" is not also
included in the options.
--
---
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
Does this work:
Field('report_motion', 'boolean', default=False, update=False),
Anthony
On Saturday, June 22, 2013 4:16:22 PM UTC-4, lucas wrote:
>
> hello one and all,
>
> under db.py, i have the field definition:
>
> Field('report_motion', 'boolean', requires=IS_NOT_EMPTY(),
> default
8 matches
Mail list logo