2026-04-01 17:59:26 +08:00

11 lines
316 B
Plaintext

orgid = params_kw.orgid
async with get_sor_context(request._run_ns, 'accounting') as sor:
recs = await sor.R('organization', {'id': orgid})
if len(recs) == 0:
return f"error: {orgid=} not found"
await openCustomerAccounts(sor, '0', orgid)
return f'{orgid} customer accounts opened'
return f'{db.e_except=}'