更新平台治理
This commit is contained in:
@@ -178,8 +178,8 @@ def filter_accessible_resource_ids(
|
||||
).fetchall()
|
||||
|
||||
accessible = {r["resource_id"] for r in rows}
|
||||
if resource_type in owner_tables:
|
||||
table, column = owner_tables[resource_type]
|
||||
if resource_type in OWNER_TABLES:
|
||||
table, column = OWNER_TABLES[resource_type]
|
||||
with store.connect() as conn:
|
||||
owned = conn.execute(f"SELECT id FROM {table} WHERE {column}=?", (user_id,)).fetchall()
|
||||
accessible.update(row["id"] for row in owned)
|
||||
|
||||
Reference in New Issue
Block a user