更改admin密码
from user.models import UserProfile
user=UserProfile.objects.filter(username=‘admin’)[0]
user.set_password(‘admin123’)
user.save()
原创于:http://www.debug5.com/detail/19/
程序猿的道德修养:
本博客源码Github地址:
https://github.com/whisnos/myblog
(仅供学习使用)请随手给个star,谢谢