Reputation: 11569
I am looking for a way to create an added_by
field to a Django admin model that is set to the currently logged in Django admin user and can only be changed by admins (so that users can only create items that claim to be added by themselves). I would welcome solutions that rely on external libraries. How can I achieve that functionality?
Upvotes: 0
Views: 37
Reputation: 3734
You could make a Creator
object that has an FK relationship to the model in question.
And only give admins access to change that object.
Upvotes: 1