Compare commits
5 Commits
| Author | SHA1 | Date | |
|---|---|---|---|
| adf51c85f2 | |||
| 48d7c108f1 | |||
| 7129e676e2 | |||
| aaa94f08fa | |||
| 92fb25c1c1 |
@@ -187,6 +187,8 @@ def create_vehicle():
|
|||||||
|
|
||||||
if form.consumables.data:
|
if form.consumables.data:
|
||||||
form.consumables.default = form.consumables.data
|
form.consumables.default = form.consumables.data
|
||||||
|
else:
|
||||||
|
form.consumables.default = []
|
||||||
|
|
||||||
if form.validate_on_submit():
|
if form.validate_on_submit():
|
||||||
if len(form.consumables.data) == 0:
|
if len(form.consumables.data) == 0:
|
||||||
|
|||||||
@@ -82,7 +82,7 @@ class CreatePitstopForm(Form):
|
|||||||
if self.date.data:
|
if self.date.data:
|
||||||
self.date.default = self.date.data
|
self.date.default = self.date.data
|
||||||
else:
|
else:
|
||||||
self.date.default = self.last_pitstop.date
|
self.date.default = date.today()
|
||||||
if self.odometer.data:
|
if self.odometer.data:
|
||||||
self.odometer.default = self.odometer.data
|
self.odometer.default = self.odometer.data
|
||||||
else:
|
else:
|
||||||
|
|||||||
Reference in New Issue
Block a user