Good noon to all,
Is there any technic to set serial no in SQLGRID, i have try following code
for it but i am not satisfied,
db.define_table("material",
Field("serial_no", writable=False,),
Field("material_type", requires=IS_IN_SET(['Capax',
'Opax']), default = "Capax"),
Field("code"),
Field("description"),
Field("unit"),
Field("price"),
)
material_table_ids = [i.id for i in db(db.material).select()]
db.material.serial_no.represent = lambda id,row:
material_table_ids.index(row and row.id or material_table_ids[-1])+1
--
---
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 [email protected].
For more options, visit https://groups.google.com/groups/opt_out.