handle none mileage 2

This commit is contained in:
Florian Bezannier
2021-09-10 19:40:31 +02:00
parent bed3f09011
commit e79956ed6f
3 changed files with 39 additions and 6 deletions
+4
View File
@@ -48,3 +48,7 @@ def record_charging():
Charging.record_charging(car, "InProgress", date2, 85, latitude, longitude, "FR", "slow", 20, 60)
Charging.record_charging(car, "InProgress", date3, 90, latitude, longitude, "FR", "slow", 20, 60)
Charging.record_charging(car, "Stopped", date4, 91, latitude, longitude, "FR", "slow", 20, 60)
def get_date(offset):
return date3 + timedelta(minutes=60 * offset)