From efb780fc7622b96e1d13b0b9f474cacd34ec0ff0 Mon Sep 17 00:00:00 2001 From: Drew Larson Date: Sat, 21 Jan 2017 08:38:56 -0600 Subject: [PATCH] Show asterisk on required fields. --- bikeshop_project/registration/models.py | 6 +++--- bikeshop_project/registration/templates/member_form.html | 6 +++--- 2 files changed, 6 insertions(+), 6 deletions(-) diff --git a/bikeshop_project/registration/models.py b/bikeshop_project/registration/models.py index 2175b3f..73b6ca4 100644 --- a/bikeshop_project/registration/models.py +++ b/bikeshop_project/registration/models.py @@ -79,9 +79,9 @@ class Member(models.Model): null=True, blank=True, ) - email_consent = models.BooleanField(default=False) - first_name = models.CharField(max_length=255, null=False) - last_name = models.CharField(max_length=255, null=False) + email_consent = models.BooleanField(default=False, blank=False) + first_name = models.CharField(max_length=255, null=False, blank=False) + last_name = models.CharField(max_length=255, null=False, blank=False) preferred_name = models.CharField(max_length=255, null=True, blank=True) date_of_birth = models.DateField(null=True, blank=True) guardian_name = models.CharField(max_length=255, null=True, blank=True) diff --git a/bikeshop_project/registration/templates/member_form.html b/bikeshop_project/registration/templates/member_form.html index 319bcfb..8b88979 100644 --- a/bikeshop_project/registration/templates/member_form.html +++ b/bikeshop_project/registration/templates/member_form.html @@ -97,7 +97,7 @@
{{ form.first_name }} - + {% if form.first_name.errors %} {{ form.first_name.errors }} {% else %} @@ -106,7 +106,7 @@
{{ form.last_name }} - + {% if form.last_name.errors %} {{ form.last_name.errors }} {% else %} @@ -151,7 +151,7 @@
{{ form.post_code }} - + {% if form.post_code.errors %} {{ form.post_code.errors }} {% else %}