Update import scripts through orders

This commit is contained in:
2025-02-17 00:53:07 -05:00
parent 702b956ff1
commit a8d3fd8033
4 changed files with 307 additions and 266 deletions

View File

@@ -385,8 +385,8 @@ async function importPurchaseOrders(prodConnection, localConnection, incremental
FROM inserted_pos
`);
recordsAdded = result.rows[0].inserted;
recordsUpdated = result.rows[0].updated;
recordsAdded = parseInt(result.rows[0].inserted, 10) || 0;
recordsUpdated = parseInt(result.rows[0].updated, 10) || 0;
// Update sync status
await localConnection.query(`