This commit is contained in:
qsh
2026-02-05 11:59:53 +08:00
parent e63e95525d
commit 5c5d3d8598
5 changed files with 48 additions and 29 deletions

View File

@@ -15,8 +15,10 @@ export const useTenantStore = defineStore('tenant', () => {
};
const getTenant = () => {
// 按照顺序获取tenantId1. storage 2. config
const tenantId = storage.get(constant.tenantId) || config.appInfo.tenantId;
return new Promise(resolve => {
getTenantInfo({ id: config.appInfo.tenantId }).then(res => {
getTenantInfo({ id: tenantId }).then(res => {
if (!isEmpty(res.data)) {
SET_TENANT_INFO(res.data);
}