2
我使用django-email-as-username
應用程序使用電子郵件,而不是用戶名進行身份驗證,它的作用就像一個魅力。Django,重寫「is_authenticated()」,當我們有電子郵件,而不是用戶名
現在,視圖我想打電話給
if request.user.is_authenticated()
但這種方法只是驗證基於(用戶名+密碼),而不是(電子郵件+密碼)的用戶。我應該如何處理這個問題?
有什麼建議嗎?
哦..大..謝謝Secator – Soask