syncActuals() recomputes the full date range from Workforce on every run but only ever upserted rows, so a shift that moved department or was edited/deleted since the last sync left its old wage_actuals_detail row in place — showing a "ghost" employee in the dept breakdown whose cost no longer matched the (correctly overwritten) department total. Now deletes existing wage_actuals/wage_actuals_detail rows for the synced date range before reinserting, so removed/reassigned shifts don't linger. |
||
|---|---|---|
| .. | ||
| src | ||
| Dockerfile | ||
| package.json | ||