@ebuilding/runtime 2.7.4 → 2.8.0
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/auth/auth-routing.module.d.ts +7 -0
- package/auth/auth.tokens.d.ts +7 -0
- package/auth/authmodule.d.ts +10 -0
- package/auth/index.d.ts +2 -0
- package/auth/login/login.component.d.ts +48 -0
- package/auth/login-cust/login.component.d.ts +47 -0
- package/core/app-feature-config.service.d.ts +26 -0
- package/core/app-feature.guard.d.ts +3 -0
- package/core/i18n/i18n.service.d.ts +25 -0
- package/core/index.d.ts +7 -0
- package/core/net/default.interceptor.d.ts +2 -0
- package/core/net/helper.d.ts +11 -0
- package/core/net/index.d.ts +2 -0
- package/core/net/refresh-token.d.ts +11 -0
- package/core/runtime-core.tokens.d.ts +18 -0
- package/core/start-default.guard.d.ts +2 -0
- package/core/startup/startup.service.d.ts +24 -0
- package/exception/index.d.ts +2 -0
- package/exception/index.module.d.ts +8 -0
- package/exception/main/index.d.ts +11 -0
- package/fesm2022/auth.mjs +500 -0
- package/fesm2022/auth.mjs.map +1 -0
- package/fesm2022/core.mjs +615 -0
- package/fesm2022/core.mjs.map +1 -0
- package/fesm2022/exception.mjs +52 -0
- package/fesm2022/exception.mjs.map +1 -0
- package/fesm2022/layout.mjs +2393 -0
- package/fesm2022/layout.mjs.map +1 -0
- package/layout/admin/index.component.d.ts +18 -0
- package/layout/auth/index.component.d.ts +19 -0
- package/layout/base.service.d.ts +48 -0
- package/layout/basic/basic.component.d.ts +13 -0
- package/layout/basic/widgets/clear-storage.component.d.ts +8 -0
- package/layout/basic/widgets/fullscreen.component.d.ts +8 -0
- package/layout/basic/widgets/i18n.component.d.ts +18 -0
- package/layout/basic/widgets/icon.component.d.ts +8 -0
- package/layout/basic/widgets/notify.component.d.ts +16 -0
- package/layout/basic/widgets/rtl.component.d.ts +8 -0
- package/layout/basic/widgets/search.component.d.ts +23 -0
- package/layout/basic/widgets/task.component.d.ts +8 -0
- package/layout/basic/widgets/user.component.d.ts +11 -0
- package/layout/blank/blank.component.d.ts +5 -0
- package/layout/components/nav-menu/index.d.ts +16 -0
- package/layout/components/nav-user/index.d.ts +54 -0
- package/layout/components/user/user.component.d.ts +57 -0
- package/layout/home/index.component.d.ts +20 -0
- package/layout/index.d.ts +7 -0
- package/layout/manage/index.component.d.ts +27 -0
- package/layout/manage/view.component.d.ts +21 -0
- package/package.json +42 -25
|
@@ -0,0 +1,7 @@
|
|
|
1
|
+
import * as i0 from "@angular/core";
|
|
2
|
+
import * as i1 from "@angular/router";
|
|
3
|
+
export declare class AuthRoutingModule {
|
|
4
|
+
static ɵfac: i0.ɵɵFactoryDeclaration<AuthRoutingModule, never>;
|
|
5
|
+
static ɵmod: i0.ɵɵNgModuleDeclaration<AuthRoutingModule, never, [typeof i1.RouterModule], [typeof i1.RouterModule]>;
|
|
6
|
+
static ɵinj: i0.ɵɵInjectorDeclaration<AuthRoutingModule>;
|
|
7
|
+
}
|
|
@@ -0,0 +1,10 @@
|
|
|
1
|
+
import * as i0 from "@angular/core";
|
|
2
|
+
import * as i1 from "@ebuilding/runtime/shared-imports";
|
|
3
|
+
import * as i2 from "./auth-routing.module";
|
|
4
|
+
import * as i3 from "./login/login.component";
|
|
5
|
+
import * as i4 from "./login-cust/login.component";
|
|
6
|
+
export declare class AuthModule {
|
|
7
|
+
static ɵfac: i0.ɵɵFactoryDeclaration<AuthModule, never>;
|
|
8
|
+
static ɵmod: i0.ɵɵNgModuleDeclaration<AuthModule, never, [typeof i1.RuntimeSharedImportsModule, typeof i2.AuthRoutingModule, typeof i3.UserLoginComponent, typeof i4.UserLoginCustComponent], never>;
|
|
9
|
+
static ɵinj: i0.ɵɵInjectorDeclaration<AuthModule>;
|
|
10
|
+
}
|
package/auth/index.d.ts
ADDED
|
@@ -0,0 +1,48 @@
|
|
|
1
|
+
import { OnDestroy } from '@angular/core';
|
|
2
|
+
import { FormBuilder, FormGroup } from '@angular/forms';
|
|
3
|
+
import { Router, ActivatedRoute } from '@angular/router';
|
|
4
|
+
import { NzMessageService } from 'ng-zorro-antd/message';
|
|
5
|
+
import { NzModalService } from 'ng-zorro-antd/modal';
|
|
6
|
+
import { ReuseTabService } from '@delon/abc/reuse-tab';
|
|
7
|
+
import { ACLService } from '@delon/acl';
|
|
8
|
+
import { ITokenService } from '@delon/auth';
|
|
9
|
+
import { SettingsService, _HttpClient } from '@delon/theme';
|
|
10
|
+
import { GramBaseDialogService } from '@ebuilding/base/shared.srv/base-dialog.service';
|
|
11
|
+
import { RuntimeAuthOptions } from '../auth.tokens';
|
|
12
|
+
import * as i0 from "@angular/core";
|
|
13
|
+
export declare class UserLoginComponent implements OnDestroy {
|
|
14
|
+
private router;
|
|
15
|
+
private activatedRoute;
|
|
16
|
+
private reuseTabService;
|
|
17
|
+
private tokenService;
|
|
18
|
+
http: _HttpClient;
|
|
19
|
+
msg: NzMessageService;
|
|
20
|
+
settingService: SettingsService;
|
|
21
|
+
private aclService;
|
|
22
|
+
private dialogSrv;
|
|
23
|
+
private authOptions;
|
|
24
|
+
title: any;
|
|
25
|
+
sourceType: any;
|
|
26
|
+
sourceUserId: any;
|
|
27
|
+
sourceCorpId: any;
|
|
28
|
+
constructor(fb: FormBuilder, modalSrv: NzModalService, router: Router, activatedRoute: ActivatedRoute, reuseTabService: ReuseTabService, tokenService: ITokenService, http: _HttpClient, msg: NzMessageService, settingService: SettingsService, aclService: ACLService, dialogSrv: GramBaseDialogService, authOptions: RuntimeAuthOptions);
|
|
29
|
+
get customerId(): import("@angular/forms").AbstractControl<any, any>;
|
|
30
|
+
get userName(): import("@angular/forms").AbstractControl<any, any>;
|
|
31
|
+
get password(): import("@angular/forms").AbstractControl<any, any>;
|
|
32
|
+
get mobile(): import("@angular/forms").AbstractControl<any, any>;
|
|
33
|
+
get captcha(): import("@angular/forms").AbstractControl<any, any>;
|
|
34
|
+
form: FormGroup;
|
|
35
|
+
error: string;
|
|
36
|
+
type: number;
|
|
37
|
+
loading: boolean;
|
|
38
|
+
forceChangePwd: boolean;
|
|
39
|
+
count: number;
|
|
40
|
+
interval$: any;
|
|
41
|
+
switch(ret: any): void;
|
|
42
|
+
getCaptcha(): void;
|
|
43
|
+
submit(): void;
|
|
44
|
+
getUserMenus(): void;
|
|
45
|
+
ngOnDestroy(): void;
|
|
46
|
+
static ɵfac: i0.ɵɵFactoryDeclaration<UserLoginComponent, [null, null, null, null, { optional: true; }, null, null, null, null, null, null, null]>;
|
|
47
|
+
static ɵcmp: i0.ɵɵComponentDeclaration<UserLoginComponent, "passport-login", never, {}, {}, never, never, true, never>;
|
|
48
|
+
}
|
|
@@ -0,0 +1,47 @@
|
|
|
1
|
+
import { OnDestroy } from '@angular/core';
|
|
2
|
+
import { FormBuilder, FormGroup } from '@angular/forms';
|
|
3
|
+
import { Router, ActivatedRoute } from '@angular/router';
|
|
4
|
+
import { NzMessageService } from 'ng-zorro-antd/message';
|
|
5
|
+
import { NzModalService } from 'ng-zorro-antd/modal';
|
|
6
|
+
import { ReuseTabService } from '@delon/abc/reuse-tab';
|
|
7
|
+
import { ACLService } from '@delon/acl';
|
|
8
|
+
import { ITokenService } from '@delon/auth';
|
|
9
|
+
import { SettingsService, _HttpClient } from '@delon/theme';
|
|
10
|
+
import { GramBaseDialogService } from '@ebuilding/base/shared.srv/base-dialog.service';
|
|
11
|
+
import { RuntimeAuthOptions } from '../auth.tokens';
|
|
12
|
+
import * as i0 from "@angular/core";
|
|
13
|
+
export declare class UserLoginCustComponent implements OnDestroy {
|
|
14
|
+
private router;
|
|
15
|
+
private activatedRoute;
|
|
16
|
+
private reuseTabService;
|
|
17
|
+
private tokenService;
|
|
18
|
+
http: _HttpClient;
|
|
19
|
+
msg: NzMessageService;
|
|
20
|
+
settingService: SettingsService;
|
|
21
|
+
private aclService;
|
|
22
|
+
private dialogSrv;
|
|
23
|
+
private authOptions;
|
|
24
|
+
title: any;
|
|
25
|
+
sourceType: any;
|
|
26
|
+
sourceUserId: any;
|
|
27
|
+
customerId: any;
|
|
28
|
+
constructor(fb: FormBuilder, modalSrv: NzModalService, router: Router, activatedRoute: ActivatedRoute, reuseTabService: ReuseTabService, tokenService: ITokenService, http: _HttpClient, msg: NzMessageService, settingService: SettingsService, aclService: ACLService, dialogSrv: GramBaseDialogService, authOptions: RuntimeAuthOptions);
|
|
29
|
+
get userName(): import("@angular/forms").AbstractControl<any, any>;
|
|
30
|
+
get password(): import("@angular/forms").AbstractControl<any, any>;
|
|
31
|
+
get mobile(): import("@angular/forms").AbstractControl<any, any>;
|
|
32
|
+
get captcha(): import("@angular/forms").AbstractControl<any, any>;
|
|
33
|
+
form: FormGroup;
|
|
34
|
+
error: string;
|
|
35
|
+
type: number;
|
|
36
|
+
loading: boolean;
|
|
37
|
+
forceChangePwd: boolean;
|
|
38
|
+
count: number;
|
|
39
|
+
interval$: any;
|
|
40
|
+
switch(ret: any): void;
|
|
41
|
+
getCaptcha(): void;
|
|
42
|
+
submit(): void;
|
|
43
|
+
getUserMenus(): void;
|
|
44
|
+
ngOnDestroy(): void;
|
|
45
|
+
static ɵfac: i0.ɵɵFactoryDeclaration<UserLoginCustComponent, [null, null, null, null, { optional: true; }, null, null, null, null, null, null, null]>;
|
|
46
|
+
static ɵcmp: i0.ɵɵComponentDeclaration<UserLoginCustComponent, "passport-login-cust", never, {}, {}, never, never, true, never>;
|
|
47
|
+
}
|
|
@@ -0,0 +1,26 @@
|
|
|
1
|
+
import { Router } from '@angular/router';
|
|
2
|
+
import { SettingsService, _HttpClient } from '@delon/theme';
|
|
3
|
+
import { Observable } from 'rxjs';
|
|
4
|
+
import * as i0 from "@angular/core";
|
|
5
|
+
export declare const AppFeatureConfigKey = "APP_FEATURE_CONFIG";
|
|
6
|
+
export interface AppFeatureConfig {
|
|
7
|
+
enableWorkflow: boolean;
|
|
8
|
+
enableMessageCenter: boolean;
|
|
9
|
+
}
|
|
10
|
+
export declare class AppFeatureConfigService {
|
|
11
|
+
private http;
|
|
12
|
+
private settings;
|
|
13
|
+
private router;
|
|
14
|
+
private loading$;
|
|
15
|
+
constructor(http: _HttpClient, settings: SettingsService, router: Router);
|
|
16
|
+
load(force?: boolean): Observable<AppFeatureConfig>;
|
|
17
|
+
save(config: AppFeatureConfig): Observable<AppFeatureConfig>;
|
|
18
|
+
current(): AppFeatureConfig | null;
|
|
19
|
+
redirectHome(): void;
|
|
20
|
+
private set;
|
|
21
|
+
private fromResponse;
|
|
22
|
+
private defaults;
|
|
23
|
+
private toBool;
|
|
24
|
+
static ɵfac: i0.ɵɵFactoryDeclaration<AppFeatureConfigService, never>;
|
|
25
|
+
static ɵprov: i0.ɵɵInjectableDeclaration<AppFeatureConfigService>;
|
|
26
|
+
}
|
|
@@ -0,0 +1,25 @@
|
|
|
1
|
+
import { AlainI18nBaseService } from '@delon/theme';
|
|
2
|
+
import { AlainConfigService } from '@delon/util/config';
|
|
3
|
+
import { NzSafeAny } from 'ng-zorro-antd/core/types';
|
|
4
|
+
import { Observable } from 'rxjs';
|
|
5
|
+
import * as i0 from "@angular/core";
|
|
6
|
+
export declare class I18NService extends AlainI18nBaseService {
|
|
7
|
+
private readonly http;
|
|
8
|
+
private readonly settings;
|
|
9
|
+
private readonly nzI18nService;
|
|
10
|
+
private readonly delonLocaleService;
|
|
11
|
+
private readonly platform;
|
|
12
|
+
protected _defaultLang: string;
|
|
13
|
+
private _langs;
|
|
14
|
+
constructor(cogSrv: AlainConfigService);
|
|
15
|
+
private getDefaultLang;
|
|
16
|
+
loadLangData(lang: string): Observable<NzSafeAny>;
|
|
17
|
+
use(lang: string, data: Record<string, unknown>): void;
|
|
18
|
+
getLangs(): Array<{
|
|
19
|
+
code: string;
|
|
20
|
+
text: string;
|
|
21
|
+
abbr: string;
|
|
22
|
+
}>;
|
|
23
|
+
static ɵfac: i0.ɵɵFactoryDeclaration<I18NService, never>;
|
|
24
|
+
static ɵprov: i0.ɵɵInjectableDeclaration<I18NService>;
|
|
25
|
+
}
|
package/core/index.d.ts
ADDED
|
@@ -0,0 +1,7 @@
|
|
|
1
|
+
export * from './i18n/i18n.service';
|
|
2
|
+
export * from './net/index';
|
|
3
|
+
export * from './startup/startup.service';
|
|
4
|
+
export * from './start-default.guard';
|
|
5
|
+
export * from './app-feature-config.service';
|
|
6
|
+
export * from './app-feature.guard';
|
|
7
|
+
export * from './runtime-core.tokens';
|
|
@@ -0,0 +1,11 @@
|
|
|
1
|
+
import { HttpResponseBase, HttpRequest } from '@angular/common/http';
|
|
2
|
+
import { Injector } from '@angular/core';
|
|
3
|
+
export interface ReThrowHttpError {
|
|
4
|
+
body: any;
|
|
5
|
+
_throw: true;
|
|
6
|
+
}
|
|
7
|
+
export declare const CODEMESSAGE: Record<number, string>;
|
|
8
|
+
export declare function goTo(injector: Injector, url: string): void;
|
|
9
|
+
export declare function toLogin(injector: Injector): void;
|
|
10
|
+
export declare function getAdditionalHeaders(req: HttpRequest<any>, injector: Injector): Record<string, string>;
|
|
11
|
+
export declare function checkStatus(injector: Injector, ev: HttpResponseBase): void;
|
|
@@ -0,0 +1,11 @@
|
|
|
1
|
+
import { HttpHandlerFn, HttpRequest, HttpResponseBase } from '@angular/common/http';
|
|
2
|
+
import { EnvironmentProviders, Injector } from '@angular/core';
|
|
3
|
+
import { Observable } from 'rxjs';
|
|
4
|
+
/**
|
|
5
|
+
* 刷新Token方式一:使用 401 重新刷新 Token
|
|
6
|
+
*/
|
|
7
|
+
export declare function tryRefreshToken(injector: Injector, ev: HttpResponseBase, req: HttpRequest<any>, next: HttpHandlerFn): Observable<any>;
|
|
8
|
+
/**
|
|
9
|
+
* 刷新Token方式二:使用 `@delon/auth` 的 `refresh` 接口,需要在 `app.config.ts` 中注册 `provideBindAuthRefresh`
|
|
10
|
+
*/
|
|
11
|
+
export declare function provideBindAuthRefresh(): EnvironmentProviders[];
|
|
@@ -0,0 +1,18 @@
|
|
|
1
|
+
import { InjectionToken } from '@angular/core';
|
|
2
|
+
export interface RuntimeCoreEnvironment {
|
|
3
|
+
production: boolean;
|
|
4
|
+
useHash: boolean;
|
|
5
|
+
api: {
|
|
6
|
+
baseUrl: string;
|
|
7
|
+
licenseUrl?: string;
|
|
8
|
+
flyUrl: string;
|
|
9
|
+
preRequest?: string;
|
|
10
|
+
mockToken?: string;
|
|
11
|
+
refreshTokenEnabled?: boolean;
|
|
12
|
+
refreshTokenType?: string;
|
|
13
|
+
};
|
|
14
|
+
modules?: unknown[];
|
|
15
|
+
config?: unknown;
|
|
16
|
+
configFile?: string;
|
|
17
|
+
}
|
|
18
|
+
export declare const RUNTIME_CORE_ENVIRONMENT: InjectionToken<RuntimeCoreEnvironment>;
|
|
@@ -0,0 +1,24 @@
|
|
|
1
|
+
import { EnvironmentProviders, Provider } from '@angular/core';
|
|
2
|
+
import { Observable } from 'rxjs';
|
|
3
|
+
import * as i0 from "@angular/core";
|
|
4
|
+
/**
|
|
5
|
+
* Used for application startup
|
|
6
|
+
* Generally used to get the basic data of the application, like: Menu Data, User Data, etc.
|
|
7
|
+
*/
|
|
8
|
+
export declare function provideStartup(): Array<Provider | EnvironmentProviders>;
|
|
9
|
+
export declare class StartupService {
|
|
10
|
+
private menuService;
|
|
11
|
+
private settingService;
|
|
12
|
+
private aclService;
|
|
13
|
+
private titleService;
|
|
14
|
+
private httpClient;
|
|
15
|
+
private http;
|
|
16
|
+
private router;
|
|
17
|
+
private i18n;
|
|
18
|
+
private tokenSrv;
|
|
19
|
+
private environment;
|
|
20
|
+
load(): Observable<void>;
|
|
21
|
+
getModule(): Observable<any>;
|
|
22
|
+
static ɵfac: i0.ɵɵFactoryDeclaration<StartupService, never>;
|
|
23
|
+
static ɵprov: i0.ɵɵInjectableDeclaration<StartupService>;
|
|
24
|
+
}
|
|
@@ -0,0 +1,8 @@
|
|
|
1
|
+
import * as i0 from "@angular/core";
|
|
2
|
+
import * as i1 from "@angular/router";
|
|
3
|
+
import * as i2 from "./main/index";
|
|
4
|
+
export declare class ExceptionModule {
|
|
5
|
+
static ɵfac: i0.ɵɵFactoryDeclaration<ExceptionModule, never>;
|
|
6
|
+
static ɵmod: i0.ɵɵNgModuleDeclaration<ExceptionModule, never, [typeof i1.RouterModule, typeof i2.ExceptionMainComponent], [typeof i1.RouterModule]>;
|
|
7
|
+
static ɵinj: i0.ɵɵInjectorDeclaration<ExceptionModule>;
|
|
8
|
+
}
|
|
@@ -0,0 +1,11 @@
|
|
|
1
|
+
import { OnDestroy, AfterViewInit } from '@angular/core';
|
|
2
|
+
import { TitleService } from '@delon/theme';
|
|
3
|
+
import * as i0 from "@angular/core";
|
|
4
|
+
export declare class ExceptionMainComponent implements AfterViewInit, OnDestroy {
|
|
5
|
+
titleSrv: TitleService;
|
|
6
|
+
constructor(titleSrv: TitleService);
|
|
7
|
+
ngAfterViewInit(): void;
|
|
8
|
+
ngOnDestroy(): void;
|
|
9
|
+
static ɵfac: i0.ɵɵFactoryDeclaration<ExceptionMainComponent, never>;
|
|
10
|
+
static ɵcmp: i0.ɵɵComponentDeclaration<ExceptionMainComponent, "exception-main", never, {}, {}, never, never, true, never>;
|
|
11
|
+
}
|