Auto-queue filings sync on new ticker inserts

This commit is contained in:
2026-03-01 18:55:59 -05:00
parent 856af03b39
commit b55fbf0942
3 changed files with 73 additions and 16 deletions

View File

@@ -96,7 +96,10 @@ export async function upsertHoldingRecord(input: {
.where(eq(holding.id, existing.id))
.returning();
return toHolding(updated);
return {
holding: toHolding(updated),
created: false
};
}
const normalized = normalizeHoldingInput({
@@ -140,7 +143,10 @@ export async function upsertHoldingRecord(input: {
})
.returning();
return toHolding(inserted);
return {
holding: toHolding(inserted),
created: true
};
}
export async function updateHoldingByIdRecord(input: {