Please open a ticket about this it gets tracked. On Thursday, 20 July 2017 20:43:40 UTC-5, Bernardo Leon wrote: > > Hello, I have a component which has an SQLFORM.grid and an oncreate and > ondelete callbacks on which I execute a response.js. When I delete a record > the response.js javascript function is executed but when I create a record > the response.js javascript function does not get executed (but the python's > oncreate function gets executed) > > This is my controller code: > > def oncreate_empleado(form): > # This method executes but the response_gestor_empleados javascript > function is not executed > response.js = 'response_gestor_empleados(%i);' % form.vars.id > > > def ondelete_empleado(table, id): > # Here the response_gestor_empleados javascript function gets executed > response.js = 'response_gestor_empleados(5);' > > > def index(): > > grid_empleados = SQLFORM.grid(db.empleado, > orderby=[db.empleado.apellidos, > db.empleado.nombres], > links=[dict(header='', > body=lambda registro: > crear_boton_seleccionar_empleado(registro))], > details=False, > csv=False, > formname='grid_empleados', > oncreate=oncreate_empleado, > ondelete=ondelete_empleado) > > return dict(grid_empleados=grid_empleados) > > Is this a bug or am I doing something wrong? Thank you! >
-- 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.