@gct-paas/core 0.1.4-dev.12 → 0.1.4-dev.14
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/dist/index.esm.min.js +1 -21679
- package/es/constants/index.d.ts +1 -0
- package/es/constants/index.mjs +1 -0
- package/es/constants/page-designer/regex.d.ts +2 -0
- package/es/constants/page-designer/regex.mjs +5 -0
- package/es/enums/index.mjs +1 -0
- package/es/enums/page-designer/index.d.ts +1 -0
- package/es/enums/page-designer/index.mjs +1 -0
- package/es/enums/page-designer/layout.d.ts +12 -0
- package/es/enums/page-designer/layout.mjs +17 -0
- package/es/global/gct/gct.d.ts +226 -0
- package/es/global/gct/gct.mjs +10 -0
- package/es/index.mjs +14 -11
- package/es/interface/i-pinia-state/i-global-state.d.ts +0 -11
- package/es/modules/env-manager/env-manager.d.ts +2 -0
- package/es/modules/env-manager/env-manager.interface.d.ts +2 -0
- package/es/modules/env-manager/env-manager.mjs +5 -1
- package/es/modules/platform-config/index.d.ts +1 -1
- package/es/modules/platform-config/store.d.ts +1 -0
- package/es/setup-app.mjs +1 -1
- package/es/state/global-pinia-state/global-pinia-state.d.ts +0 -6
- package/es/state/global-pinia-state/global-pinia-state.mjs +0 -6
- package/es/store/index.d.ts +7 -0
- package/es/store/index.mjs +9 -0
- package/es/types/index.d.ts +11 -0
- package/es/utils/axios/interceptors.mjs +1 -2
- package/es/utils/css-loader/css-loader.d.ts +36 -0
- package/es/utils/css-loader/css-loader.mjs +82 -0
- package/es/utils/deviceFingerprint.mjs +6 -3
- package/es/utils/index.d.ts +2 -1
- package/es/utils/index.mjs +1 -0
- package/es/utils/plugin-static-resource/plugin-static-resource.d.ts +2 -27
- package/es/utils/plugin-static-resource/plugin-static-resource.mjs +5 -32
- package/es/utils/uuid/uuid.d.ts +2 -1
- package/es/utils/uuid/uuid.mjs +1 -4
- package/package.json +7 -19
package/es/constants/index.d.ts
CHANGED
|
@@ -20,3 +20,4 @@ export { FormContainerType } from './form-container-type/form-container-type';
|
|
|
20
20
|
export { DefaultDateTypeConst } from './default-date-type/default-date-type';
|
|
21
21
|
export { CoreConst } from './core';
|
|
22
22
|
export { ModelTypeOptions } from './page-designer/model';
|
|
23
|
+
export * from './page-designer/regex';
|
package/es/constants/index.mjs
CHANGED
|
@@ -10,6 +10,7 @@ import "./form-container-type/form-container-type.mjs";
|
|
|
10
10
|
import "./default-date-type/default-date-type.mjs";
|
|
11
11
|
import "./core.mjs";
|
|
12
12
|
import "./page-designer/model.mjs";
|
|
13
|
+
import "./page-designer/regex.mjs";
|
|
13
14
|
//#region src/constants/index.ts
|
|
14
15
|
/**
|
|
15
16
|
* 默认样式命名空间名称
|
package/es/enums/index.mjs
CHANGED
|
@@ -4,6 +4,7 @@ import "./page-designer/panel.mjs";
|
|
|
4
4
|
import "./page-designer/toolkit.mjs";
|
|
5
5
|
import "./page-designer/widget.mjs";
|
|
6
6
|
import "./page-designer/designer.mjs";
|
|
7
|
+
import "./page-designer/layout.mjs";
|
|
7
8
|
import "./page-designer/index.mjs";
|
|
8
9
|
import "./developer-center/integration.mjs";
|
|
9
10
|
import "./appStateEnum.mjs";
|
|
@@ -0,0 +1,17 @@
|
|
|
1
|
+
//#region src/enums/page-designer/layout.ts
|
|
2
|
+
var FormDesignEnum = /* @__PURE__ */ function(FormDesignEnum) {
|
|
3
|
+
/**在线表单 */
|
|
4
|
+
FormDesignEnum["ONLINE_FORM"] = "online_form_module";
|
|
5
|
+
/**eDHR */
|
|
6
|
+
FormDesignEnum["EDHR"] = "edhr_module";
|
|
7
|
+
return FormDesignEnum;
|
|
8
|
+
}({});
|
|
9
|
+
var PrintTypeEnum = /* @__PURE__ */ function(PrintTypeEnum) {
|
|
10
|
+
/** 标签 */
|
|
11
|
+
PrintTypeEnum["LABEL"] = "label_module";
|
|
12
|
+
/** 单据 */
|
|
13
|
+
PrintTypeEnum["RECEIPT"] = "document_module";
|
|
14
|
+
return PrintTypeEnum;
|
|
15
|
+
}({});
|
|
16
|
+
//#endregion
|
|
17
|
+
export { FormDesignEnum, PrintTypeEnum };
|
package/es/global/gct/gct.d.ts
CHANGED
|
@@ -12,6 +12,11 @@ import { RouterUtil } from '../../router';
|
|
|
12
12
|
* @class GctGlobal
|
|
13
13
|
*/
|
|
14
14
|
export declare class GctGlobal {
|
|
15
|
+
/**
|
|
16
|
+
* 模块联邦实例
|
|
17
|
+
*
|
|
18
|
+
* @description 使用规范参考官方文档: https://module-federation.io/zh/guide/start/index.html
|
|
19
|
+
*/
|
|
15
20
|
/**
|
|
16
21
|
* i18n 工具类
|
|
17
22
|
*/
|
|
@@ -31,6 +36,227 @@ export declare class GctGlobal {
|
|
|
31
36
|
* 全局 store 实例
|
|
32
37
|
*/
|
|
33
38
|
readonly store: import('pinia').Store<"global-store", import('../..').IGlobalState, import('../..').IGlobalGetters, import('../..').IGlobalActions>;
|
|
39
|
+
/**
|
|
40
|
+
* 全局平台配置 store 实例
|
|
41
|
+
*
|
|
42
|
+
*/
|
|
43
|
+
readonly platformStore: import('pinia').Store<"platform-config", Pick<{
|
|
44
|
+
projectSetting: {};
|
|
45
|
+
setProjectConfig: (config: {}) => void;
|
|
46
|
+
deploySetting: {
|
|
47
|
+
deployMode: import('../..').DeployModeEnum;
|
|
48
|
+
};
|
|
49
|
+
setDeploySetting: (data: import('@gct-paas/api/platform').SysConfigResponse) => void;
|
|
50
|
+
isIndependentApp: import('vue').ComputedRef<boolean>;
|
|
51
|
+
watermarkSetting: {
|
|
52
|
+
openWatermark: boolean;
|
|
53
|
+
watermarkContent: string;
|
|
54
|
+
fontSize: number;
|
|
55
|
+
color: string;
|
|
56
|
+
verticalAlign: string;
|
|
57
|
+
textAlign: string;
|
|
58
|
+
text: string;
|
|
59
|
+
transparent: number;
|
|
60
|
+
width: number;
|
|
61
|
+
height: number;
|
|
62
|
+
};
|
|
63
|
+
postWatermarkSetting: () => Promise<void>;
|
|
64
|
+
setWatermarkSetting: (data: import('@gct-paas/api/platform').SysConfigResponse) => void;
|
|
65
|
+
themeSetting: import('../..').IThemeSetting;
|
|
66
|
+
setThemeSetting: (data: import('@gct-paas/api/platform').SysConfigResponse) => void;
|
|
67
|
+
postThemeSetting: () => Promise<void>;
|
|
68
|
+
menuCollapsed: import('vue').Ref<boolean, boolean>;
|
|
69
|
+
toggleMenuCollapsed: () => void;
|
|
70
|
+
menuCollapsedWidth: number;
|
|
71
|
+
menuWidthRange: number[];
|
|
72
|
+
themeColors: string[];
|
|
73
|
+
securitySetting: import('@gct-paas/api/platform').SecurityConfig;
|
|
74
|
+
postSecuritySetting: () => Promise<void>;
|
|
75
|
+
setSecuritySetting: (data: import('@gct-paas/api/platform').SysConfigResponse) => void;
|
|
76
|
+
orgSetting: import('@gct-paas/api/platform').OrgConfig;
|
|
77
|
+
setOrgSetting: (data: import('@gct-paas/api/platform').SysConfigResponse) => void;
|
|
78
|
+
postOrgSetting: () => Promise<void>;
|
|
79
|
+
relationFields: import('vue').Ref<{
|
|
80
|
+
label: string;
|
|
81
|
+
value: string;
|
|
82
|
+
type: number;
|
|
83
|
+
}[], {
|
|
84
|
+
label: string;
|
|
85
|
+
value: string;
|
|
86
|
+
type: number;
|
|
87
|
+
}[] | {
|
|
88
|
+
label: string;
|
|
89
|
+
value: string;
|
|
90
|
+
type: number;
|
|
91
|
+
}[]>;
|
|
92
|
+
relationFiledsCopy: import('vue').Ref<{
|
|
93
|
+
label: string;
|
|
94
|
+
value: string;
|
|
95
|
+
}[], {
|
|
96
|
+
label: string;
|
|
97
|
+
value: string;
|
|
98
|
+
}[] | {
|
|
99
|
+
label: string;
|
|
100
|
+
value: string;
|
|
101
|
+
}[]>;
|
|
102
|
+
loginSetting: import('@gct-paas/api/platform').AuthConfig;
|
|
103
|
+
postLoginSetting: () => Promise<void>;
|
|
104
|
+
setLoginSetting: (config: import('@gct-paas/api/platform').SysConfigResponse | undefined) => void;
|
|
105
|
+
loginModeAuthTypes: import('vue').Ref<string[], string[]>;
|
|
106
|
+
openIDOAuthAuthTypes: import('vue').Ref<string[], string[]>;
|
|
107
|
+
sysLoginSort: import('vue').Ref<IObject[], IObject[]>;
|
|
108
|
+
openIDOAuthAuthSort: import('vue').Ref<IObject[], IObject[]>;
|
|
109
|
+
loginModeConfig: Map<string, IObject>;
|
|
110
|
+
basicSetting: import('@gct-paas/api/platform').PlatformBaseConfig;
|
|
111
|
+
setBasicSetting: (data: import('@gct-paas/api/platform').SysConfigResponse, transfer?: boolean) => void;
|
|
112
|
+
postBasicSetting: () => Promise<string>;
|
|
113
|
+
init: () => Promise<void>;
|
|
114
|
+
renderInit: () => Promise<void>;
|
|
115
|
+
}, "projectSetting" | "deploySetting" | "watermarkSetting" | "themeSetting" | "menuCollapsed" | "menuCollapsedWidth" | "menuWidthRange" | "themeColors" | "securitySetting" | "orgSetting" | "relationFields" | "relationFiledsCopy" | "loginSetting" | "loginModeAuthTypes" | "openIDOAuthAuthTypes" | "sysLoginSort" | "openIDOAuthAuthSort" | "loginModeConfig" | "basicSetting">, Pick<{
|
|
116
|
+
projectSetting: {};
|
|
117
|
+
setProjectConfig: (config: {}) => void;
|
|
118
|
+
deploySetting: {
|
|
119
|
+
deployMode: import('../..').DeployModeEnum;
|
|
120
|
+
};
|
|
121
|
+
setDeploySetting: (data: import('@gct-paas/api/platform').SysConfigResponse) => void;
|
|
122
|
+
isIndependentApp: import('vue').ComputedRef<boolean>;
|
|
123
|
+
watermarkSetting: {
|
|
124
|
+
openWatermark: boolean;
|
|
125
|
+
watermarkContent: string;
|
|
126
|
+
fontSize: number;
|
|
127
|
+
color: string;
|
|
128
|
+
verticalAlign: string;
|
|
129
|
+
textAlign: string;
|
|
130
|
+
text: string;
|
|
131
|
+
transparent: number;
|
|
132
|
+
width: number;
|
|
133
|
+
height: number;
|
|
134
|
+
};
|
|
135
|
+
postWatermarkSetting: () => Promise<void>;
|
|
136
|
+
setWatermarkSetting: (data: import('@gct-paas/api/platform').SysConfigResponse) => void;
|
|
137
|
+
themeSetting: import('../..').IThemeSetting;
|
|
138
|
+
setThemeSetting: (data: import('@gct-paas/api/platform').SysConfigResponse) => void;
|
|
139
|
+
postThemeSetting: () => Promise<void>;
|
|
140
|
+
menuCollapsed: import('vue').Ref<boolean, boolean>;
|
|
141
|
+
toggleMenuCollapsed: () => void;
|
|
142
|
+
menuCollapsedWidth: number;
|
|
143
|
+
menuWidthRange: number[];
|
|
144
|
+
themeColors: string[];
|
|
145
|
+
securitySetting: import('@gct-paas/api/platform').SecurityConfig;
|
|
146
|
+
postSecuritySetting: () => Promise<void>;
|
|
147
|
+
setSecuritySetting: (data: import('@gct-paas/api/platform').SysConfigResponse) => void;
|
|
148
|
+
orgSetting: import('@gct-paas/api/platform').OrgConfig;
|
|
149
|
+
setOrgSetting: (data: import('@gct-paas/api/platform').SysConfigResponse) => void;
|
|
150
|
+
postOrgSetting: () => Promise<void>;
|
|
151
|
+
relationFields: import('vue').Ref<{
|
|
152
|
+
label: string;
|
|
153
|
+
value: string;
|
|
154
|
+
type: number;
|
|
155
|
+
}[], {
|
|
156
|
+
label: string;
|
|
157
|
+
value: string;
|
|
158
|
+
type: number;
|
|
159
|
+
}[] | {
|
|
160
|
+
label: string;
|
|
161
|
+
value: string;
|
|
162
|
+
type: number;
|
|
163
|
+
}[]>;
|
|
164
|
+
relationFiledsCopy: import('vue').Ref<{
|
|
165
|
+
label: string;
|
|
166
|
+
value: string;
|
|
167
|
+
}[], {
|
|
168
|
+
label: string;
|
|
169
|
+
value: string;
|
|
170
|
+
}[] | {
|
|
171
|
+
label: string;
|
|
172
|
+
value: string;
|
|
173
|
+
}[]>;
|
|
174
|
+
loginSetting: import('@gct-paas/api/platform').AuthConfig;
|
|
175
|
+
postLoginSetting: () => Promise<void>;
|
|
176
|
+
setLoginSetting: (config: import('@gct-paas/api/platform').SysConfigResponse | undefined) => void;
|
|
177
|
+
loginModeAuthTypes: import('vue').Ref<string[], string[]>;
|
|
178
|
+
openIDOAuthAuthTypes: import('vue').Ref<string[], string[]>;
|
|
179
|
+
sysLoginSort: import('vue').Ref<IObject[], IObject[]>;
|
|
180
|
+
openIDOAuthAuthSort: import('vue').Ref<IObject[], IObject[]>;
|
|
181
|
+
loginModeConfig: Map<string, IObject>;
|
|
182
|
+
basicSetting: import('@gct-paas/api/platform').PlatformBaseConfig;
|
|
183
|
+
setBasicSetting: (data: import('@gct-paas/api/platform').SysConfigResponse, transfer?: boolean) => void;
|
|
184
|
+
postBasicSetting: () => Promise<string>;
|
|
185
|
+
init: () => Promise<void>;
|
|
186
|
+
renderInit: () => Promise<void>;
|
|
187
|
+
}, "isIndependentApp">, Pick<{
|
|
188
|
+
projectSetting: {};
|
|
189
|
+
setProjectConfig: (config: {}) => void;
|
|
190
|
+
deploySetting: {
|
|
191
|
+
deployMode: import('../..').DeployModeEnum;
|
|
192
|
+
};
|
|
193
|
+
setDeploySetting: (data: import('@gct-paas/api/platform').SysConfigResponse) => void;
|
|
194
|
+
isIndependentApp: import('vue').ComputedRef<boolean>;
|
|
195
|
+
watermarkSetting: {
|
|
196
|
+
openWatermark: boolean;
|
|
197
|
+
watermarkContent: string;
|
|
198
|
+
fontSize: number;
|
|
199
|
+
color: string;
|
|
200
|
+
verticalAlign: string;
|
|
201
|
+
textAlign: string;
|
|
202
|
+
text: string;
|
|
203
|
+
transparent: number;
|
|
204
|
+
width: number;
|
|
205
|
+
height: number;
|
|
206
|
+
};
|
|
207
|
+
postWatermarkSetting: () => Promise<void>;
|
|
208
|
+
setWatermarkSetting: (data: import('@gct-paas/api/platform').SysConfigResponse) => void;
|
|
209
|
+
themeSetting: import('../..').IThemeSetting;
|
|
210
|
+
setThemeSetting: (data: import('@gct-paas/api/platform').SysConfigResponse) => void;
|
|
211
|
+
postThemeSetting: () => Promise<void>;
|
|
212
|
+
menuCollapsed: import('vue').Ref<boolean, boolean>;
|
|
213
|
+
toggleMenuCollapsed: () => void;
|
|
214
|
+
menuCollapsedWidth: number;
|
|
215
|
+
menuWidthRange: number[];
|
|
216
|
+
themeColors: string[];
|
|
217
|
+
securitySetting: import('@gct-paas/api/platform').SecurityConfig;
|
|
218
|
+
postSecuritySetting: () => Promise<void>;
|
|
219
|
+
setSecuritySetting: (data: import('@gct-paas/api/platform').SysConfigResponse) => void;
|
|
220
|
+
orgSetting: import('@gct-paas/api/platform').OrgConfig;
|
|
221
|
+
setOrgSetting: (data: import('@gct-paas/api/platform').SysConfigResponse) => void;
|
|
222
|
+
postOrgSetting: () => Promise<void>;
|
|
223
|
+
relationFields: import('vue').Ref<{
|
|
224
|
+
label: string;
|
|
225
|
+
value: string;
|
|
226
|
+
type: number;
|
|
227
|
+
}[], {
|
|
228
|
+
label: string;
|
|
229
|
+
value: string;
|
|
230
|
+
type: number;
|
|
231
|
+
}[] | {
|
|
232
|
+
label: string;
|
|
233
|
+
value: string;
|
|
234
|
+
type: number;
|
|
235
|
+
}[]>;
|
|
236
|
+
relationFiledsCopy: import('vue').Ref<{
|
|
237
|
+
label: string;
|
|
238
|
+
value: string;
|
|
239
|
+
}[], {
|
|
240
|
+
label: string;
|
|
241
|
+
value: string;
|
|
242
|
+
}[] | {
|
|
243
|
+
label: string;
|
|
244
|
+
value: string;
|
|
245
|
+
}[]>;
|
|
246
|
+
loginSetting: import('@gct-paas/api/platform').AuthConfig;
|
|
247
|
+
postLoginSetting: () => Promise<void>;
|
|
248
|
+
setLoginSetting: (config: import('@gct-paas/api/platform').SysConfigResponse | undefined) => void;
|
|
249
|
+
loginModeAuthTypes: import('vue').Ref<string[], string[]>;
|
|
250
|
+
openIDOAuthAuthTypes: import('vue').Ref<string[], string[]>;
|
|
251
|
+
sysLoginSort: import('vue').Ref<IObject[], IObject[]>;
|
|
252
|
+
openIDOAuthAuthSort: import('vue').Ref<IObject[], IObject[]>;
|
|
253
|
+
loginModeConfig: Map<string, IObject>;
|
|
254
|
+
basicSetting: import('@gct-paas/api/platform').PlatformBaseConfig;
|
|
255
|
+
setBasicSetting: (data: import('@gct-paas/api/platform').SysConfigResponse, transfer?: boolean) => void;
|
|
256
|
+
postBasicSetting: () => Promise<string>;
|
|
257
|
+
init: () => Promise<void>;
|
|
258
|
+
renderInit: () => Promise<void>;
|
|
259
|
+
}, "setProjectConfig" | "setDeploySetting" | "postWatermarkSetting" | "setWatermarkSetting" | "setThemeSetting" | "postThemeSetting" | "toggleMenuCollapsed" | "postSecuritySetting" | "setSecuritySetting" | "setOrgSetting" | "postOrgSetting" | "postLoginSetting" | "setLoginSetting" | "setBasicSetting" | "postBasicSetting" | "init" | "renderInit">>;
|
|
34
260
|
/**
|
|
35
261
|
* 全局 router 工具类
|
|
36
262
|
*/
|
package/es/global/gct/gct.mjs
CHANGED
|
@@ -14,6 +14,11 @@ import { RouterUtil } from "../../router/index.mjs";
|
|
|
14
14
|
* @class GctGlobal
|
|
15
15
|
*/
|
|
16
16
|
var GctGlobal = class {
|
|
17
|
+
/**
|
|
18
|
+
* 模块联邦实例
|
|
19
|
+
*
|
|
20
|
+
* @description 使用规范参考官方文档: https://module-federation.io/zh/guide/start/index.html
|
|
21
|
+
*/
|
|
17
22
|
/**
|
|
18
23
|
* i18n 工具类
|
|
19
24
|
*/
|
|
@@ -34,6 +39,11 @@ var GctGlobal = class {
|
|
|
34
39
|
*/
|
|
35
40
|
store = this.storeUtil.store;
|
|
36
41
|
/**
|
|
42
|
+
* 全局平台配置 store 实例
|
|
43
|
+
*
|
|
44
|
+
*/
|
|
45
|
+
platformStore = this.storeUtil.platformConfigStore;
|
|
46
|
+
/**
|
|
37
47
|
* 全局 router 工具类
|
|
38
48
|
*/
|
|
39
49
|
routerUtil = new RouterUtil();
|
package/es/index.mjs
CHANGED
|
@@ -4,6 +4,7 @@ import { ASSIGNMENTSTRATEGY_ENUM, BorderStyle, COLUMNS_TYPE, Dependency_ENUM, Di
|
|
|
4
4
|
import { ToolkitEnum } from "./enums/page-designer/toolkit.mjs";
|
|
5
5
|
import { BuiltinType, ButtonColorTheme, ButtonColorType, ButtonGroupType, ButtonSize, ButtonStyle, ButtonType, ButtonTypeGroup, ButtonType_vant, CURRENCY_ENUM, CURRENCY_LANG_ENUM, CategoryTypeEnum, DatasourceTypeEnum, DateRangeEnums, DisplayEnums, KeyMode, ListTreeSearchTypeEnum, Platform, PrintModeEnums, ResetRuleType, RowSelectionTypeEnums, SelectPickerEnums, SignatureStyleEnum, SignatureTypeEnum, StatisticalMethodEnums, TIMETYPE_ENUM, TIMETYPE_LANG_ENUM, TableEditingMethodEnum, TableSearchTypeEnum, TableTypeEnum, TransactionMode, WidgetInScopeEnum, openWindowEnums, operateSysEnums } from "./enums/page-designer/widget.mjs";
|
|
6
6
|
import { BindCmpStyleEnum, BindCmpStyleTypeEnum, Ch_BindCmpStyleEnum, FormComponents, SCOPE, SCOPEINFO, SearchComponents, bindCmpStyleMap, buttonShowType, controlConfigEnum, fixedAlignENUM, mobileSearchListByFieldType, padSearchListByFieldType, searchListByFieldType, sortTypeEnum, statisticalMethodEnum, tableColumnTypeEnum, tableColumnWidthEnum, tabsTypeENUM, transformBindCmp2CmpType } from "./enums/page-designer/designer.mjs";
|
|
7
|
+
import { FormDesignEnum, PrintTypeEnum } from "./enums/page-designer/layout.mjs";
|
|
7
8
|
import { PrintResourceEnum } from "./enums/developer-center/integration.mjs";
|
|
8
9
|
import { AppPublishStateEnum } from "./enums/appStateEnum.mjs";
|
|
9
10
|
import { BasicAction, CustomAction, DefaultActions, PlatformSettingActions } from "./enums/authActionEnum.mjs";
|
|
@@ -21,6 +22,7 @@ import { BpmnNodeTypeEnum, ButtonTypeEnum, ExamineAndApproveStateEnum, OpinionTy
|
|
|
21
22
|
import { PluginModeEnum } from "./enums/plugin-enum.mjs";
|
|
22
23
|
import { DataSetReturnTypeEnum, EntityFormulaReturnTypeEnum, ExpressionModeEnum, ExpressionTabEnum, IdentifierAddon, OperatorTypeEnum, ReturnTypeEnum, VarTypeEnum, zeroWidthSpace } from "./enums/expressionEnum.mjs";
|
|
23
24
|
import { GctMqttTopsEnum, GlobalParamEnum } from "./enums/index.mjs";
|
|
25
|
+
import { cssLoader } from "./utils/css-loader/css-loader.mjs";
|
|
24
26
|
import { gctMemoizeAsync } from "./utils/cache-adapter/cache-adapter.mjs";
|
|
25
27
|
import { DictionaryUtil } from "./utils/dictionary/dictionary.mjs";
|
|
26
28
|
import { t } from "./utils/i18n/index.mjs";
|
|
@@ -42,6 +44,7 @@ import { FormContainerType } from "./constants/form-container-type/form-containe
|
|
|
42
44
|
import { DefaultDateTypeConst } from "./constants/default-date-type/default-date-type.mjs";
|
|
43
45
|
import { CoreConst } from "./constants/core.mjs";
|
|
44
46
|
import { ModelTypeOptions } from "./constants/page-designer/model.mjs";
|
|
47
|
+
import { timeReg, urlReg } from "./constants/page-designer/regex.mjs";
|
|
45
48
|
import { APP_INST, PLUGIN_BASE_URL, STYLE_NAMESPACE_TAG, VITE_MINIO_PATH } from "./constants/index.mjs";
|
|
46
49
|
import { Namespace, useNamespace } from "./utils/namespace/namespace.mjs";
|
|
47
50
|
import { Modal } from "./utils/openUtil/modal/modal.mjs";
|
|
@@ -51,7 +54,7 @@ import { deepMerge, getTenant, getTimezone, getToken, isMobile, parseMatrixParam
|
|
|
51
54
|
import { buildShortUUID, buildUUID, sha256, uuid2 } from "./utils/uuid/uuid.mjs";
|
|
52
55
|
import { afterFieldSet, afterValueSet, cacheFnReturn, computedEx, emitFieldSet, parseValueUnit } from "./utils/value-helper/value-helper.mjs";
|
|
53
56
|
import { interceptors } from "./utils/axios/interceptors.mjs";
|
|
54
|
-
import { getDeviceFingerprint, getPageIdentification } from "./utils/deviceFingerprint.mjs";
|
|
57
|
+
import { getDeviceFingerprint, getMobileBrowserFingerprint, getPageIdentification } from "./utils/deviceFingerprint.mjs";
|
|
55
58
|
import { TreeHelper } from "./utils/treeHelper/treeHelper.mjs";
|
|
56
59
|
import { calcFontStyle, calcStyle } from "./utils/style/index.mjs";
|
|
57
60
|
import { genUrl, openWindow } from "./utils/util.mjs";
|
|
@@ -65,6 +68,15 @@ import { sizeParser, typeParser } from "./utils/file/parser.mjs";
|
|
|
65
68
|
import { isMultipleOperator } from "./utils/design/design.mjs";
|
|
66
69
|
import { permission } from "./utils/permission.mjs";
|
|
67
70
|
import "./utils/index.mjs";
|
|
71
|
+
import { LoginSortTypeEnum, LoginTypeEnum } from "./modules/platform-config/enums/login.enum.mjs";
|
|
72
|
+
import { KickRuleEnum, PassRule } from "./modules/platform-config/enums/platform.enum.mjs";
|
|
73
|
+
import { DeployModeEnum } from "./modules/platform-config/enums/deploy.enum.mjs";
|
|
74
|
+
import { OTHER_LOGIN_KEYS, SYSTEM_LOGIN_KEYS, getLoginTypeOptions } from "./modules/platform-config/constants/login.const.mjs";
|
|
75
|
+
import { RELATION_FIELDS } from "./modules/platform-config/constants/org.const.mjs";
|
|
76
|
+
import { MENU_COLLAPSED_WIDTH, MENU_WIDTH_RANGE, THEME_COLORS } from "./modules/platform-config/constants/theme.const.mjs";
|
|
77
|
+
import { WATERMARK_INIT_DATA } from "./modules/platform-config/constants/watermark.const.mjs";
|
|
78
|
+
import { usePlatformConfigStore } from "./modules/platform-config/store.mjs";
|
|
79
|
+
import "./modules/platform-config/index.mjs";
|
|
68
80
|
import { GlobalStoreUtil } from "./store/index.mjs";
|
|
69
81
|
import { EnvironmentType } from "./modules/env-manager/env-manager.interface.mjs";
|
|
70
82
|
import { APP_PREVIEW_PATH_REG, APP_PROD_PATH_REG, APP_RUN_PATH_REG, DEV_SINGLE_PATH_REG, HOST_REG, IP_REG, TEST_SINGLE_PATH_REG } from "./modules/env-manager/env-manager.const.mjs";
|
|
@@ -84,15 +96,6 @@ import { copyTextToClipboard, isDef, useCopyToClipboard } from "./hooks/useCopyT
|
|
|
84
96
|
import "./hooks/index.mjs";
|
|
85
97
|
import { ErrorStrategyFactory } from "./modules/error-handler/error-strategy.mjs";
|
|
86
98
|
import { ErrorHandler, setupErrorHandler } from "./modules/error-handler/index.mjs";
|
|
87
|
-
import { LoginSortTypeEnum, LoginTypeEnum } from "./modules/platform-config/enums/login.enum.mjs";
|
|
88
|
-
import { KickRuleEnum, PassRule } from "./modules/platform-config/enums/platform.enum.mjs";
|
|
89
|
-
import { DeployModeEnum } from "./modules/platform-config/enums/deploy.enum.mjs";
|
|
90
|
-
import { OTHER_LOGIN_KEYS, SYSTEM_LOGIN_KEYS, getLoginTypeOptions } from "./modules/platform-config/constants/login.const.mjs";
|
|
91
|
-
import { RELATION_FIELDS } from "./modules/platform-config/constants/org.const.mjs";
|
|
92
|
-
import { MENU_COLLAPSED_WIDTH, MENU_WIDTH_RANGE, THEME_COLORS } from "./modules/platform-config/constants/theme.const.mjs";
|
|
93
|
-
import { WATERMARK_INIT_DATA } from "./modules/platform-config/constants/watermark.const.mjs";
|
|
94
|
-
import { usePlatformConfigStore } from "./modules/platform-config/store.mjs";
|
|
95
|
-
import "./modules/platform-config/index.mjs";
|
|
96
99
|
import { useUserStore } from "./modules/user-stores/store/user.store.mjs";
|
|
97
100
|
import { useTenantStore } from "./modules/user-stores/store/tenant.store.mjs";
|
|
98
101
|
import { usePermissionStore } from "./modules/user-stores/store/permission.store.mjs";
|
|
@@ -122,4 +125,4 @@ function onInit() {
|
|
|
122
125
|
}
|
|
123
126
|
onInit();
|
|
124
127
|
//#endregion
|
|
125
|
-
export { AGLINE_ENUMS, APP_DARK_MODE_KEY_, APP_INST, APP_LOCAL_CACHE_KEY, APP_PREVIEW_PATH_REG, APP_PROD_PATH_REG, APP_RUN_PATH_REG, APP_SESSION_CACHE_KEY, ARRAY_TYPE, ASSIGNMENTSTRATEGY_ENUM, AggTypes, AppPublishStateEnum, BOOLEAN_TYPE, BasicAction, BindCmpStyleEnum, BindCmpStyleTypeEnum, BizServiceEnum, BorderStyle, BpmnNodeTypeEnum, BuiltOperators, BuiltinType, ButtonColorTheme, ButtonColorType, ButtonGroupType, ButtonOpeEnum, ButtonSize, ButtonStyle, ButtonType, ButtonTypeEnum, ButtonTypeGroup, ButtonType_vant, CARD_TRIGGER_ENUM, COLUMNS_TYPE, CURRENCY_ENUM, CURRENCY_LANG_ENUM, CUSTOM_LANGUAGE, CUSTOM_THEME, CacheTypeEnum, CategoryTypeEnum, Ch_BindCmpStyleEnum, ContentEnum, ContentTypeEnum, CoreConst, CreateType, CustomAction, DESIGNER_SESSION_CACHE_KEY, DEV_SINGLE_PATH_REG, DataSetReturnTypeEnum, DatasourceTypeEnum, DateRangeEnums, DefaultActions, DefaultDateTypeConst, Dependency_ENUM, DeployModeEnum, DeviceParamsTypeEnum, DictionaryUtil, DisplayEnums, DisplayTagTypeEnum, DisplayType, EditorRegisterConst, EntityFormulaReturnTypeEnum, EntityModelCategoryEnum, EntityModelTypeEnum, EnvironmentManager, EnvironmentType, ErrorHandler, ErrorStrategyFactory, ErrorTypeEnum, EventCategory, ExamineAndApproveStateEnum, ExceptionEnum, ExpressionModeEnum, ExpressionTabEnum, FIELD_TYPE, FIELD_TYPE_BASIC, FIELD_TYPE_CATEGORY, FIELD_TYPE_LOGIC, FIELD_TYPE_TRACE, FUNC_KEYS, FUN_BOL_TYPE, FUN_NUM_TYPE, FUN_OBJ_OR_ARR_TYPE, FUN_STR_TYPE, FieldDefaultValueTypeEnum, FieldIconMap, FieldSysVarDefaultValueEnum, FieldTypeToJs, FormComponents, FormContainerType, GENDER_TYPE, GLOBAL_TYPE, GLOBAL_VAR_TYPE, GctGlobal, GctMqttTopsEnum, GlobalParamEnum, GlobalStoreUtil, HOST_REG, INNER_EVENT, IP_REG, IdentifierAddon, KeyMode, KickRuleEnum, LOCALE_KEY, LOCALE_LIST_KEY, LOCAL_I18N_TRANSLATE, LOCK_INFO_KEY, LinkedList, LinkedNode, ListTreeSearchTypeEnum, LocaleUtil, LoginSortTypeEnum, LoginTypeEnum, MENU_COLLAPSED_WIDTH, MENU_WIDTH_RANGE, MQTT_CLIENT_EVENT, MQTT_DEFAULT_CONNECT_OPTIONS, MULTIPLE_TABS_KEY, MaterialEnum, MenuModeEnum, MenuSplitTyeEnum, MenuType, MenuTypeEnum, MessageType, MixSidebarTriggerEnum, Modal, ModeFnMap, ModeTabDict, ModeTabMap, ModelTypeOptions, MqttClient, MqttConnectionStatus, MqttManager, NUMBER_TYPE, Namespace, NodesConfigTypeEnum, OBJECT_TYPE, OTHER_LOGIN_KEYS, OpenMode, OperatorTypeEnum, OpinionTypeEnum, OverlayContainer, PLUGIN_BASE_URL, PROJ_CFG_KEY, PageEnum, PanelEnum, PassRule, PatternEnum, PermissionModeEnum, PersonalCenterType, Platform, PlatformSettingActions, PlatformSettingEnum, PlatformType, PluginModeEnum, PluginStaticResource, Postion, PrintModeEnums, PrintResourceEnum, ProcessStatusEnum, ProgressTypeEnum, ProjectName, PropGroup, RELATION_FIELDS, RETURN_TYPE_MAP, ROLES_KEY, RdoButtonOpeEnum, RequestEnum, ResetRuleType, ResultEnum, ReturnTypeEnum, ReturnTypeMaps, RoleEnum, RouterTransitionEnum, RowSelectionTypeEnums, SCOPE, SCOPEINFO, SEARCH_SERVICE, SHOW_FIELDTYPES, SIDE_BAR_MINI_WIDTH, SIDE_BAR_SHOW_TIT_MINI_WIDTH, STRING_TYPE, STYLE_NAMESPACE_TAG, SUB_TABLE_EDIT_MODE, SUB_TABLE_OPE_EVENT_TYPE, SUB_TABLE_OPE_EVENT_TYPE_INLINE, SYSTEM_LOGIN_KEYS, SYSTEM_VAR_PREFIX, SearchComponents, SelectPickerEnums, SessionTimeoutProcessingEnum, SettingButtonPositionEnum, SignatureStyleEnum, SignatureTypeEnum, SizeEnum, StatisticalMethodEnums, StyleGroup, TENANT_KEY, TEST_SINGLE_PATH_REG, THEME_COLORS, TIMETYPE_ENUM, TIMETYPE_LANG_ENUM, TIMEZONE_KEY, TODO_TYPE, TOKEN_KEY, TableEditingMethodEnum, TableSearchTypeEnum, TableTypeEnum, TagTypeEnum, TextAlign, TextDecoration, ThemeEnum, ToolkitEnum, TopMenuAlignEnum, TransactionMode, TreeHelper, TriggerEnum, TypeEnum, USER_INFO_KEY, UniqueConstraintType, UploadTypeEnum, Uploader, UserServiceType, VERIFICATIONCONDITIONS_TYPE, VITE_MINIO_PATH, VarTypeEnum, WATERMARK_INIT_DATA, WidgetInScopeEnum, WinMsgTypeEnum, WorkbenchType, afterFieldSet, afterValueSet, allOperator, biBackFunctionGroup, biBackFunctionMap, bindCmpStyleMap, booleanOperator, booleanTypes, buildItemRules, buildShortUUID, buildUUID, buttonShowType, cacheFnReturn, calcFontStyle, calcStyle, ch_ProcessStatusMap, computedEx, controlConfigEnum, copyTextToClipboard, createAppVue, dataURLtoBlob, deepMerge, downloadByBase64, downloadByData, downloadByOnlineUrl, downloadByUrl, emitFieldSet, fixedAlignENUM, functionGroup, functionMap, gctMemoizeAsync, genUrl, getDeviceFingerprint, getLoginTypeOptions, getOperatorList, getPageIdentification, getTenant, getTimezone, getToken, hasEmojiAndSpecStr, hasEmojiAndSpecStr1, innerVarIds, innerVarList, insertCustomCssToHead, interceptors, ipaasBackFunctionGroup, ipaasBackFunctionMap, isDef, isMobile, isMultipleOperator, isSortFiled, mitt, mobileSearchListByFieldType, modelLoader, notSingleArr, nullDisplayEnum, numberOperator, numberTypes, openWindow, openWindowEnums, operateSysEnums, operator2FuncMap, padSearchListByFieldType, pageLayoutModeEnum, parseMatrixParams, parseValueUnit, permission, presetColor, randomUUID, returnBolOperator, screenEnum, screenMap, scriptTypeEnum, searchListByFieldType, selectionTypeEnums, setTenant, setToken, setupApp, setupErrorHandler, setupI18n, sha256, sizeEnum, sizeParser, sortTypeEnum, statisticalMethodEnum, stringifyMatrixParams, t, tableColumnTypeEnum, tableColumnWidthEnum, tabsTypeENUM, tagEnum, transformBindCmp2CmpType, typeParser, uploaderFiles, urlToBase64, useAppInst, useCopyToClipboard, useIFrameProps, useModal, useNamespace, usePermissionStore, usePlatformConfigStore, useTenantStore, useUUid, useUserStore, useWuJieBus, useWuJieProps, uuid2, validateEmoji, validateIsModelName, validateModelName, zeroWidthSpace };
|
|
128
|
+
export { AGLINE_ENUMS, APP_DARK_MODE_KEY_, APP_INST, APP_LOCAL_CACHE_KEY, APP_PREVIEW_PATH_REG, APP_PROD_PATH_REG, APP_RUN_PATH_REG, APP_SESSION_CACHE_KEY, ARRAY_TYPE, ASSIGNMENTSTRATEGY_ENUM, AggTypes, AppPublishStateEnum, BOOLEAN_TYPE, BasicAction, BindCmpStyleEnum, BindCmpStyleTypeEnum, BizServiceEnum, BorderStyle, BpmnNodeTypeEnum, BuiltOperators, BuiltinType, ButtonColorTheme, ButtonColorType, ButtonGroupType, ButtonOpeEnum, ButtonSize, ButtonStyle, ButtonType, ButtonTypeEnum, ButtonTypeGroup, ButtonType_vant, CARD_TRIGGER_ENUM, COLUMNS_TYPE, CURRENCY_ENUM, CURRENCY_LANG_ENUM, CUSTOM_LANGUAGE, CUSTOM_THEME, CacheTypeEnum, CategoryTypeEnum, Ch_BindCmpStyleEnum, ContentEnum, ContentTypeEnum, CoreConst, CreateType, CustomAction, DESIGNER_SESSION_CACHE_KEY, DEV_SINGLE_PATH_REG, DataSetReturnTypeEnum, DatasourceTypeEnum, DateRangeEnums, DefaultActions, DefaultDateTypeConst, Dependency_ENUM, DeployModeEnum, DeviceParamsTypeEnum, DictionaryUtil, DisplayEnums, DisplayTagTypeEnum, DisplayType, EditorRegisterConst, EntityFormulaReturnTypeEnum, EntityModelCategoryEnum, EntityModelTypeEnum, EnvironmentManager, EnvironmentType, ErrorHandler, ErrorStrategyFactory, ErrorTypeEnum, EventCategory, ExamineAndApproveStateEnum, ExceptionEnum, ExpressionModeEnum, ExpressionTabEnum, FIELD_TYPE, FIELD_TYPE_BASIC, FIELD_TYPE_CATEGORY, FIELD_TYPE_LOGIC, FIELD_TYPE_TRACE, FUNC_KEYS, FUN_BOL_TYPE, FUN_NUM_TYPE, FUN_OBJ_OR_ARR_TYPE, FUN_STR_TYPE, FieldDefaultValueTypeEnum, FieldIconMap, FieldSysVarDefaultValueEnum, FieldTypeToJs, FormComponents, FormContainerType, FormDesignEnum, GENDER_TYPE, GLOBAL_TYPE, GLOBAL_VAR_TYPE, GctGlobal, GctMqttTopsEnum, GlobalParamEnum, GlobalStoreUtil, HOST_REG, INNER_EVENT, IP_REG, IdentifierAddon, KeyMode, KickRuleEnum, LOCALE_KEY, LOCALE_LIST_KEY, LOCAL_I18N_TRANSLATE, LOCK_INFO_KEY, LinkedList, LinkedNode, ListTreeSearchTypeEnum, LocaleUtil, LoginSortTypeEnum, LoginTypeEnum, MENU_COLLAPSED_WIDTH, MENU_WIDTH_RANGE, MQTT_CLIENT_EVENT, MQTT_DEFAULT_CONNECT_OPTIONS, MULTIPLE_TABS_KEY, MaterialEnum, MenuModeEnum, MenuSplitTyeEnum, MenuType, MenuTypeEnum, MessageType, MixSidebarTriggerEnum, Modal, ModeFnMap, ModeTabDict, ModeTabMap, ModelTypeOptions, MqttClient, MqttConnectionStatus, MqttManager, NUMBER_TYPE, Namespace, NodesConfigTypeEnum, OBJECT_TYPE, OTHER_LOGIN_KEYS, OpenMode, OperatorTypeEnum, OpinionTypeEnum, OverlayContainer, PLUGIN_BASE_URL, PROJ_CFG_KEY, PageEnum, PanelEnum, PassRule, PatternEnum, PermissionModeEnum, PersonalCenterType, Platform, PlatformSettingActions, PlatformSettingEnum, PlatformType, PluginModeEnum, PluginStaticResource, Postion, PrintModeEnums, PrintResourceEnum, PrintTypeEnum, ProcessStatusEnum, ProgressTypeEnum, ProjectName, PropGroup, RELATION_FIELDS, RETURN_TYPE_MAP, ROLES_KEY, RdoButtonOpeEnum, RequestEnum, ResetRuleType, ResultEnum, ReturnTypeEnum, ReturnTypeMaps, RoleEnum, RouterTransitionEnum, RowSelectionTypeEnums, SCOPE, SCOPEINFO, SEARCH_SERVICE, SHOW_FIELDTYPES, SIDE_BAR_MINI_WIDTH, SIDE_BAR_SHOW_TIT_MINI_WIDTH, STRING_TYPE, STYLE_NAMESPACE_TAG, SUB_TABLE_EDIT_MODE, SUB_TABLE_OPE_EVENT_TYPE, SUB_TABLE_OPE_EVENT_TYPE_INLINE, SYSTEM_LOGIN_KEYS, SYSTEM_VAR_PREFIX, SearchComponents, SelectPickerEnums, SessionTimeoutProcessingEnum, SettingButtonPositionEnum, SignatureStyleEnum, SignatureTypeEnum, SizeEnum, StatisticalMethodEnums, StyleGroup, TENANT_KEY, TEST_SINGLE_PATH_REG, THEME_COLORS, TIMETYPE_ENUM, TIMETYPE_LANG_ENUM, TIMEZONE_KEY, TODO_TYPE, TOKEN_KEY, TableEditingMethodEnum, TableSearchTypeEnum, TableTypeEnum, TagTypeEnum, TextAlign, TextDecoration, ThemeEnum, ToolkitEnum, TopMenuAlignEnum, TransactionMode, TreeHelper, TriggerEnum, TypeEnum, USER_INFO_KEY, UniqueConstraintType, UploadTypeEnum, Uploader, UserServiceType, VERIFICATIONCONDITIONS_TYPE, VITE_MINIO_PATH, VarTypeEnum, WATERMARK_INIT_DATA, WidgetInScopeEnum, WinMsgTypeEnum, WorkbenchType, afterFieldSet, afterValueSet, allOperator, biBackFunctionGroup, biBackFunctionMap, bindCmpStyleMap, booleanOperator, booleanTypes, buildItemRules, buildShortUUID, buildUUID, buttonShowType, cacheFnReturn, calcFontStyle, calcStyle, ch_ProcessStatusMap, computedEx, controlConfigEnum, copyTextToClipboard, createAppVue, cssLoader, dataURLtoBlob, deepMerge, downloadByBase64, downloadByData, downloadByOnlineUrl, downloadByUrl, emitFieldSet, fixedAlignENUM, functionGroup, functionMap, gctMemoizeAsync, genUrl, getDeviceFingerprint, getLoginTypeOptions, getMobileBrowserFingerprint, getOperatorList, getPageIdentification, getTenant, getTimezone, getToken, hasEmojiAndSpecStr, hasEmojiAndSpecStr1, innerVarIds, innerVarList, insertCustomCssToHead, interceptors, ipaasBackFunctionGroup, ipaasBackFunctionMap, isDef, isMobile, isMultipleOperator, isSortFiled, mitt, mobileSearchListByFieldType, modelLoader, notSingleArr, nullDisplayEnum, numberOperator, numberTypes, openWindow, openWindowEnums, operateSysEnums, operator2FuncMap, padSearchListByFieldType, pageLayoutModeEnum, parseMatrixParams, parseValueUnit, permission, presetColor, randomUUID, returnBolOperator, screenEnum, screenMap, scriptTypeEnum, searchListByFieldType, selectionTypeEnums, setTenant, setToken, setupApp, setupErrorHandler, setupI18n, sha256, sizeEnum, sizeParser, sortTypeEnum, statisticalMethodEnum, stringifyMatrixParams, t, tableColumnTypeEnum, tableColumnWidthEnum, tabsTypeENUM, tagEnum, timeReg, transformBindCmp2CmpType, typeParser, uploaderFiles, urlReg, urlToBase64, useAppInst, useCopyToClipboard, useIFrameProps, useModal, useNamespace, usePermissionStore, usePlatformConfigStore, useTenantStore, useUUid, useUserStore, useWuJieBus, useWuJieProps, uuid2, validateEmoji, validateIsModelName, validateModelName, zeroWidthSpace };
|
|
@@ -21,17 +21,6 @@ export interface IGlobalState extends StateTree {
|
|
|
21
21
|
* @type {ProjectName}
|
|
22
22
|
*/
|
|
23
23
|
projectName: ProjectName;
|
|
24
|
-
/**
|
|
25
|
-
* 租户标识
|
|
26
|
-
*
|
|
27
|
-
* @type {string}
|
|
28
|
-
*/
|
|
29
|
-
/**
|
|
30
|
-
* 多语言环境
|
|
31
|
-
*
|
|
32
|
-
* @default zh-CN
|
|
33
|
-
* @type {string}
|
|
34
|
-
*/
|
|
35
24
|
/**
|
|
36
25
|
* 应用信息, todo: 等 api 包完成后,实际类型从 api 导入
|
|
37
26
|
*
|
|
@@ -19,6 +19,10 @@ var EnvironmentManager = class {
|
|
|
19
19
|
this._platformOrigin = location.origin || "";
|
|
20
20
|
this._isHostMode = HOST_REG.test(this._platformOrigin);
|
|
21
21
|
}
|
|
22
|
+
/**安卓混合开发模式下 */
|
|
23
|
+
get isAndroid() {
|
|
24
|
+
return window.location.origin === "file://";
|
|
25
|
+
}
|
|
22
26
|
/**
|
|
23
27
|
* 是否为应用前端运行时
|
|
24
28
|
*/
|
|
@@ -97,7 +101,7 @@ var EnvironmentManager = class {
|
|
|
97
101
|
*/
|
|
98
102
|
getEnv() {
|
|
99
103
|
if (this.isTestEnv) return EnvironmentType.TEST;
|
|
100
|
-
else if (this.isAppProd) return EnvironmentType.PROD;
|
|
104
|
+
else if (this.isAppProd || this.isAndroid) return EnvironmentType.PROD;
|
|
101
105
|
else return EnvironmentType.DEV;
|
|
102
106
|
}
|
|
103
107
|
};
|
|
@@ -219,3 +219,4 @@ export declare const usePlatformConfigStore: import('pinia').StoreDefinition<"pl
|
|
|
219
219
|
init: () => Promise<void>;
|
|
220
220
|
renderInit: () => Promise<void>;
|
|
221
221
|
}, "setProjectConfig" | "setDeploySetting" | "postWatermarkSetting" | "setWatermarkSetting" | "setThemeSetting" | "postThemeSetting" | "toggleMenuCollapsed" | "postSecuritySetting" | "setSecuritySetting" | "setOrgSetting" | "postOrgSetting" | "postLoginSetting" | "setLoginSetting" | "setBasicSetting" | "postBasicSetting" | "init" | "renderInit">>;
|
|
222
|
+
export type IPlatformConfigStore = ReturnType<typeof usePlatformConfigStore>;
|
package/es/setup-app.mjs
CHANGED
|
@@ -1,9 +1,9 @@
|
|
|
1
1
|
import { getToken } from "./utils/tools/tools.mjs";
|
|
2
2
|
import { interceptors } from "./utils/axios/interceptors.mjs";
|
|
3
3
|
import "./utils/index.mjs";
|
|
4
|
-
import { setupErrorHandler } from "./modules/error-handler/index.mjs";
|
|
5
4
|
import { usePlatformConfigStore } from "./modules/platform-config/store.mjs";
|
|
6
5
|
import "./modules/platform-config/index.mjs";
|
|
6
|
+
import { setupErrorHandler } from "./modules/error-handler/index.mjs";
|
|
7
7
|
import { useUserStore } from "./modules/user-stores/store/user.store.mjs";
|
|
8
8
|
import "./modules/user-stores/index.mjs";
|
|
9
9
|
import { HttpUtil } from "@gct-paas/api";
|
package/es/store/index.d.ts
CHANGED
|
@@ -1,4 +1,5 @@
|
|
|
1
1
|
import { IGlobalStore } from './global-store';
|
|
2
|
+
import { IPlatformConfigStore } from '../modules/platform-config';
|
|
2
3
|
/**
|
|
3
4
|
* 全局的状态管理工具类
|
|
4
5
|
*
|
|
@@ -15,5 +16,11 @@ export declare class GlobalStoreUtil {
|
|
|
15
16
|
*
|
|
16
17
|
*/
|
|
17
18
|
readonly store: IGlobalStore;
|
|
19
|
+
/**
|
|
20
|
+
* 全局平台配置状态管理实例
|
|
21
|
+
*
|
|
22
|
+
* @type {IPlatformConfigStore}
|
|
23
|
+
*/
|
|
24
|
+
readonly platformConfigStore: IPlatformConfigStore;
|
|
18
25
|
constructor();
|
|
19
26
|
}
|
package/es/store/index.mjs
CHANGED
|
@@ -1,4 +1,6 @@
|
|
|
1
1
|
import { useGlobalStore } from "./global-store.mjs";
|
|
2
|
+
import { usePlatformConfigStore } from "../modules/platform-config/store.mjs";
|
|
3
|
+
import "../modules/platform-config/index.mjs";
|
|
2
4
|
import { createPinia, setActivePinia } from "pinia";
|
|
3
5
|
//#region src/store/index.ts
|
|
4
6
|
/**
|
|
@@ -17,9 +19,16 @@ var GlobalStoreUtil = class {
|
|
|
17
19
|
*
|
|
18
20
|
*/
|
|
19
21
|
store;
|
|
22
|
+
/**
|
|
23
|
+
* 全局平台配置状态管理实例
|
|
24
|
+
*
|
|
25
|
+
* @type {IPlatformConfigStore}
|
|
26
|
+
*/
|
|
27
|
+
platformConfigStore;
|
|
20
28
|
constructor() {
|
|
21
29
|
setActivePinia(this.pinia);
|
|
22
30
|
this.store = useGlobalStore();
|
|
31
|
+
this.platformConfigStore = usePlatformConfigStore();
|
|
23
32
|
}
|
|
24
33
|
};
|
|
25
34
|
//#endregion
|
package/es/types/index.d.ts
CHANGED
|
@@ -6,6 +6,7 @@ import type { GctGlobal } from '../global';
|
|
|
6
6
|
import type { ApiManage as APaasApiManage } from '@gct-paas/api/apaas';
|
|
7
7
|
import type { ApiManage as PlatformApiManage } from '@gct-paas/api/platform';
|
|
8
8
|
import type { bus } from 'wujie';
|
|
9
|
+
// import type { ModuleFederation } from '@module-federation/runtime';
|
|
9
10
|
|
|
10
11
|
/**
|
|
11
12
|
* 全局 api 对象
|
|
@@ -28,6 +29,10 @@ declare global {
|
|
|
28
29
|
* paas 平台 API 管理
|
|
29
30
|
*/
|
|
30
31
|
const _api: GlobalApi;
|
|
32
|
+
/**
|
|
33
|
+
* 模块联邦运行时对象
|
|
34
|
+
*/
|
|
35
|
+
// const _mf: ModuleFederation;
|
|
31
36
|
|
|
32
37
|
interface Window {
|
|
33
38
|
/**
|
|
@@ -50,6 +55,12 @@ declare global {
|
|
|
50
55
|
* @type {*}
|
|
51
56
|
*/
|
|
52
57
|
$wujie: { props: IObject; bus: bus };
|
|
58
|
+
/**
|
|
59
|
+
* 模块联邦运行时对象
|
|
60
|
+
*
|
|
61
|
+
* @type {ModuleFederation}
|
|
62
|
+
*/
|
|
63
|
+
// _mf: ModuleFederation;
|
|
53
64
|
}
|
|
54
65
|
|
|
55
66
|
interface ImportMetaEnv {
|
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
import { getTenant, getTimezone, getToken
|
|
1
|
+
import { getTenant, getTimezone, getToken } from "../tools/tools.mjs";
|
|
2
2
|
import { AxiosHeaders } from "axios";
|
|
3
3
|
//#region src/utils/axios/interceptors.ts
|
|
4
4
|
/**
|
|
@@ -12,7 +12,6 @@ function interceptors(axios) {
|
|
|
12
12
|
if (!config.headers) config.headers = new AxiosHeaders();
|
|
13
13
|
Object.assign(config.headers, {
|
|
14
14
|
Token: getToken(),
|
|
15
|
-
Source: isMobile ? 502 : 501,
|
|
16
15
|
Lang: _gct.store.lang,
|
|
17
16
|
"Tenant-Id": getTenant(),
|
|
18
17
|
Timezone: getTimezone()
|