diff --git a/fleet_management/traccar_api.py b/fleet_management/traccar_api.py index 1b6b0f8..3814d33 100644 --- a/fleet_management/traccar_api.py +++ b/fleet_management/traccar_api.py @@ -28,7 +28,7 @@ def get_devices(doc=None): should also be able to be called frequently to update the status""" # get informations for authentication on traccar server - ts = frappe.get_last_doc('Traccar Settings') + ts = frappe.get_doc('Traccar Settings') # get all devices from traccar server try: @@ -68,7 +68,7 @@ def get_trips_for_device(device_id, start=None, end=None): Fetches all trips for a device, stores them in Trip Doctype, and links them to the vehicle assigned to the device. """ # get information for authentication on traccar server - ts = frappe.get_last_doc('Traccar Settings') + ts = frappe.get_doc('Traccar Settings') # Define default start and end datetime if not provided if not start: