Re: [web2py] boolean_widget

2013-06-07 Thread Tim Richardson
Note that the validator to enforce selection (perhaps it is a "accept terms and conditions" field) is requires=IS_IN_SET(['on']) -- --- You received this message because you are subscribed to the Google Groups "web2py-users" group. To unsubscribe from this group and stop receiving emails f

Re: [web2py] boolean_widget

2013-06-06 Thread Jose
the boolean types have a default widget, which is a checkbox, when is > checked is True, and when is not is False, becouse it is empty... when > you Choose Si or No, you send a value so you get True becouse it is not > empty to be False. > > I thinks that's the problem. > Your comment is ri

Re: [web2py] boolean_widget

2013-06-06 Thread Marco Mansilla
El Thu, 6 Jun 2013 16:07:41 -0700 (PDT) Jose escribió: > Hello > > I have the following > > def boolean_widget(field, value): > return SELECT( > OPTION('Si', _value=True), > OPTION('No', _value=False), > _name=field.name, > _id='%s_%s' % (fiel

[web2py] boolean_widget

2013-06-06 Thread Jose
Hello I have the following def boolean_widget(field, value): return SELECT( OPTION('Si', _value=True), OPTION('No', _value=False), _name=field.name, _id='%s_%s' % (field._tablename, field.name), ) tb_algo = db.define_table('algo',