fix: use ServerEnv().get_module_dbname('sage') instead of hardcoded 'sage'
This commit is contained in:
parent
a42d362995
commit
e6d5998c15
@ -483,7 +483,7 @@ async def delete_distribution_agreement_item(request, params_kw):
|
|||||||
async with db.sqlorContext(dbname) as sor:
|
async with db.sqlorContext(dbname) as sor:
|
||||||
await sor.D("distribution_agreement_items", {"id": item_id})
|
await sor.D("distribution_agreement_items", {"id": item_id})
|
||||||
# Also remove product_org_auth
|
# Also remove product_org_auth
|
||||||
async with DBPools().sqlorContext("sage") as sor_sage:
|
async with DBPools().sqlorContext(ServerEnv().get_module_dbname('sage')) as sor_sage:
|
||||||
await sor_sage.sqlExe(
|
await sor_sage.sqlExe(
|
||||||
"DELETE FROM product_org_auth WHERE auth_source_id = ${sid}$",
|
"DELETE FROM product_org_auth WHERE auth_source_id = ${sid}$",
|
||||||
{"sid": item_id}
|
{"sid": item_id}
|
||||||
|
|||||||
Loading…
x
Reference in New Issue
Block a user