I’m using QField to record GPS tracks and measure how long each track took (effort time). I have start_dt and end_dt fields.
I was able to automate most of the attributes, but I’m having a problem with end_dt:
the time that gets stored is often the time of sync to QFieldCloud, not the time when tracking actually stopped.
This seems to happen because of “Apply default value on update”:
-
I need to enable “Apply default value on update” so that end_dt captures the exact time when tracking is stopped.
-
But when the data is later synced or edited, the default is applied again and end_dt is updated to the sync time, which breaks my tracking duration.
What I would like to achieve
start_dt
-
Automatically set when tracking starts.
-
Never changed afterwards.
end_dt
-
Automatically set exactly when the user taps “Stop tracking”.
-
Never changed afterwards (not by edits, not by sync).
Duration
-
Calculated reliably from end_dt - start_dt.
-
No need for the user to tap or edit anything.
We work with Forest Guards who are not very familiar with technology, so we need this process to be as automatic and foolproof as possible, with no manual steps that can introduce human error.
Question:
Is there a way in QField to:
-
Tie end_dt to the “Stop tracking” event, and
-
Freeze that value so it is never changed again on sync or later edits?
If not, would it be possible to add such an option/feature?