diff --git a/Dockerfile-webpack b/Dockerfile-webpack index 848070e..f6ef5fb 100644 --- a/Dockerfile-webpack +++ b/Dockerfile-webpack @@ -1,9 +1,9 @@ FROM node:7.3.0 RUN mkdir /code WORKDIR /code -ADD ./bikeshop_project /code +ADD ./bikeshop_project/package.json package.json RUN npm install RUN npm install -g bower -COPY ./bower.json . +ADD ./bikeshop_project/bower.json bower.json RUN bower install --allow-root EXPOSE 3000:3000 diff --git a/bikeshop_project/bikeshop/settings/base.py b/bikeshop_project/bikeshop/settings/base.py index 9534a50..563b27e 100644 --- a/bikeshop_project/bikeshop/settings/base.py +++ b/bikeshop_project/bikeshop/settings/base.py @@ -143,7 +143,7 @@ WEBPACK_LOADER = { 'DEFAULT': { 'CACHE': False, 'BUNDLE_DIR_NAME': 'bundles/', # must end with slash - 'STATS_FILE': os.path.join(BASE_DIR, 'webpack-stats.json'), + 'STATS_FILE': os.path.join(BASE_DIR, '../webpack-stats.json'), 'POLL_INTERVAL': 0.1, 'IGNORE': ['.+\.hot-update.js', '.+\.map'] } 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 %}