mirror of
https://github.com/actualbudget/actual.git
synced 2026-03-09 03:32:54 -05:00
add a 'dryRun' option to transactions import API (#5758)
This commit is contained in:
@@ -96,6 +96,7 @@ export function addTransactions(
|
||||
|
||||
export interface ImportTransactionsOpts {
|
||||
defaultCleared?: boolean;
|
||||
dryRun?: boolean;
|
||||
}
|
||||
|
||||
export function importTransactions(
|
||||
@@ -103,11 +104,13 @@ export function importTransactions(
|
||||
transactions: ImportTransactionEntity[],
|
||||
opts: ImportTransactionsOpts = {
|
||||
defaultCleared: true,
|
||||
dryRun: false,
|
||||
},
|
||||
) {
|
||||
return send('api/transactions-import', {
|
||||
accountId,
|
||||
transactions,
|
||||
isPreview: opts.dryRun,
|
||||
opts,
|
||||
});
|
||||
}
|
||||
|
||||
6
upcoming-release-notes/5758.md
Normal file
6
upcoming-release-notes/5758.md
Normal file
@@ -0,0 +1,6 @@
|
||||
---
|
||||
category: Features
|
||||
authors: [amrawadk]
|
||||
---
|
||||
|
||||
Add 'dryRun' option to importTransactions API.
|
||||
Reference in New Issue
Block a user