Skip to content

Commit

Permalink
Full name
Browse files Browse the repository at this point in the history
  • Loading branch information
asennoussi committed Oct 17, 2023
1 parent a8b41af commit b2845f7
Show file tree
Hide file tree
Showing 2 changed files with 7 additions and 1 deletion.
3 changes: 2 additions & 1 deletion accounts/forms.py
Original file line number Diff line number Diff line change
Expand Up @@ -19,8 +19,9 @@
class UserEditForm(forms.ModelForm):
class Meta:
model = CustomUser
fields = ['paypal_email', 'email']
fields = ['full_name', 'paypal_email', 'email']
widgets = {
'full_name': forms.TextInput(attrs={'class': 'form-control'}),
'paypal_email': forms.TextInput(attrs={'class': 'form-control'}),
'email': forms.EmailInput(attrs={'class': 'form-control'}),
}
Expand Down
5 changes: 5 additions & 0 deletions accounts/templates/accounts/customuser_update_form.html
Original file line number Diff line number Diff line change
Expand Up @@ -16,6 +16,11 @@ <h1 class="h4">Account settings</h1>

<form id="updateCustomUser" action="" method="post" data-toggle="validator" data-focus="false">
{% csrf_token %}
<div class="form-check mb-3">
<label class="form-check-label form-label" for="{{form.full_name.id_for_label}}">Full name</label>
{{ form.full_name }}
</div>

<div class="form-check mb-3">
<label class="form-check-label form-label" for="{{form.paypal_email.id_for_label}}">Paypal Email</label>
{{ form.paypal_email }}
Expand Down

0 comments on commit b2845f7

Please sign in to comment.