edit
This commit is contained in:
@ -62,7 +62,7 @@ export class BusinessInterceptor implements HttpInterceptor {
|
||||
const header: any = {
|
||||
appId: this.envSrv.env.appId,
|
||||
tenantId: this.envSrv.env.tenantId,
|
||||
enterpriseId: '0',
|
||||
enterpriseId: this.envSrv.env.enterpriseId,
|
||||
...position
|
||||
};
|
||||
|
||||
|
||||
@ -1,8 +1,10 @@
|
||||
import { HttpClient } from '@angular/common/http';
|
||||
import { Inject, Injectable } from '@angular/core';
|
||||
import { cacheConf } from '@conf/cache.conf';
|
||||
import { sysConf } from '@conf/sys.conf';
|
||||
import { ACLService } from '@delon/acl';
|
||||
import { MenuService, SettingsService, TitleService, _HttpClient } from '@delon/theme';
|
||||
import { AmapService, EAUserService } from '@shared';
|
||||
import { AmapService, EACacheService, EAUserService } from '@shared';
|
||||
import { NzSafeAny } from 'ng-zorro-antd/core/types';
|
||||
import { NzIconService } from 'ng-zorro-antd/icon';
|
||||
import { Observable, zip } from 'rxjs';
|
||||
@ -27,6 +29,7 @@ export class StartupService {
|
||||
private httpClient: _HttpClient,
|
||||
private userSrv: EAUserService,
|
||||
private amapService: AmapService,
|
||||
public cacheSrv: EACacheService,
|
||||
private coreSrv: CoreService
|
||||
) {
|
||||
iconSrv.addIcon(...ICONS_AUTO, ...ICONS);
|
||||
@ -83,6 +86,11 @@ export class StartupService {
|
||||
this.settingService.setApp(appData);
|
||||
// 用户信息:包括姓名、头像、邮箱地址
|
||||
this.settingService.setUser(userData);
|
||||
this.cacheSrv.set(cacheConf.env, {
|
||||
appId: sysConf.appId,
|
||||
tenantId: userData?.tenantId || sysConf.tenantId,
|
||||
enterpriseId: userData?.enterpriseId || sysConf.enterpriseId
|
||||
});
|
||||
// ACL:设置权限为全量
|
||||
this.aclService.setFull(true);
|
||||
// 初始化菜单
|
||||
|
||||
Reference in New Issue
Block a user