You should not change web2py_ajax. You should translate the string "%Y- %m-%d" using the internationalization interface.
On Feb 1, 4:33 am, Jan Palach <[email protected]> wrote: > Hi everybody, > > I have a little problem. I have a table containing a date field in the format > "% m-% d% Y"as shown below: > > db.define_table('parcelas', > Field('numero', 'integer'), > Field('valor', 'double'), > Field('data_vencimento', 'date'), > Field('pago', 'boolean'), > Field('pagamento_id', db.pagamento) > ) > > db.parcelas.data_vencimento.requires=IS_DATE(format=T("%d-%m-%Y"), > error_message=T("use dd-mm-aaaa")) > > In my form the corresponding inputs are using the class "date" see > below for example: > > <input class="date" type="text" id="data_parcela" name="data_parcela"/> > > After saving the field is something strange in the management section > of thedatabase object is not recovered, returning the following error: > > File "gluon / dal.py", line 1008, in select > File "gluon / dal.py", line 1207, in parse > ValueError: day is out of range for month > > I changed the web2py_ajax.html to use the format "% d-% m-% Y", but it seems > not enough. > > Should I convert the string to a form sent by type date before saving? Can > anyone help me? > > Sorry my english... :)

