mirror of
https://github.com/nikdoof/test-auth.git
synced 2025-12-14 06:42:16 +00:00
Password Reset now allows for providing passwords when GENERATE_SERVICE_PASSWORD is false
This commit is contained in:
@@ -51,6 +51,13 @@ def UserServiceAccountForm(user):
|
||||
|
||||
return ServiceAccountForm
|
||||
|
||||
class ServiceAccountResetForm(forms.Form):
|
||||
def __init__(self, *args, **kwargs):
|
||||
super(ServiceAccountResetForm, self).__init__(*args, **kwargs)
|
||||
if not settings.GENERATE_SERVICE_PASSWORD:
|
||||
self.password = forms.CharField(widget=forms.PasswordInput, label="Password" )
|
||||
self.fields['password'] = self.password
|
||||
|
||||
class RedditAccountForm(forms.Form):
|
||||
""" Reddit Account Form """
|
||||
|
||||
|
||||
Reference in New Issue
Block a user