Initial values for new items in admin
Example: class NewsAdmin(InitialFieldsMixin, admin.ModelAdmin): initial = {'author_name': lambda self, request, obj, **kwargs: request.user}
- admin
Example: class NewsAdmin(InitialFieldsMixin, admin.ModelAdmin): initial = {'author_name': lambda self, request, obj, **kwargs: request.user}
please delete this, a snippet got posted twice accidentally