forked from python-discord/site
-
Notifications
You must be signed in to change notification settings - Fork 0
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Merge pull request python-discord#292 from python-discord/allauth-use…
…r-settings Allauth improvements & GH
- Loading branch information
Showing
22 changed files
with
1,052 additions
and
34 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Empty file.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,24 @@ | ||
from crispy_forms.helper import FormHelper | ||
from crispy_forms.layout import Layout | ||
from django.forms import CharField, Form | ||
from django_crispy_bulma.layout import IconField, Submit | ||
|
||
|
||
class AccountDeletionForm(Form): | ||
"""Account deletion form, to collect username for confirmation of removal.""" | ||
|
||
def __init__(self, *args, **kwargs): | ||
super().__init__(*args, **kwargs) | ||
self.helper = FormHelper() | ||
|
||
self.helper.form_method = "post" | ||
self.helper.add_input(Submit("submit", "I understand, delete my account")) | ||
|
||
self.helper.layout = Layout( | ||
IconField("username", icon_prepend="user") | ||
) | ||
|
||
username = CharField( | ||
label="Username", | ||
required=True | ||
) |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Oops, something went wrong.