feat: 多租户联动 — CMA切换企业注入tenant_id + a2a_dispatch分发
This commit is contained in:
@@ -71,6 +71,10 @@ function onEntityChange(id: number) {
|
||||
currentEntityName.value = e?.short_name || e?.name || ''
|
||||
localStorage.setItem('cma_entity_id', String(id))
|
||||
localStorage.setItem('cma_entity_name', currentEntityName.value)
|
||||
// 多租户联动:通知后端记录当前tenant(供项目Bot A2A分发)
|
||||
try {
|
||||
api.post('/tenant/switch', { entity_id: id, source: 'cma-frontend' })
|
||||
} catch (_) {}
|
||||
location.reload()
|
||||
}
|
||||
onMounted(async () => {
|
||||
|
||||
Reference in New Issue
Block a user