mirror of
https://github.com/actualbudget/actual.git
synced 2026-03-11 20:44:32 -05:00
Fix scheduled transfers not linking when payee account is imported first (#6025)
This commit is contained in:
committed by
GitHub
parent
e786bdc398
commit
1a845583ef
@@ -68,14 +68,21 @@ export async function addTransfer(transaction, transferredAccount) {
|
||||
schedule: transaction.schedule,
|
||||
cleared: false,
|
||||
};
|
||||
const { notes, cleared } = await runRules(transferTransaction);
|
||||
const { notes, cleared, schedule } = await runRules(transferTransaction);
|
||||
const matchedSchedule = schedule ?? transaction.schedule;
|
||||
|
||||
const id = await db.insertTransaction({
|
||||
...transferTransaction,
|
||||
notes,
|
||||
cleared,
|
||||
schedule: matchedSchedule,
|
||||
});
|
||||
|
||||
await db.updateTransaction({ id: transaction.id, transfer_id: id });
|
||||
await db.updateTransaction({
|
||||
id: transaction.id,
|
||||
transfer_id: id,
|
||||
...(matchedSchedule ? { schedule: matchedSchedule } : {}),
|
||||
});
|
||||
const categoryCleared = await clearCategory(transaction, transferredAccount);
|
||||
|
||||
return {
|
||||
|
||||
7
upcoming-release-notes/6025.md
Normal file
7
upcoming-release-notes/6025.md
Normal file
@@ -0,0 +1,7 @@
|
||||
---
|
||||
category: Bugfix
|
||||
authors: [MatissJanis]
|
||||
---
|
||||
|
||||
Fix scheduled transfers not linking when payee account is imported first
|
||||
|
||||
Reference in New Issue
Block a user