Closed MarcelRParcs closed 5 years ago
I made a change to subtract out the buffer time that is set in the collaboration and passed into the procedure.
trackInSeconds = (date(scheduledArrivalDate, "date", "epochSeconds") - date(now(), "date", "epochSeconds")) - (buffer/1000)
I made a couple other changes to check fsm_06 branch for the complete update.
Hello everyone,
It looks like the procedure collab.scheduleLocationTracking returns the time until the scheduled arrival date and not the time until the scheduled arrival date minus the hour that is passed to the procedure as a parameter.
Before:
trackInSeconds = date(scheduledArrivalDate, "date", "epochSeconds") - date(now(), "date", "epochSeconds")
After:
trackInSeconds = date(reminder, "date", "epochSeconds") - date(now(), "date", "epochSeconds")
This should return the scheduled time minus the given buffer time so it starts tracking before the scheduled arrival time.
Best regards Marcel