feat: pause bank account feeds

This commit is contained in:
Ahmed Bouhuolia
2024-08-04 21:14:05 +02:00
parent fc0240c692
commit f9cf6d325a
8 changed files with 64 additions and 13 deletions

View File

@@ -37,7 +37,7 @@ export class PauseBankAccountFeeds {
}
return this.uow.withTransaction(tenantId, async (trx: Knex.Transaction) => {
await PlaidItem.query(trx).findById(oldAccount.plaidItem.id).patch({
pausedAt: null,
pausedAt: new Date(),
});
});
}

View File

@@ -36,7 +36,7 @@ export class ResumeBankAccountFeeds {
}
return this.uow.withTransaction(tenantId, async (trx: Knex.Transaction) => {
await PlaidItem.query(trx).findById(oldAccount.plaidItem.id).patch({
pausedAt: new Date(),
pausedAt: null,
});
});
}