开发者

Customize the django User management

开发者 https://www.devze.com 2023-01-23 02:10 出处:网络
By default, I can see \"Delete the selected user\" action from django user admin page, now I want to add more actions? Who has any idea?

By default, I can see "Delete the selected user" action from django user admin page, now I want to add more actions? Who has any idea?

I've looked at "http://docs.djangoproject.com/en/dev/ref/contrib/admin/actions/#writing-actions", but I don't know how to add the ac开发者_如何学Gotion to it. Need your help, thanks.


If you want actions to be added to the User model, w/o changing the Django code you need: http://docs.djangoproject.com/en/dev/ref/contrib/admin/actions/#making-actions-available-site-wide Example usage case: custom .delete() methods.

0

精彩评论

暂无评论...
验证码 换一张
取 消

关注公众号