In the addon MagicOrm we have a pk_name method that allows overriding the pk's name (whic is default _id) in the Orm.jsonable() method to something else (the addon changes it to <ORM_NAME>_id.
It would be nice to have better support for this so you could easily change arbitrary names to something different in the jsonable method. You can definitely just override .jsonable() but often times that's a lot of boilerplate to change one value
In the addon MagicOrm we have a
pk_name
method that allows overriding the pk's name (whic is default_id
) in theOrm.jsonable()
method to something else (the addon changes it to<ORM_NAME>_id
.It would be nice to have better support for this so you could easily change arbitrary names to something different in the jsonable method. You can definitely just override
.jsonable()
but often times that's a lot of boilerplate to change one value