How can I set a default value on a ForeignKey field in a django Model or AdminModel?
Something like this (but of course this doesn't work)...
created_by = models.ForeignKey(User, default=request.user)
I know I can 'trick' it in the view, but in terms of the AdminModel it doesn't seem possible.
See Question&Answers more detail:
os 与恶龙缠斗过久,自身亦成为恶龙;凝视深渊过久,深渊将回以凝视…