Currently multiple event are not fully supported. Whenever a tracking will be assigned on the same record for different events, an error: "Invalid current tracking ID .. " will be thrown.
Therefore, Device Tracker is required to differentiate between different events.
private function getCurrentTrackingId($pid, $field, $id) {
$result = $this->query(
"SELECT value FROM redcap_data WHERE project_id = ? AND field_name = ? AND record = ?",
[ $pid, $field, $id ]
);
return $result->fetch_object()->value;
}
Currently multiple event are not fully supported. Whenever a tracking will be assigned on the same record for different events, an error: "Invalid current tracking ID .. " will be thrown.
Therefore, Device Tracker is required to differentiate between different events.
https://github.com/Research-IT-Swiss-TPH/redcap-device-tracker/blob/b70003cf0894eace7683df676e5e00648a6d2f3f/deviceTracker.php#L634
Possible Fix;
pass event id to getCurrentTrackingID