mirror of
https://github.com/renee-png/acmcc.git
synced 2026-06-21 01:40:01 +00:00
Reconciliation: set cleared=false on transfer far leg (NOT NULL fix)
The far-account transfer leg omitted cleared, violating the column's not-null constraint. Default it to false; the near leg stays cleared=true. Co-Authored-By: Claude Opus 4.8 <noreply@anthropic.com>
This commit is contained in:
@@ -500,7 +500,7 @@ export default function AccountingReconcileDetailPage() {
|
|||||||
{
|
{
|
||||||
company_id: cid, account_id: transfer.other_account_id, date: transfer.date, type: otherType, amount: amt,
|
company_id: cid, account_id: transfer.other_account_id, date: transfer.date, type: otherType, amount: amt,
|
||||||
description: `Transfer ${transfer.direction === "out" ? "from" : "to"} ${thisName}${memo ? ` — ${memo}` : ""}`,
|
description: `Transfer ${transfer.direction === "out" ? "from" : "to"} ${thisName}${memo ? ` — ${memo}` : ""}`,
|
||||||
category: "Transfer", transfer_id: transferId,
|
category: "Transfer", transfer_id: transferId, cleared: false,
|
||||||
},
|
},
|
||||||
];
|
];
|
||||||
const { data, error } = await accounting.from("transactions").insert(rows).select("id,account_id");
|
const { data, error } = await accounting.from("transactions").insert(rows).select("id,account_id");
|
||||||
|
|||||||
Reference in New Issue
Block a user