@gct-paas/core 0.1.5-dev.4 → 0.1.5-dev.6
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 -1
- package/es/index.mjs +2 -1
- package/es/interface/index.d.ts +0 -1
- package/es/interface/model-designer/entity.d.ts +87 -79
- package/es/locale/index.mjs +5 -1
- package/es/modules/platform-config/store.mjs +0 -1
- package/es/modules/user-stores/store/user.store.d.ts +7 -2
- package/es/modules/user-stores/store/user.store.mjs +15 -4
- package/es/router/index.mjs +2 -2
- package/es/setup-app.mjs +4 -3
- package/es/store/index.d.ts +1 -0
- package/es/store/index.mjs +1 -0
- package/es/store/session-store.d.ts +7 -0
- package/es/store/session-store.mjs +7 -0
- package/es/store/storage-store.d.ts +2 -0
- package/es/store/storage-store.mjs +3 -2
- package/es/types/index.d.ts +0 -1
- package/es/utils/kit-pkg-util/kit-pkg-util.mjs +2 -2
- package/es/utils/plugin-pkg-util/plugin-pkg-util.d.ts +1 -1
- package/es/utils/plugin-pkg-util/plugin-pkg-util.mjs +1 -1
- package/es/utils/tools/tools.d.ts +1 -1
- package/package.json +1 -1
- package/es/interface/i-import-style-map/i-import-style-map.d.ts +0 -15
package/es/index.mjs
CHANGED
|
@@ -81,6 +81,7 @@ import { WATERMARK_INIT_DATA } from "./modules/platform-config/constants/waterma
|
|
|
81
81
|
import { usePlatformConfigStore } from "./modules/platform-config/store.mjs";
|
|
82
82
|
import "./modules/platform-config/index.mjs";
|
|
83
83
|
import { globalRefStorage } from "./store/storage-store.mjs";
|
|
84
|
+
import { globalRefSession } from "./store/session-store.mjs";
|
|
84
85
|
import { GlobalStoreUtil } from "./store/index.mjs";
|
|
85
86
|
import { EnvironmentType } from "./modules/env-manager/env-manager.interface.mjs";
|
|
86
87
|
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";
|
|
@@ -131,4 +132,4 @@ function onInit() {
|
|
|
131
132
|
}
|
|
132
133
|
onInit();
|
|
133
134
|
//#endregion
|
|
134
|
-
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, KitPkgUtil, 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, PluginPgkUtil, PluginStaticResource, Postion, PrintModeEnums, PrintResourceEnum, PrintTypeEnum, ProcessStatusEnum, ProgressTypeEnum, ProjectName, PropGroup, REDIRECT_NAME, 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, 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, createWhiteImageWithText, cssLoader, dataURLtoBlob, deepMerge, downloadByBase64, downloadByData, downloadByOnlineUrl, downloadByUrl, emitFieldSet, fileUrlParser, fixedAlignENUM, functionGroup, functionMap, gctMemoizeAsync, genUrl, getDeviceFingerprint, getLoginTypeOptions, getMobileBrowserFingerprint, getOperatorList, getPageIdentification, getTenant, getToken, getVueComponentByCode, globalRefStorage, 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, transformUrl, typeParser, uploaderFiles, urlReg, urlToBase64, useAppInst, useCopyToClipboard, useIFrameProps, useModal, useNamespace, usePermissionStore, usePlatformConfigStore, useTenantStore, useUUid, useUserStore, useWuJieBus, useWuJieProps, uuid2, validateEmoji, validateIsModelName, validateModelName, zeroWidthSpace };
|
|
135
|
+
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, KitPkgUtil, 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, PluginPgkUtil, PluginStaticResource, Postion, PrintModeEnums, PrintResourceEnum, PrintTypeEnum, ProcessStatusEnum, ProgressTypeEnum, ProjectName, PropGroup, REDIRECT_NAME, 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, 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, createWhiteImageWithText, cssLoader, dataURLtoBlob, deepMerge, downloadByBase64, downloadByData, downloadByOnlineUrl, downloadByUrl, emitFieldSet, fileUrlParser, fixedAlignENUM, functionGroup, functionMap, gctMemoizeAsync, genUrl, getDeviceFingerprint, getLoginTypeOptions, getMobileBrowserFingerprint, getOperatorList, getPageIdentification, getTenant, getToken, getVueComponentByCode, globalRefSession, globalRefStorage, 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, transformUrl, typeParser, uploaderFiles, urlReg, urlToBase64, useAppInst, useCopyToClipboard, useIFrameProps, useModal, useNamespace, usePermissionStore, usePlatformConfigStore, useTenantStore, useUUid, useUserStore, useWuJieBus, useWuJieProps, uuid2, validateEmoji, validateIsModelName, validateModelName, zeroWidthSpace };
|
package/es/interface/index.d.ts
CHANGED
|
@@ -5,7 +5,6 @@ export type { IDictionaryItem } from './i-dictionary/i-dictionary-item';
|
|
|
5
5
|
export type { IFieldCodeChain } from './i-field-code-chain/i-field-code-chain';
|
|
6
6
|
export type { GlobalVar } from './i-global-var/i-global-var';
|
|
7
7
|
export type { IMobileHomeMenuItem } from './i-mobile-home-menu-item/i-mobile-home-menu-item';
|
|
8
|
-
export type { IStyleIMportMap } from './i-import-style-map/i-import-style-map';
|
|
9
8
|
export type { IPluginKitModule } from './i-kit-plugin-module/i-kit-plugin-module';
|
|
10
9
|
export type { IGlobalActions } from './i-pinia-action/i-global-actions';
|
|
11
10
|
export type { IGlobalGetters } from './i-pinia-getter/i-global-getters';
|
|
@@ -1,4 +1,78 @@
|
|
|
1
|
-
import { FIELD_TYPE, FieldDefaultValueTypeEnum, FieldSysVarDefaultValueEnum, UniqueConstraintType } from '../../enums';
|
|
1
|
+
import { EntityFormulaReturnTypeEnum, FIELD_TYPE, FieldDefaultValueTypeEnum, FieldSysVarDefaultValueEnum, UniqueConstraintType } from '../../enums';
|
|
2
|
+
export interface UniqueConstraint {
|
|
3
|
+
type: UniqueConstraintType;
|
|
4
|
+
fieldKeys?: string[];
|
|
5
|
+
}
|
|
6
|
+
export interface DefaultValueConfig {
|
|
7
|
+
type: FieldDefaultValueTypeEnum;
|
|
8
|
+
value?: string | number | boolean | FieldSysVarDefaultValueEnum;
|
|
9
|
+
name?: string;
|
|
10
|
+
}
|
|
11
|
+
export interface DisplayRuleConfig {
|
|
12
|
+
exp: string;
|
|
13
|
+
exprInEditor: string;
|
|
14
|
+
relationColumns: string[];
|
|
15
|
+
}
|
|
16
|
+
export interface ExpConfig {
|
|
17
|
+
exp: string;
|
|
18
|
+
expression: string;
|
|
19
|
+
relationColumns: string[];
|
|
20
|
+
nodes?: IObject[];
|
|
21
|
+
designJson?: IObject;
|
|
22
|
+
fieldKey?: string;
|
|
23
|
+
}
|
|
24
|
+
export interface AggConfig {
|
|
25
|
+
/** 汇总类型 */
|
|
26
|
+
aggFunc: string;
|
|
27
|
+
/** 汇总字段名 */
|
|
28
|
+
relationColumns: string[];
|
|
29
|
+
}
|
|
30
|
+
export interface RuleConfigDetail {
|
|
31
|
+
nodes: IObject[];
|
|
32
|
+
designJson: IObject;
|
|
33
|
+
fieldKey: string;
|
|
34
|
+
}
|
|
35
|
+
export interface CustomEnumConfig {
|
|
36
|
+
enabled: number;
|
|
37
|
+
values: string[];
|
|
38
|
+
}
|
|
39
|
+
export interface FormulaConfig {
|
|
40
|
+
exp: string;
|
|
41
|
+
expression: string;
|
|
42
|
+
showQrCode?: boolean;
|
|
43
|
+
digits?: number;
|
|
44
|
+
truelabel?: string;
|
|
45
|
+
falselabel?: string;
|
|
46
|
+
}
|
|
47
|
+
export interface FieldSpecificConfig {
|
|
48
|
+
minValue?: number;
|
|
49
|
+
maxValue?: number;
|
|
50
|
+
digits?: number;
|
|
51
|
+
true?: string;
|
|
52
|
+
false?: string;
|
|
53
|
+
/** 上传最大数量 */
|
|
54
|
+
maxNumber?: number;
|
|
55
|
+
/** 单文件大小限制 */
|
|
56
|
+
fileSize?: number;
|
|
57
|
+
/** 允许的文件类型 */
|
|
58
|
+
fileTypes?: string[];
|
|
59
|
+
/** 四舍五入规则 */
|
|
60
|
+
rulesForRounding?: number;
|
|
61
|
+
/** 流水号规则类型 */
|
|
62
|
+
ruleType?: string;
|
|
63
|
+
/** 显示规则 (人员、模型应用) */
|
|
64
|
+
displayRule?: DisplayRuleConfig;
|
|
65
|
+
ruleConfig?: RuleConfigDetail;
|
|
66
|
+
/** 返回值类型映射 */
|
|
67
|
+
mappingType?: EntityFormulaReturnTypeEnum;
|
|
68
|
+
expType?: string;
|
|
69
|
+
/** 是否实时计算 */
|
|
70
|
+
expRealCompute?: boolean;
|
|
71
|
+
expConfig?: ExpConfig;
|
|
72
|
+
formulaConfig?: FormulaConfig;
|
|
73
|
+
aggConfig?: AggConfig;
|
|
74
|
+
customEnumConfig?: CustomEnumConfig;
|
|
75
|
+
}
|
|
2
76
|
export interface FieldFormState {
|
|
3
77
|
id?: string;
|
|
4
78
|
modelKey: string;
|
|
@@ -7,102 +81,36 @@ export interface FieldFormState {
|
|
|
7
81
|
type: FIELD_TYPE;
|
|
8
82
|
required: number;
|
|
9
83
|
parentField?: number;
|
|
10
|
-
uniqueConstraint: {
|
|
11
|
-
type: UniqueConstraintType;
|
|
12
|
-
fieldKeys?: string[];
|
|
13
|
-
};
|
|
14
|
-
/** 默认值 */
|
|
15
|
-
defaultValue: {
|
|
16
|
-
type: FieldDefaultValueTypeEnum;
|
|
17
|
-
value?: string | number | boolean | FieldSysVarDefaultValueEnum;
|
|
18
|
-
name?: string;
|
|
19
|
-
};
|
|
20
84
|
description: string;
|
|
85
|
+
uniqueConstraint: UniqueConstraint;
|
|
86
|
+
/** 默认值配置 */
|
|
87
|
+
defaultValue: DefaultValueConfig;
|
|
21
88
|
/** 字段特性配置 */
|
|
22
|
-
specificConfig:
|
|
23
|
-
|
|
24
|
-
minValue?: number;
|
|
25
|
-
/**数值/长度限制 */
|
|
26
|
-
maxValue?: number;
|
|
27
|
-
/**数值精度 */
|
|
28
|
-
digits?: number;
|
|
29
|
-
/** 布尔 true 文案 */
|
|
30
|
-
true?: string;
|
|
31
|
-
/** 布尔 false 文案 */
|
|
32
|
-
false?: string;
|
|
33
|
-
/** 上传数量 */
|
|
34
|
-
maxNumber?: number;
|
|
35
|
-
/** 文件大小 */
|
|
36
|
-
fileSize?: number;
|
|
37
|
-
/** 文件类型 */
|
|
38
|
-
fileTypes?: string[];
|
|
39
|
-
ruleType?: string;
|
|
40
|
-
/** 显示规则 人员、模型应用 */
|
|
41
|
-
displayRule?: {
|
|
42
|
-
exp: string;
|
|
43
|
-
exprInEditor: string;
|
|
44
|
-
relationColumns: string[];
|
|
45
|
-
};
|
|
46
|
-
/**
|
|
47
|
-
* 公式新增参数
|
|
48
|
-
* 2024年11月21日
|
|
49
|
-
*/
|
|
50
|
-
expType?: string;
|
|
51
|
-
/**实时计算 */
|
|
52
|
-
expRealCompute?: boolean;
|
|
53
|
-
/** 公式配置 */
|
|
54
|
-
expConfig?: unknown | {
|
|
55
|
-
exp: string;
|
|
56
|
-
expression: string;
|
|
57
|
-
relationColumns: string[];
|
|
58
|
-
};
|
|
59
|
-
/** 汇总配置 */
|
|
60
|
-
aggConfig?: {
|
|
61
|
-
/** 汇总类型 */
|
|
62
|
-
aggFunc: string;
|
|
63
|
-
/** 汇总字段名 */
|
|
64
|
-
relationColumns: string[];
|
|
65
|
-
};
|
|
66
|
-
ruleConfig?: unknown | {
|
|
67
|
-
nodes: IObject[];
|
|
68
|
-
designJson: IObject;
|
|
69
|
-
fieldKey: string;
|
|
70
|
-
};
|
|
71
|
-
[k: string]: unknown;
|
|
72
|
-
/**枚举 */
|
|
73
|
-
customEnumConfig?: {
|
|
74
|
-
enabled: number;
|
|
75
|
-
values: string[];
|
|
76
|
-
};
|
|
77
|
-
/**前端公式 */
|
|
78
|
-
formulaConfig?: {
|
|
79
|
-
exp: string;
|
|
80
|
-
expression: string;
|
|
81
|
-
showQrCode?: boolean;
|
|
82
|
-
digits?: number;
|
|
83
|
-
truelabel?: string;
|
|
84
|
-
falselabel?: string;
|
|
85
|
-
};
|
|
86
|
-
};
|
|
87
|
-
/**关联信息KEY 如:枚举/主子/关联 */
|
|
89
|
+
specificConfig: FieldSpecificConfig;
|
|
90
|
+
/** 关联信息KEY 如:枚举/主子/关联 */
|
|
88
91
|
bindInfo?: string;
|
|
89
92
|
/** 主子/引用关联模型类型 */
|
|
90
93
|
refModelType?: string;
|
|
94
|
+
/** 多语言配置 */
|
|
91
95
|
i18nConfig?: string;
|
|
92
96
|
/**
|
|
93
|
-
*
|
|
97
|
+
* 普通数据类型值为 fieldType
|
|
94
98
|
* 映射类型(公式、函数等实际映射的类型)
|
|
95
99
|
*/
|
|
96
100
|
mappingType?: string;
|
|
97
|
-
/**
|
|
101
|
+
/** 主子关联:绑定子模型字段 */
|
|
98
102
|
bindFieldKey?: string;
|
|
99
103
|
/** 在线表单新建字段中的子模型key */
|
|
100
104
|
subModelKey?: string;
|
|
105
|
+
[key: string]: any;
|
|
101
106
|
}
|
|
102
107
|
export interface SpecificConfig {
|
|
108
|
+
/** 公式的表达式(key) */
|
|
103
109
|
exp?: string;
|
|
104
110
|
expression?: string;
|
|
111
|
+
/** 公式/汇总 关联的字段集合 */
|
|
105
112
|
relationColumns?: IObject[];
|
|
113
|
+
/** 汇总字段的枚举 */
|
|
106
114
|
aggFunc?: string;
|
|
107
115
|
bindField?: string;
|
|
108
116
|
refModelType?: string;
|
package/es/locale/index.mjs
CHANGED
|
@@ -1,6 +1,7 @@
|
|
|
1
1
|
import { globalRefStorage } from "../store/storage-store.mjs";
|
|
2
2
|
import "../store/index.mjs";
|
|
3
3
|
import { createI18n } from "vue-i18n";
|
|
4
|
+
import { HttpUtil } from "@gct-paas/api";
|
|
4
5
|
//#region src/locale/index.ts
|
|
5
6
|
var LocaleUtil = class {
|
|
6
7
|
localeList = [];
|
|
@@ -67,7 +68,10 @@ var LocaleUtil = class {
|
|
|
67
68
|
}
|
|
68
69
|
async loadMessages(url, locale = this.locale) {
|
|
69
70
|
if (!url) return;
|
|
70
|
-
const messages = (await (
|
|
71
|
+
const messages = (await HttpUtil.get(url, {}, {}, {}, {
|
|
72
|
+
headers: { "Content-Type": void 0 },
|
|
73
|
+
nativeData: true
|
|
74
|
+
})).split("\n").reduce((acc, item) => {
|
|
71
75
|
const [key, ...value] = item.split(":");
|
|
72
76
|
acc[key] = value.join(":");
|
|
73
77
|
return acc;
|
|
@@ -46,7 +46,6 @@ var usePlatformConfigStore = defineStore("platform-config", () => {
|
|
|
46
46
|
if (map[PlatformSettingEnum.THEME]) theme.setThemeSetting(map[PlatformSettingEnum.THEME]);
|
|
47
47
|
if (map[PlatformSettingEnum.WATERMARK]) watermark.setWatermarkSetting(map[PlatformSettingEnum.WATERMARK]);
|
|
48
48
|
if (map[PlatformSettingEnum.DEPLOY]) deploy.setDeploySetting(map[PlatformSettingEnum.DEPLOY]);
|
|
49
|
-
console.debug("平台配置初始化完成", map);
|
|
50
49
|
}
|
|
51
50
|
/**应用前台设置初始化 */
|
|
52
51
|
async function renderInit() {
|
|
@@ -290,13 +290,18 @@ export declare const useUserStore: import('pinia').StoreDefinition<"user", UserS
|
|
|
290
290
|
}, {
|
|
291
291
|
login(config: LoginParams, { hasError }?: {
|
|
292
292
|
hasError: any;
|
|
293
|
-
}): Promise<
|
|
293
|
+
}): Promise<UserLoginResp>;
|
|
294
294
|
getUserInfoAction(Token?: string): Promise<UserLoginResp | null>;
|
|
295
295
|
/**单应用登录 */
|
|
296
296
|
afterLoginSingleApp(): Promise<void>;
|
|
297
297
|
/**登录后逻辑 */
|
|
298
298
|
afterLoginAction(): Promise<null | undefined>;
|
|
299
|
-
|
|
299
|
+
/**退出登录 接口*/
|
|
300
|
+
submitLoginOut(): Promise<void>;
|
|
301
|
+
/**
|
|
302
|
+
* 清空对应信息
|
|
303
|
+
*/
|
|
304
|
+
appLoginOut(): Promise<void>;
|
|
300
305
|
setUserInfo(info: IObject): Promise<void>;
|
|
301
306
|
updateUserInfo(data: IObject): Promise<void>;
|
|
302
307
|
}>;
|
|
@@ -1,6 +1,9 @@
|
|
|
1
1
|
import { getTenant, getToken, setToken } from "../../../utils/tools/tools.mjs";
|
|
2
|
+
import { sha256 } from "../../../utils/uuid/uuid.mjs";
|
|
2
3
|
import { getDeviceFingerprint, getPageIdentification } from "../../../utils/deviceFingerprint.mjs";
|
|
3
4
|
import "../../../utils/index.mjs";
|
|
5
|
+
import { globalRefStorage } from "../../../store/storage-store.mjs";
|
|
6
|
+
import "../../../store/index.mjs";
|
|
4
7
|
import { defineStore } from "pinia";
|
|
5
8
|
//#region src/modules/user-stores/store/user.store.ts
|
|
6
9
|
var useUserStore = defineStore("user", {
|
|
@@ -26,9 +29,9 @@ var useUserStore = defineStore("user", {
|
|
|
26
29
|
async login(config, { hasError } = {}) {
|
|
27
30
|
try {
|
|
28
31
|
const { token, signWay } = await loginApi(config, hasError);
|
|
29
|
-
|
|
32
|
+
globalRefStorage.value.signWay = signWay || "";
|
|
30
33
|
setToken(token);
|
|
31
|
-
return this.
|
|
34
|
+
return this.getUserInfoAction(token);
|
|
32
35
|
} catch (error) {
|
|
33
36
|
return Promise.reject(error);
|
|
34
37
|
}
|
|
@@ -47,8 +50,13 @@ var useUserStore = defineStore("user", {
|
|
|
47
50
|
async afterLoginAction() {
|
|
48
51
|
if (!getToken) return null;
|
|
49
52
|
},
|
|
50
|
-
async
|
|
53
|
+
async submitLoginOut() {
|
|
51
54
|
await doLogout();
|
|
55
|
+
this.appLoginOut();
|
|
56
|
+
},
|
|
57
|
+
async appLoginOut() {
|
|
58
|
+
setToken();
|
|
59
|
+
this.setUserInfo({});
|
|
52
60
|
},
|
|
53
61
|
async setUserInfo(info) {
|
|
54
62
|
this.userInfo = {
|
|
@@ -75,7 +83,10 @@ var useUserStore = defineStore("user", {
|
|
|
75
83
|
*/
|
|
76
84
|
async function loginApi(params, { hasError = true } = {}) {
|
|
77
85
|
const fingerprint = await getDeviceFingerprint();
|
|
78
|
-
return await _api.platform.login.postSign(
|
|
86
|
+
return await _api.platform.login.postSign({
|
|
87
|
+
...params,
|
|
88
|
+
password: sha256(params.password || "")
|
|
89
|
+
}, { headers: {
|
|
79
90
|
browser: fingerprint,
|
|
80
91
|
"Auth-Code": params.authCode,
|
|
81
92
|
hasError
|
package/es/router/index.mjs
CHANGED
|
@@ -16,9 +16,9 @@ var RouterUtil = class {
|
|
|
16
16
|
* @description 将单个或多个路由记录添加到路由器中
|
|
17
17
|
*/
|
|
18
18
|
async add(route) {
|
|
19
|
-
if (Array.isArray(route)) route.forEach((r) => this.
|
|
19
|
+
if (Array.isArray(route)) route.forEach((r) => this.router.addRoute(r));
|
|
20
20
|
else this.router.addRoute(route);
|
|
21
|
-
await this.router.replace(this.router.currentRoute.value.fullPath);
|
|
21
|
+
if (!this.router.hasRoute(this.router.currentRoute.value.name)) await this.router.replace(this.router.currentRoute.value.fullPath);
|
|
22
22
|
}
|
|
23
23
|
/**刷新当前路由 */
|
|
24
24
|
async redo() {
|
package/es/setup-app.mjs
CHANGED
|
@@ -16,10 +16,11 @@ import { HttpUtil } from "@gct-paas/api";
|
|
|
16
16
|
async function setupApp(_app) {
|
|
17
17
|
HttpUtil.use(interceptors);
|
|
18
18
|
await _gct.init();
|
|
19
|
-
const token = getToken();
|
|
20
|
-
console.log("setupApp", token);
|
|
21
|
-
if (token) await useUserStore().getUserInfoAction(token);
|
|
22
19
|
await usePlatformConfigStore().init();
|
|
20
|
+
const token = getToken();
|
|
21
|
+
if (token) try {
|
|
22
|
+
await useUserStore().getUserInfoAction(token);
|
|
23
|
+
} catch {}
|
|
23
24
|
}
|
|
24
25
|
//#endregion
|
|
25
26
|
export { setupApp };
|
package/es/store/index.d.ts
CHANGED
package/es/store/index.mjs
CHANGED
|
@@ -2,6 +2,7 @@ import { useGlobalStore } from "./global-store.mjs";
|
|
|
2
2
|
import { usePlatformConfigStore } from "../modules/platform-config/store.mjs";
|
|
3
3
|
import "../modules/platform-config/index.mjs";
|
|
4
4
|
import "./storage-store.mjs";
|
|
5
|
+
import "./session-store.mjs";
|
|
5
6
|
import { createPinia, setActivePinia } from "pinia";
|
|
6
7
|
//#region src/store/index.ts
|
|
7
8
|
/**
|
|
@@ -2,9 +2,10 @@ import { useStorage } from "@vueuse/core";
|
|
|
2
2
|
/**
|
|
3
3
|
* 全局双向绑定持续化缓存Map
|
|
4
4
|
*/
|
|
5
|
-
var globalRefStorage = useStorage("
|
|
5
|
+
var globalRefStorage = useStorage("GCT_GLOBAL_STORAGE:PAAS", {
|
|
6
6
|
timezone: "UTC+08:00",
|
|
7
|
-
lang: ""
|
|
7
|
+
lang: "",
|
|
8
|
+
signWay: ""
|
|
8
9
|
});
|
|
9
10
|
//#endregion
|
|
10
11
|
export { globalRefStorage };
|
package/es/types/index.d.ts
CHANGED
|
@@ -26,13 +26,13 @@ var KitPkgUtil = class {
|
|
|
26
26
|
* @return {*} {(Promise<IPluginKitModule | null>)}
|
|
27
27
|
*/
|
|
28
28
|
static async loadKit(kit, mode) {
|
|
29
|
-
const loaderUrl = this.joinPaths(this.KIT_PKG_BASE_PATH, kit, mode,
|
|
29
|
+
const loaderUrl = this.joinPaths(this.KIT_PKG_BASE_PATH, kit, mode, "loader.esm.min.js");
|
|
30
30
|
try {
|
|
31
31
|
const module = await import(
|
|
32
32
|
/* @vite-ignore */
|
|
33
33
|
loaderUrl
|
|
34
34
|
);
|
|
35
|
-
if (module
|
|
35
|
+
if (module) return module;
|
|
36
36
|
else console.warn(`Kit ${kit} does not export a default function`);
|
|
37
37
|
} catch (error) {
|
|
38
38
|
console.error(`Error loading kit ${kit} from ${loaderUrl}:`, error);
|
|
@@ -47,7 +47,7 @@ export declare class PluginPgkUtil {
|
|
|
47
47
|
* @protected
|
|
48
48
|
* @static
|
|
49
49
|
* @param {IStyleIMportMap[]} plugins
|
|
50
|
-
* @returns {*} {Promise<
|
|
50
|
+
* @returns {*} {Promise<IObject[]>}
|
|
51
51
|
*/
|
|
52
52
|
protected static loadPlugins(mode: PluginModeEnum, configs?: PluginTenant['plugins']): Promise<IModuleMap>;
|
|
53
53
|
/**
|
|
@@ -60,7 +60,7 @@ var PluginPgkUtil = class {
|
|
|
60
60
|
* @protected
|
|
61
61
|
* @static
|
|
62
62
|
* @param {IStyleIMportMap[]} plugins
|
|
63
|
-
* @returns {*} {Promise<
|
|
63
|
+
* @returns {*} {Promise<IObject[]>}
|
|
64
64
|
*/
|
|
65
65
|
static async loadPlugins(mode, configs = []) {
|
|
66
66
|
const moduleMap = {};
|
package/package.json
CHANGED
|
@@ -1,15 +0,0 @@
|
|
|
1
|
-
/**
|
|
2
|
-
* systemjs 扩展样式模块加载声明
|
|
3
|
-
*
|
|
4
|
-
* @export
|
|
5
|
-
* @interface IStyleIMportMap
|
|
6
|
-
* @extends {System.ImportMap}
|
|
7
|
-
*/
|
|
8
|
-
export interface IStyleIMportMap extends System.ImportMap {
|
|
9
|
-
/**
|
|
10
|
-
* 样式静态资源相对或者绝对路径与 imports 里边对应,会在加载 import 脚本时,自动加载样式文件
|
|
11
|
-
*
|
|
12
|
-
* @type {(Record<string, string[] | string>)}
|
|
13
|
-
*/
|
|
14
|
-
styles?: Record<string, string[] | string>;
|
|
15
|
-
}
|