Fix issue
This commit is contained in:
@ -107,17 +107,17 @@ function MovementsTable(p: {
|
||||
|
||||
// Change account of movement
|
||||
const handleMoveClick = async (movement: Movement) => {
|
||||
const target = await chooseAccount(
|
||||
"Transfer movement",
|
||||
const targetAccount = await chooseAccount(
|
||||
"Transfer movementd",
|
||||
`Please select the target account that will receive the movement: ${movement.label} (${movement.amount} €)`,
|
||||
"Transfer movement",
|
||||
[accounts.get(movement.account_id)!]
|
||||
);
|
||||
|
||||
if (!target) return;
|
||||
if (!targetAccount) return;
|
||||
|
||||
try {
|
||||
movement.account_id = target.id;
|
||||
movement.account_id = targetAccount.id;
|
||||
|
||||
await MovementApi.Update(movement);
|
||||
|
||||
|
Reference in New Issue
Block a user