From 92fb25c1c1bf456c071e215c0e0c9924c109f36e Mon Sep 17 00:00:00 2001 From: Joachim Lusiardi Date: Mon, 25 Jul 2016 18:54:27 +0200 Subject: [PATCH 1/2] fix issue 8 --- app/forms.py | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/app/forms.py b/app/forms.py index f884643..5a51f8c 100644 --- a/app/forms.py +++ b/app/forms.py @@ -82,7 +82,7 @@ class CreatePitstopForm(Form): if self.date.data: self.date.default = self.date.data else: - self.date.default = self.last_pitstop.date + self.date.default = date.today() if self.odometer.data: self.odometer.default = self.odometer.data else: From 7129e676e283812864f757851f0316cc8cf24b3b Mon Sep 17 00:00:00 2001 From: Joachim Lusiardi Date: Fri, 29 Jul 2016 21:10:58 +0200 Subject: [PATCH 2/2] Fixed issue 9 --- app/__init__.py | 2 ++ 1 file changed, 2 insertions(+) diff --git a/app/__init__.py b/app/__init__.py index 8b2e2ce..fd530ca 100644 --- a/app/__init__.py +++ b/app/__init__.py @@ -187,6 +187,8 @@ def create_vehicle(): if form.consumables.data: form.consumables.default = form.consumables.data + else: + form.consumables.default = [] if form.validate_on_submit(): if len(form.consumables.data) == 0: