I have an app that tracks deliveries to my business. When we get new deliveries the following 3 steps need to be completed:
- Mark off the delivery (count the items in the delivery)
- Put away the delivery (delivery items to be put in the correct storage location)
- Receive into inventory system
I have a YN flag and form associated with each step, I also have a DateTime field (DTS - date time stamp) for each step which I use NOW() when they complete the form. This all works fine
I have a Bot with an event that is triggered when all 3 steps flags are set to Y (completed) and then a process (which is an action) to set a column ‘Complete DTS’ to NOW(). What is happening is that when this action is performed it is overwritting the DateTime of the 3 previous steps to to NOW() (same DateTime as the ‘Complete DTS’ column)
Eg. As we go through the delivery steps
Mark off DTS - 01/01/2021 12:00:00
Put Away DTS - 01/01/2021 12:05:00
I complete the final step and watch the Google Sheets and Received Inventory DTS is updated correctly, let say for this example
Received Inventory - 01/012021 12:10:00
As I watch the Google Sheets file I can see the data being written to the 3 steps DTS field and 2-3 seconds after Received Inventory DTS is updated the Complete DTS is updated to 01/01/2021 12:10:02.
2 seconds later all the above fields are set to the same as Completed DTS.
Mark off DTS - 01/01/2021 12:10:02
Put Away DTS - 01/01/2021 12:10:02
Received Inventory - 01/01/2021 12:10:02
Complete DTS - 01/01/2021 12:10:02
Cannot understand why this is happening, Complete DTS should update but the other 3 DTS fields should not change.
I have been trying to debug this for a few days now, can anyone shed some light on this ?