diff options
author | eug-vs <eug-vs@keemail.me> | 2021-03-20 20:28:44 +0300 |
---|---|---|
committer | eug-vs <eug-vs@keemail.me> | 2021-03-20 20:28:44 +0300 |
commit | 42cc6be0fc083ff5f7897a9e214918d750cb59ff (patch) | |
tree | 8127b59842c01636593dbe87fa69c62d7efad47c | |
parent | afa1d1371c10878f395f95279beac5bb0aec6963 (diff) | |
download | commercel-api-42cc6be0fc083ff5f7897a9e214918d750cb59ff.tar.gz |
feat: use UTC date parsing
-rw-r--r-- | src/services/uploads.service.ts | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/src/services/uploads.service.ts b/src/services/uploads.service.ts index 3479d0f..2a887e4 100644 --- a/src/services/uploads.service.ts +++ b/src/services/uploads.service.ts @@ -40,7 +40,7 @@ const parseTransfersBill = async (context: HookContext): Promise<HookContext> => } else if (cols.length === 7) { const [dateString, doc, op, code, account, debet, credit] = cols; try { - const date = moment(dateString, 'DD.MM.YYYY').toISOString(); + const date = moment.utc(dateString, 'DD.MM.YYYY').toISOString(); acc.push({ date, doc, op, code, account, debet, credit }); } catch (e) { console.log(`Skipping row because not a date: ${dateString}`); |