Use pk attribute on model objects instead of id