@gct-paas/core 0.1.4-dev.0 → 0.1.4-dev.10
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.mjs +8101 -0
- package/dist/index.min.cjs +386 -1
- package/dist/index.system.min.js +386 -1
- package/es/constants/core.mjs +0 -1
- package/es/constants/editor-register/editor-register.mjs +0 -1
- package/es/constants/editor-type/editor-type.d.ts +65 -1
- package/es/constants/editor-type/editor-type.mjs +14 -1
- package/es/constants/expression-type/BuiltOperators.d.ts +20 -0
- package/es/constants/expression-type/BuiltOperators.mjs +149 -0
- package/es/constants/expression-type/FunctionKeys.d.ts +1 -0
- package/es/constants/expression-type/FunctionKeys.mjs +81 -0
- package/es/constants/expression-type/editor.d.ts +8 -0
- package/es/constants/expression-type/editor.mjs +4 -0
- package/es/constants/expression-type/function.d.ts +7 -0
- package/es/constants/expression-type/function.mjs +875 -0
- package/es/constants/expression-type/index.d.ts +42 -0
- package/es/constants/expression-type/index.mjs +120 -0
- package/es/constants/expression-type/modeCfg.d.ts +30 -0
- package/es/constants/expression-type/modeCfg.mjs +268 -0
- package/es/constants/expression-type/variable.d.ts +12 -0
- package/es/constants/expression-type/variable.mjs +42 -0
- package/es/constants/form-container-type/form-container-type.mjs +0 -1
- package/es/constants/index.d.ts +9 -0
- package/es/constants/index.mjs +7 -6
- package/es/controller/edit-form/edit-form.controller.mjs +0 -1
- package/es/controller/editor/color-editor.controller.mjs +0 -1
- package/es/controller/editor/length-unit-editor.controller.mjs +0 -1
- package/es/controller/editor-item/editor-item.controller.mjs +0 -1
- package/es/controller/form/form.controller.mjs +5 -5
- package/es/controller/form-collapse/form-collapse.controller.mjs +4 -3
- package/es/controller/form-collapse-pane/form-collapse-pane.controller.mjs +4 -3
- package/es/controller/form-edit-item/form-edit-item.controller.d.ts +1 -0
- package/es/controller/form-edit-item/form-edit-item.controller.mjs +6 -2
- package/es/controller/form-group/form-group.controller.mjs +4 -3
- package/es/controller/form-item/form-item.controller.d.ts +1 -0
- package/es/controller/form-item/form-item.controller.mjs +7 -3
- package/es/controller/form-item-basic/form-item-basic.controller.mjs +3 -2
- package/es/controller/form-item-hidden/form-item-hidden.controller.mjs +0 -1
- package/es/controller/form-tab/form-tab.controller.mjs +4 -3
- package/es/controller/form-tab-pane/form-tab-pane.controller.mjs +4 -3
- package/es/controller/gct-form/gct-form.controller.mjs +5 -5
- package/es/create-app-vue.d.ts +8 -0
- package/es/create-app-vue.mjs +12 -0
- package/es/enums/app-designer/index.d.ts +13 -1
- package/es/enums/app-designer/index.mjs +8 -2
- package/es/enums/appEnum.d.ts +22 -66
- package/es/enums/appEnum.mjs +24 -15
- package/es/enums/appStateEnum.mjs +0 -1
- package/es/enums/authActionEnum.mjs +0 -1
- package/es/enums/breakpointEnum.mjs +0 -1
- package/es/enums/cacheEnum.mjs +0 -1
- package/es/enums/designEnum.d.ts +9 -3
- package/es/enums/designEnum.mjs +34 -32
- package/es/enums/developer-center/index.d.ts +1 -0
- package/es/enums/developer-center/integration.d.ts +4 -0
- package/es/enums/developer-center/integration.mjs +7 -0
- package/es/enums/exceptionEnum.mjs +0 -1
- package/es/enums/expressionEnum.d.ts +130 -0
- package/es/enums/expressionEnum.mjs +75 -0
- package/es/enums/globalEnum.d.ts +38 -0
- package/es/enums/globalEnum.mjs +25 -0
- package/es/enums/httpEnum.mjs +0 -1
- package/es/enums/index.d.ts +19 -0
- package/es/enums/index.mjs +13 -20
- package/es/enums/menuEnum.mjs +0 -1
- package/es/enums/page-designer/designer.d.ts +23 -3
- package/es/enums/page-designer/designer.mjs +90 -6
- package/es/enums/page-designer/panel.d.ts +78 -7
- package/es/enums/page-designer/panel.mjs +22 -4
- package/es/enums/page-designer/toolkit.mjs +0 -1
- package/es/enums/page-designer/widget.d.ts +2 -1
- package/es/enums/page-designer/widget.mjs +3 -3
- package/es/enums/pageEnum.mjs +0 -1
- package/es/enums/plugin-enum.mjs +0 -1
- package/es/enums/processEnum.d.ts +54 -0
- package/es/enums/processEnum.mjs +36 -2
- package/es/enums/roleEnum.mjs +0 -1
- package/es/enums/sizeEnum.mjs +0 -1
- package/es/global/gct/gct.d.ts +39 -25
- package/es/global/gct/gct.mjs +49 -27
- package/es/hooks/index.d.ts +2 -1
- package/es/hooks/use-app-inst/use-app-inst.d.ts +8 -0
- package/es/hooks/use-app-inst/use-app-inst.mjs +8 -0
- package/es/hooks/use-form/use-form.mjs +0 -1
- package/es/hooks/use-gct-form-value/use-gct-form-value.d.ts +1 -1
- package/es/hooks/use-gct-form-value/use-gct-form-value.mjs +0 -4
- package/es/hooks/use-modal/use-modal.mjs +0 -1
- package/es/hooks/use-overlay-scrollbars/use-overlay-scrollbars.d.ts +11 -0
- package/es/hooks/use-sub-app-utils/use-sub-app-utils.d.ts +27 -0
- package/es/hooks/use-sub-app-utils/use-sub-app-utils.mjs +30 -0
- package/es/hooks/useCopyToClipboard.mjs +0 -1
- package/es/index.d.ts +7 -9
- package/es/index.mjs +94 -48
- package/es/interface/controller/form-edit-item/form-edit-item.controller.d.ts +5 -0
- package/es/interface/controller/index.d.ts +0 -1
- package/es/interface/form/i-editor/i-editor-basic.d.ts +2 -2
- package/es/interface/form/i-editor/i-model-field-select-editor.d.ts +18 -0
- package/es/interface/form/i-form/i-form-collapse-pane.d.ts +4 -0
- package/es/interface/form/i-form/i-form-item-basic.d.ts +1 -1
- package/es/interface/form/i-form/i-form-tab-pane.d.ts +4 -0
- package/es/interface/form/index.d.ts +1 -0
- package/es/interface/i-app-context/i-app-context.d.ts +34 -0
- package/es/interface/i-field-code-chain/i-field-code-chain.d.ts +17 -0
- package/es/interface/i-global-var/i-global-var.d.ts +15 -0
- package/es/interface/i-mobile-home-menu-item/i-mobile-home-menu-item.d.ts +94 -0
- package/es/interface/i-pinia-action/i-global-actions.d.ts +7 -4
- package/es/interface/i-pinia-getter/i-global-getters.d.ts +1 -5
- package/es/interface/i-pinia-state/i-global-state.d.ts +7 -2
- package/es/interface/index.d.ts +5 -6
- package/es/interface/open-util/i-message-util/i-message-util.d.ts +54 -0
- package/es/interface/{i-modal → open-util/i-modal}/i-modal.d.ts +9 -10
- package/es/interface/{i-modal-data → open-util/i-modal-data}/i-modal-data.d.ts +6 -0
- package/es/interface/open-util/i-modal-options/i-modal-options.d.ts +12 -0
- package/es/interface/open-util/i-open-window-options/i-open-window-options.d.ts +59 -0
- package/es/interface/open-util/i-overlay-container/i-overlay-container.d.ts +36 -0
- package/es/interface/open-util/i-overlay-controller/i-overlay-controller.d.ts +36 -0
- package/es/interface/open-util/index.d.ts +7 -0
- package/es/interface/state/index.d.ts +0 -1
- package/es/locale/index.d.ts +19 -0
- package/es/locale/index.mjs +60 -0
- package/es/modules/env-manager/env-manager.const.d.ts +14 -0
- package/es/modules/env-manager/env-manager.const.mjs +9 -0
- package/es/modules/env-manager/env-manager.d.ts +59 -0
- package/es/modules/env-manager/env-manager.interface.d.ts +43 -0
- package/es/modules/env-manager/env-manager.interface.mjs +8 -0
- package/es/modules/env-manager/env-manager.mjs +108 -0
- package/es/modules/env-manager/index.d.ts +3 -0
- package/es/modules/error-handler/error-handler.const.d.ts +48 -0
- package/es/modules/error-handler/error-handler.const.mjs +18 -0
- package/es/modules/error-handler/error-handler.interface.d.ts +51 -0
- package/es/modules/error-handler/error-strategy.d.ts +138 -0
- package/es/modules/error-handler/error-strategy.mjs +175 -0
- package/es/modules/error-handler/index.d.ts +78 -0
- package/es/modules/error-handler/index.mjs +108 -0
- package/es/modules/platform-config/constants/index.d.ts +7 -0
- package/es/modules/platform-config/constants/login.const.d.ts +15 -0
- package/es/modules/platform-config/constants/login.const.mjs +50 -0
- package/es/modules/platform-config/constants/org.const.d.ts +9 -0
- package/es/modules/platform-config/constants/org.const.mjs +54 -0
- package/es/modules/platform-config/constants/theme.const.d.ts +9 -0
- package/es/modules/platform-config/constants/theme.const.mjs +5 -0
- package/es/modules/platform-config/constants/watermark.const.d.ts +16 -0
- package/es/modules/platform-config/constants/watermark.const.mjs +14 -0
- package/es/modules/platform-config/enums/deploy.enum.d.ts +10 -0
- package/es/modules/platform-config/enums/deploy.enum.mjs +7 -0
- package/es/modules/platform-config/enums/index.d.ts +6 -0
- package/es/modules/platform-config/enums/login.enum.d.ts +25 -0
- package/es/modules/platform-config/enums/login.enum.mjs +16 -0
- package/es/modules/platform-config/enums/platform.enum.d.ts +27 -0
- package/es/modules/platform-config/enums/platform.enum.mjs +26 -0
- package/es/modules/platform-config/index.d.ts +8 -0
- package/es/modules/platform-config/interfaces/global-setting.interface.d.ts +7 -0
- package/es/modules/platform-config/interfaces/index.d.ts +7 -0
- package/es/modules/platform-config/interfaces/login-config.interface.d.ts +17 -0
- package/es/modules/platform-config/interfaces/platform-map.interface.d.ts +8 -0
- package/es/modules/platform-config/interfaces/theme-setting.interface.d.ts +30 -0
- package/es/modules/platform-config/store.d.ts +221 -0
- package/es/modules/platform-config/store.mjs +78 -0
- package/es/modules/platform-config/useBasicSetting.d.ts +11 -0
- package/es/modules/platform-config/useBasicSetting.mjs +39 -0
- package/es/modules/platform-config/useDeploySetting.d.ts +19 -0
- package/es/modules/platform-config/useDeploySetting.mjs +27 -0
- package/es/modules/platform-config/useLoginSetting.d.ts +15 -0
- package/es/modules/platform-config/useLoginSetting.mjs +177 -0
- package/es/modules/platform-config/useOrgSetting.d.ts +34 -0
- package/es/modules/platform-config/useOrgSetting.mjs +66 -0
- package/es/modules/platform-config/useProjectSetting.d.ts +12 -0
- package/es/modules/platform-config/useProjectSetting.mjs +11 -0
- package/es/modules/platform-config/useSecuritySetting.d.ts +11 -0
- package/es/modules/platform-config/useSecuritySetting.mjs +60 -0
- package/es/modules/platform-config/useThemeSetting.d.ts +16 -0
- package/es/modules/platform-config/useThemeSetting.mjs +64 -0
- package/es/modules/platform-config/useWatermarkSetting.d.ts +21 -0
- package/es/modules/platform-config/useWatermarkSetting.mjs +26 -0
- package/es/modules/user-stores/index.d.ts +3 -0
- package/es/modules/user-stores/store/permission.store.d.ts +21 -0
- package/es/modules/user-stores/store/permission.store.mjs +38 -0
- package/es/modules/user-stores/store/tenant.store.d.ts +9 -0
- package/es/modules/user-stores/store/tenant.store.mjs +24 -0
- package/es/modules/user-stores/store/user.store.d.ts +154 -0
- package/es/modules/user-stores/store/user.store.mjs +108 -0
- package/es/modules/user-stores/types/permission.d.ts +1 -0
- package/es/modules/user-stores/types/tenant.d.ts +1 -0
- package/es/modules/user-stores/types/user.d.ts +14 -0
- package/es/register/editor-register/editor-register.d.ts +5 -13
- package/es/register/editor-register/editor-register.mjs +8 -17
- package/es/register/form-item-register/form-item-register.d.ts +4 -15
- package/es/register/form-item-register/form-item-register.mjs +7 -17
- package/es/register/index.d.ts +12 -2
- package/es/router/index.d.ts +13 -0
- package/es/router/index.mjs +31 -0
- package/es/setup-app.d.ts +8 -0
- package/es/setup-app.mjs +31 -0
- package/es/state/form/form.state.mjs +0 -1
- package/es/state/form-collapse/form-collapse.state.mjs +0 -1
- package/es/state/form-collapse-pane/form-collapse-pane.state.mjs +0 -1
- package/es/state/form-edit-item/form-edit-item.state.mjs +0 -1
- package/es/state/form-group/form-group.state.mjs +0 -1
- package/es/state/form-item/form-item.state.mjs +0 -1
- package/es/state/form-item-basic/form-item-basic.state.mjs +0 -1
- package/es/state/form-tab/form-tab.state.mjs +0 -1
- package/es/state/form-tab-pane/form-tab-pane.state.mjs +0 -1
- package/es/state/global-pinia-state/global-pinia-state.d.ts +8 -13
- package/es/state/global-pinia-state/global-pinia-state.mjs +35 -9
- package/es/store/global-store.d.ts +1 -0
- package/es/store/global-store.mjs +38 -9
- package/es/store/index.d.ts +2 -3
- package/es/store/index.mjs +0 -1
- package/es/types/index.d.ts +51 -1
- package/es/utils/axios/interceptors.mjs +2 -23
- package/es/utils/cache-adapter/cache-adapter.d.ts +2 -0
- package/es/utils/cache-adapter/cache-adapter.mjs +59 -0
- package/es/utils/deviceFingerprint.d.ts +17 -0
- package/es/utils/deviceFingerprint.mjs +73 -0
- package/es/utils/dictionary/dictionary.mjs +0 -1
- package/es/utils/i18n/index.d.ts +2 -1
- package/es/utils/i18n/index.mjs +3 -4
- package/es/utils/index.d.ts +20 -4
- package/es/utils/is-sort-filed/is-sort-filed.d.ts +10 -0
- package/es/utils/is-sort-filed/is-sort-filed.mjs +40 -0
- package/es/utils/linked-list/linked-list.d.ts +72 -0
- package/es/utils/linked-list/linked-list.mjs +119 -0
- package/es/utils/linked-node/linked-node.d.ts +31 -0
- package/es/utils/linked-node/linked-node.mjs +32 -0
- package/es/utils/lowcode/utils.d.ts +1 -0
- package/es/utils/lowcode/utils.mjs +20 -0
- package/es/utils/lowcode/validate.d.ts +13 -0
- package/es/utils/lowcode/validate.mjs +29 -0
- package/es/utils/mitt/mitt.d.ts +1 -0
- package/es/utils/mitt/mitt.mjs +5 -0
- package/es/utils/model-loader/model-loader.d.ts +118 -0
- package/es/utils/model-loader/model-loader.mjs +326 -0
- package/es/utils/namespace/namespace.d.ts +8 -0
- package/es/utils/namespace/namespace.mjs +4 -2
- package/es/utils/openUtil/index.d.ts +2 -0
- package/es/utils/openUtil/modal/modal.d.ts +61 -0
- package/es/utils/openUtil/modal/modal.mjs +80 -0
- package/es/utils/openUtil/overlay-container/overlay-container.d.ts +100 -0
- package/es/utils/openUtil/overlay-container/overlay-container.mjs +139 -0
- package/es/utils/plugin-static-resource/plugin-static-resource.mjs +1 -2
- package/es/utils/props/gct-form-item/gct-form-item.props.d.ts +63 -0
- package/es/utils/props/gct-form-item/gct-form-item.props.mjs +66 -0
- package/es/utils/props/index.d.ts +1 -0
- package/es/utils/style/index.d.ts +16 -0
- package/es/utils/style/index.mjs +141 -0
- package/es/utils/tools/tools.d.ts +23 -21
- package/es/utils/tools/tools.mjs +37 -27
- package/es/utils/treeHelper/treeHelper.d.ts +118 -0
- package/es/utils/treeHelper/treeHelper.mjs +234 -0
- package/es/utils/useUUid.d.ts +41 -0
- package/es/utils/useUUid.mjs +93 -0
- package/es/utils/util.d.ts +39 -0
- package/es/utils/util.mjs +40 -0
- package/es/utils/uuid/uuid.d.ts +3 -0
- package/es/utils/uuid/uuid.mjs +48 -0
- package/es/utils/value-helper/value-helper.d.ts +49 -0
- package/es/utils/value-helper/value-helper.mjs +111 -0
- package/es/utils/width-install/width-install.mjs +4 -2
- package/package.json +41 -22
- package/es/_virtual/_commonjsHelpers.mjs +0 -44
- package/es/_virtual/index.mjs +0 -7
- package/es/controller/index.mjs +0 -17
- package/es/enums/page-designer/index.mjs +0 -6
- package/es/global/index.mjs +0 -3
- package/es/hooks/index.mjs +0 -7
- package/es/hooks/use-namespace/use-namespace.d.ts +0 -9
- package/es/hooks/use-namespace/use-namespace.mjs +0 -9
- package/es/interface/controller/edit-form/edit-form.controller.mjs +0 -1
- package/es/interface/controller/editor/i-color-editor.controller.mjs +0 -1
- package/es/interface/controller/editor/i-length-unit-editor.controller.mjs +0 -1
- package/es/interface/controller/editor-item/editor-item.controller.mjs +0 -1
- package/es/interface/controller/form/form.controller.mjs +0 -3
- package/es/interface/controller/form-collapse/form-collapse.controller.mjs +0 -1
- package/es/interface/controller/form-collapse-pane/form-collapse-pane.controller.mjs +0 -1
- package/es/interface/controller/form-edit-item/form-edit-item.controller.mjs +0 -1
- package/es/interface/controller/form-group/form-group.controller.mjs +0 -1
- package/es/interface/controller/form-hidden-item/form-hidden-item.controller.mjs +0 -1
- package/es/interface/controller/form-item/form-item.controller.mjs +0 -1
- package/es/interface/controller/form-item-basic/form-item-basic.controller.mjs +0 -1
- package/es/interface/controller/form-tab/form-tab.controller.mjs +0 -1
- package/es/interface/controller/form-tab-pane/form-tab-pane.controller.mjs +0 -1
- package/es/interface/controller/i-designer-controller.d.ts +0 -116
- package/es/interface/controller/i-designer-controller.mjs +0 -1
- package/es/interface/controller/index.mjs +0 -1
- package/es/interface/events/form/i-form.event.mjs +0 -1
- package/es/interface/events/index.mjs +0 -1
- package/es/interface/form/i-editor/i-check-switch.mjs +0 -3
- package/es/interface/form/i-editor/i-checkbox-editor.mjs +0 -3
- package/es/interface/form/i-editor/i-color-editor.mjs +0 -3
- package/es/interface/form/i-editor/i-editor-basic.mjs +0 -1
- package/es/interface/form/i-editor/i-icon-select-editor.mjs +0 -3
- package/es/interface/form/i-editor/i-info-editor.mjs +0 -3
- package/es/interface/form/i-editor/i-length-unit-editor.mjs +0 -3
- package/es/interface/form/i-editor/i-number-editor.mjs +0 -3
- package/es/interface/form/i-editor/i-picker-editor.mjs +0 -3
- package/es/interface/form/i-editor/i-radio-editor.mjs +0 -3
- package/es/interface/form/i-editor/i-select-editor.mjs +0 -3
- package/es/interface/form/i-editor/i-span-editor.mjs +0 -3
- package/es/interface/form/i-editor/i-switch-editor.mjs +0 -3
- package/es/interface/form/i-editor/i-text-editor.mjs +0 -3
- package/es/interface/form/i-editor/i-textarea-editor.mjs +0 -3
- package/es/interface/form/i-form/i-edit-form.mjs +0 -1
- package/es/interface/form/i-form/i-form-collapse-pane.mjs +0 -1
- package/es/interface/form/i-form/i-form-collapse.mjs +0 -1
- package/es/interface/form/i-form/i-form-container.mjs +0 -1
- package/es/interface/form/i-form/i-form-edit-item.mjs +0 -1
- package/es/interface/form/i-form/i-form-group-container.mjs +0 -1
- package/es/interface/form/i-form/i-form-group.mjs +0 -1
- package/es/interface/form/i-form/i-form-hidden-item.mjs +0 -1
- package/es/interface/form/i-form/i-form-item-basic.mjs +0 -1
- package/es/interface/form/i-form/i-form-item.mjs +0 -1
- package/es/interface/form/i-form/i-form-tab-pane.mjs +0 -1
- package/es/interface/form/i-form/i-form-tab.mjs +0 -1
- package/es/interface/form/i-form/i-form.mjs +0 -1
- package/es/interface/form/index.mjs +0 -1
- package/es/interface/hooks/i-designer-hooks.d.ts +0 -26
- package/es/interface/hooks/i-designer-hooks.mjs +0 -3
- package/es/interface/hooks/index.d.ts +0 -1
- package/es/interface/hooks/index.mjs +0 -1
- package/es/interface/i-dictionary/i-dictionary-item.mjs +0 -1
- package/es/interface/i-dictionary/i-dictionary.mjs +0 -1
- package/es/interface/i-http-response/i-http-response.d.ts +0 -29
- package/es/interface/i-http-response/i-http-response.mjs +0 -1
- package/es/interface/i-import-style-map/i-import-style-map.mjs +0 -1
- package/es/interface/i-message-util/i-message-util.d.ts +0 -78
- package/es/interface/i-message-util/i-message-util.mjs +0 -1
- package/es/interface/i-modal/i-modal.mjs +0 -3
- package/es/interface/i-modal-data/i-modal-data.mjs +0 -1
- package/es/interface/i-pinia-action/i-global-actions.mjs +0 -1
- package/es/interface/i-pinia-getter/i-global-getters.mjs +0 -1
- package/es/interface/i-pinia-state/i-global-state.mjs +0 -1
- package/es/interface/index.mjs +0 -1
- package/es/interface/layout/i-flex-layout/i-flex-container.mjs +0 -1
- package/es/interface/layout/i-flex-layout/i-flex-item.mjs +0 -1
- package/es/interface/layout/i-grid-layout/i-grid-container.mjs +0 -1
- package/es/interface/layout/i-grid-layout/i-grid-item-span.mjs +0 -1
- package/es/interface/layout/i-grid-layout/i-grid-item.mjs +0 -1
- package/es/interface/layout/i-layout-basis/i-layout-container-basis.mjs +0 -1
- package/es/interface/layout/index.mjs +0 -1
- package/es/interface/low-code-types/index.d.ts +0 -4
- package/es/interface/low-code-types/index.mjs +0 -5
- package/es/interface/low-code-types/modal-types.d.ts +0 -67
- package/es/interface/low-code-types/modal-types.mjs +0 -3
- package/es/interface/low-code-types/model/index.d.ts +0 -5338
- package/es/interface/low-code-types/model/index.mjs +0 -1
- package/es/interface/low-code-types/schema/index.d.ts +0 -12
- package/es/interface/low-code-types/schema/index.mjs +0 -1
- package/es/interface/low-code-types/widget-basic-types.d.ts +0 -667
- package/es/interface/low-code-types/widget-basic-types.mjs +0 -3
- package/es/interface/provider/i-editor-provider/i-editor-provider.mjs +0 -1
- package/es/interface/provider/i-form-item-provider/i-form-item-provider.mjs +0 -1
- package/es/interface/provider/i-provider-basic/i-provider-basic.mjs +0 -1
- package/es/interface/provider/index.mjs +0 -1
- package/es/interface/state/form/form.state.mjs +0 -1
- package/es/interface/state/form-collapse/form-collapse.state.mjs +0 -1
- package/es/interface/state/form-collapse-pane/form-collapse-pane.state.mjs +0 -1
- package/es/interface/state/form-edit-item/form-edit-item.state.mjs +0 -1
- package/es/interface/state/form-group/form-group.state.mjs +0 -1
- package/es/interface/state/form-hidden-item/form-hidden-item.state.mjs +0 -1
- package/es/interface/state/form-item/form-item.state.mjs +0 -1
- package/es/interface/state/form-item-basic/form-item-basic.state.mjs +0 -1
- package/es/interface/state/form-tab/form-tab.state.mjs +0 -1
- package/es/interface/state/form-tab-pane/form-tab-pane.state.mjs +0 -1
- package/es/interface/state/i-designer-state.d.ts +0 -27
- package/es/interface/state/i-designer-state.mjs +0 -1
- package/es/interface/state/index.mjs +0 -1
- package/es/interface/style/i-border.mjs +0 -1
- package/es/interface/style/i-font.mjs +0 -1
- package/es/interface/style/i-margin.mjs +0 -1
- package/es/interface/style/i-padding.mjs +0 -1
- package/es/interface/style/i-position.mjs +0 -1
- package/es/interface/style/i-spacing.mjs +0 -1
- package/es/interface/style/index.mjs +0 -1
- package/es/node_modules/.pnpm/path-browserify@1.0.1/node_modules/path-browserify/index.mjs +0 -541
- package/es/node_modules/.pnpm/qx-util@0.4.8/node_modules/qx-util/out/hook/async-series-hook/async-series-hook.mjs +0 -73
- package/es/node_modules/.pnpm/qx-util@0.4.8/node_modules/qx-util/out/hook/index.mjs +0 -2
- package/es/node_modules/.pnpm/qx-util@0.4.8/node_modules/qx-util/out/hook/sync-series-hook/sync-series-hook.mjs +0 -100
- package/es/node_modules/.pnpm/qx-util@0.4.8/node_modules/qx-util/out/index.mjs +0 -2
- package/es/node_modules/.pnpm/qx-util@0.4.8/node_modules/qx-util/out/utils/array/array.mjs +0 -47
- package/es/node_modules/.pnpm/qx-util@0.4.8/node_modules/qx-util/out/utils/index.mjs +0 -5
- package/es/node_modules/.pnpm/qx-util@0.4.8/node_modules/qx-util/out/utils/object/object.mjs +0 -24
- package/es/node_modules/.pnpm/qx-util@0.4.8/node_modules/qx-util/out/utils/qx-event/qx-event.mjs +0 -94
- package/es/node_modules/.pnpm/qx-util@0.4.8/node_modules/qx-util/out/utils/qx-event-emitter/qx-event-emitter.mjs +0 -146
- package/es/node_modules/.pnpm/qx-util@0.4.8/node_modules/qx-util/out/utils/type-util/type-util.mjs +0 -149
- package/es/node_modules/.pnpm/qx-util@0.4.8/node_modules/qx-util/out/utils/util/util.mjs +0 -227
- package/es/provider/i-designer-provider/i-designer-provider.d.ts +0 -102
- package/es/provider/i-designer-provider/i-designer-provider.mjs +0 -1
- package/es/provider/index.d.ts +0 -1
- package/es/provider/index.mjs +0 -1
- package/es/register/designer-register/designer-register.d.ts +0 -53
- package/es/register/designer-register/designer-register.mjs +0 -69
- package/es/register/index.mjs +0 -6
- package/es/register/render-register/render-register.d.ts +0 -59
- package/es/register/render-register/render-register.mjs +0 -65
- package/es/service/base.service.d.ts +0 -19
- package/es/service/base.service.mjs +0 -41
- package/es/service/index.d.ts +0 -1
- package/es/service/index.mjs +0 -3
- package/es/state/index.mjs +0 -12
- package/es/utils/axios/axios.d.ts +0 -27
- package/es/utils/axios/axios.mjs +0 -84
- package/es/utils/index.mjs +0 -10
- package/es/utils/plugin-pkg-util/plugin-pkg-util.d.ts +0 -96
- package/es/utils/plugin-pkg-util/plugin-pkg-util.mjs +0 -262
|
@@ -0,0 +1,15 @@
|
|
|
1
|
+
import { AuthConfig, SysConfigResponse } from '@gct-paas/api/platform';
|
|
2
|
+
/**
|
|
3
|
+
* 登录设置 Composable 函数
|
|
4
|
+
* @returns 返回登录设置相关的响应式数据和方法
|
|
5
|
+
*/
|
|
6
|
+
export declare function useLoginSetting(): {
|
|
7
|
+
loginSetting: AuthConfig;
|
|
8
|
+
postLoginSetting: () => Promise<void>;
|
|
9
|
+
setLoginSetting: (config: SysConfigResponse | undefined) => void;
|
|
10
|
+
loginModeAuthTypes: import('vue').Ref<string[], string[]>;
|
|
11
|
+
openIDOAuthAuthTypes: import('vue').Ref<string[], string[]>;
|
|
12
|
+
sysLoginSort: import('vue').Ref<IObject[], IObject[]>;
|
|
13
|
+
openIDOAuthAuthSort: import('vue').Ref<IObject[], IObject[]>;
|
|
14
|
+
loginModeConfig: Map<string, IObject>;
|
|
15
|
+
};
|
|
@@ -0,0 +1,177 @@
|
|
|
1
|
+
import { ref, reactive } from 'vue';
|
|
2
|
+
import { LoginTypeEnum, LoginSortTypeEnum } from './enums/login.enum.mjs';
|
|
3
|
+
import { getLoginTypeOptions, OTHER_LOGIN_KEYS, SYSTEM_LOGIN_KEYS } from './constants/login.const.mjs';
|
|
4
|
+
import { has, isEmpty } from 'lodash-es';
|
|
5
|
+
|
|
6
|
+
const loginModeAuthTypes = ref([LoginTypeEnum.ACCOUNT]);
|
|
7
|
+
const openIDOAuthAuthTypes = ref([]);
|
|
8
|
+
const sysLoginSort = ref(getLoginTypeOptions(SYSTEM_LOGIN_KEYS));
|
|
9
|
+
const openIDOAuthAuthSort = ref(
|
|
10
|
+
getLoginTypeOptions(OTHER_LOGIN_KEYS)
|
|
11
|
+
);
|
|
12
|
+
const loginSetting = reactive({
|
|
13
|
+
theme: "full",
|
|
14
|
+
title: "欢迎登录冠骋云PaaS平台",
|
|
15
|
+
subtitle: "让数字化赋能客户成功!",
|
|
16
|
+
logo: "",
|
|
17
|
+
banner: "",
|
|
18
|
+
loginModeConfigs: [],
|
|
19
|
+
openIDOAuthConfigs: [],
|
|
20
|
+
sortJson: "",
|
|
21
|
+
defaultAuthType: LoginTypeEnum.ACCOUNT
|
|
22
|
+
});
|
|
23
|
+
const loginModeConfig = reactive(
|
|
24
|
+
/* @__PURE__ */ new Map([
|
|
25
|
+
[
|
|
26
|
+
LoginTypeEnum.ACCOUNT,
|
|
27
|
+
{
|
|
28
|
+
address: "",
|
|
29
|
+
authType: LoginTypeEnum.ACCOUNT,
|
|
30
|
+
relationField: "",
|
|
31
|
+
enabled: 0
|
|
32
|
+
}
|
|
33
|
+
],
|
|
34
|
+
[
|
|
35
|
+
LoginTypeEnum.DOMAIN_ACCOUNT,
|
|
36
|
+
{
|
|
37
|
+
address: "",
|
|
38
|
+
authType: LoginTypeEnum.DOMAIN_ACCOUNT,
|
|
39
|
+
relationField: "",
|
|
40
|
+
domainSuffix: "",
|
|
41
|
+
relationFieldName: "",
|
|
42
|
+
enabled: 0
|
|
43
|
+
}
|
|
44
|
+
],
|
|
45
|
+
[
|
|
46
|
+
LoginTypeEnum.MOBILE,
|
|
47
|
+
{
|
|
48
|
+
smsServiceProvider: "",
|
|
49
|
+
// 短信服务商
|
|
50
|
+
smsKey: "",
|
|
51
|
+
// 授权key
|
|
52
|
+
smsKeySecret: "",
|
|
53
|
+
// 授权secret
|
|
54
|
+
smsTemplateCode: "",
|
|
55
|
+
// 模板代码
|
|
56
|
+
smsSignName: "",
|
|
57
|
+
// 短信签名
|
|
58
|
+
phoneNumb: "",
|
|
59
|
+
smsSdkAppId: "",
|
|
60
|
+
authType: LoginTypeEnum.MOBILE,
|
|
61
|
+
enabled: 0
|
|
62
|
+
}
|
|
63
|
+
],
|
|
64
|
+
[
|
|
65
|
+
LoginTypeEnum.DINGDING,
|
|
66
|
+
{
|
|
67
|
+
appId: "",
|
|
68
|
+
authType: LoginTypeEnum.DINGDING,
|
|
69
|
+
secret: "",
|
|
70
|
+
redirectURL: "",
|
|
71
|
+
enabled: 0
|
|
72
|
+
}
|
|
73
|
+
],
|
|
74
|
+
[
|
|
75
|
+
LoginTypeEnum.FEISHU,
|
|
76
|
+
{
|
|
77
|
+
appId: "",
|
|
78
|
+
authType: LoginTypeEnum.FEISHU,
|
|
79
|
+
secret: "",
|
|
80
|
+
redirectURL: "",
|
|
81
|
+
enabled: 0
|
|
82
|
+
}
|
|
83
|
+
],
|
|
84
|
+
[
|
|
85
|
+
LoginTypeEnum.QIYEWEIXIN,
|
|
86
|
+
{
|
|
87
|
+
appId: "",
|
|
88
|
+
agentId: "",
|
|
89
|
+
authType: LoginTypeEnum.QIYEWEIXIN,
|
|
90
|
+
secret: "",
|
|
91
|
+
redirectURL: "",
|
|
92
|
+
enabled: 0,
|
|
93
|
+
certFileName: ""
|
|
94
|
+
}
|
|
95
|
+
]
|
|
96
|
+
])
|
|
97
|
+
);
|
|
98
|
+
function useLoginSetting() {
|
|
99
|
+
const postLoginSetting = async () => {
|
|
100
|
+
const enableTypes = [
|
|
101
|
+
...loginModeAuthTypes.value,
|
|
102
|
+
...openIDOAuthAuthTypes.value
|
|
103
|
+
];
|
|
104
|
+
enableTypes.forEach((item) => {
|
|
105
|
+
const config = loginModeConfig.get(item);
|
|
106
|
+
if (config) {
|
|
107
|
+
config.enabled = 1;
|
|
108
|
+
}
|
|
109
|
+
});
|
|
110
|
+
loginSetting.loginModeConfigs = SYSTEM_LOGIN_KEYS.map((item) => {
|
|
111
|
+
return loginModeConfig.get(item);
|
|
112
|
+
}).filter((config) => config !== void 0);
|
|
113
|
+
loginSetting.openIDOAuthConfigs = OTHER_LOGIN_KEYS.map((item) => {
|
|
114
|
+
return loginModeConfig.get(item);
|
|
115
|
+
}).filter((config) => config !== void 0);
|
|
116
|
+
loginSetting.sortJson = JSON.stringify({
|
|
117
|
+
[LoginSortTypeEnum.SYSTEM]: sysLoginSort.value.map((item) => item.id),
|
|
118
|
+
[LoginSortTypeEnum.THIRD_PARTY]: openIDOAuthAuthSort.value.map(
|
|
119
|
+
(item) => item.id
|
|
120
|
+
)
|
|
121
|
+
});
|
|
122
|
+
await _api.platform.plat.postLogin(loginSetting);
|
|
123
|
+
};
|
|
124
|
+
const setLoginSetting = (config) => {
|
|
125
|
+
if (config && config.value) {
|
|
126
|
+
const value = JSON.parse(config.value);
|
|
127
|
+
for (const k in value) {
|
|
128
|
+
if (k in loginSetting) {
|
|
129
|
+
loginSetting[k] = value[k];
|
|
130
|
+
}
|
|
131
|
+
}
|
|
132
|
+
if (has(value, "sortJson") && !isEmpty(value.sortJson)) {
|
|
133
|
+
const sortObj = JSON.parse(value.sortJson);
|
|
134
|
+
if (has(sortObj, LoginSortTypeEnum.SYSTEM)) {
|
|
135
|
+
sysLoginSort.value = getLoginTypeOptions(
|
|
136
|
+
sortObj[LoginSortTypeEnum.SYSTEM]
|
|
137
|
+
);
|
|
138
|
+
}
|
|
139
|
+
if (has(sortObj, LoginSortTypeEnum.THIRD_PARTY)) {
|
|
140
|
+
openIDOAuthAuthSort.value = getLoginTypeOptions(
|
|
141
|
+
sortObj[LoginSortTypeEnum.THIRD_PARTY]
|
|
142
|
+
);
|
|
143
|
+
}
|
|
144
|
+
}
|
|
145
|
+
loginSetting.loginModeConfigs?.forEach((item) => {
|
|
146
|
+
loginModeConfig.set(item.authType, { ...item, enabled: 0 });
|
|
147
|
+
});
|
|
148
|
+
const loginModeConfigs = loginSetting.loginModeConfigs?.filter((item) => {
|
|
149
|
+
return item.enabled;
|
|
150
|
+
}).map((i) => {
|
|
151
|
+
return i.authType;
|
|
152
|
+
}) || [];
|
|
153
|
+
loginModeConfigs.push(LoginTypeEnum.ACCOUNT);
|
|
154
|
+
loginModeAuthTypes.value = [...new Set(loginModeConfigs)];
|
|
155
|
+
loginSetting.openIDOAuthConfigs?.forEach((item) => {
|
|
156
|
+
loginModeConfig.set(item.authType, { ...item, enabled: 0 });
|
|
157
|
+
});
|
|
158
|
+
openIDOAuthAuthTypes.value = loginSetting.openIDOAuthConfigs?.filter((item) => {
|
|
159
|
+
return item.enabled;
|
|
160
|
+
}).map((i) => {
|
|
161
|
+
return i.authType;
|
|
162
|
+
}) || [];
|
|
163
|
+
}
|
|
164
|
+
};
|
|
165
|
+
return {
|
|
166
|
+
loginSetting,
|
|
167
|
+
postLoginSetting,
|
|
168
|
+
setLoginSetting,
|
|
169
|
+
loginModeAuthTypes,
|
|
170
|
+
openIDOAuthAuthTypes,
|
|
171
|
+
sysLoginSort,
|
|
172
|
+
openIDOAuthAuthSort,
|
|
173
|
+
loginModeConfig
|
|
174
|
+
};
|
|
175
|
+
}
|
|
176
|
+
|
|
177
|
+
export { useLoginSetting };
|
|
@@ -0,0 +1,34 @@
|
|
|
1
|
+
import { OrgConfig, SysConfigResponse } from '@gct-paas/api/platform';
|
|
2
|
+
/**
|
|
3
|
+
* 组织设置 Composable 函数
|
|
4
|
+
* @param isPlatform - 是否为平台模式,默认为 true
|
|
5
|
+
* @returns 返回组织设置相关的响应式数据和方法
|
|
6
|
+
*/
|
|
7
|
+
export declare function useOrgSetting(isPlatform?: boolean): {
|
|
8
|
+
orgSetting: OrgConfig;
|
|
9
|
+
setOrgSetting: (data: SysConfigResponse) => void;
|
|
10
|
+
postOrgSetting: () => Promise<void>;
|
|
11
|
+
relationFields: import('vue').Ref<{
|
|
12
|
+
label: string;
|
|
13
|
+
value: string;
|
|
14
|
+
type: number;
|
|
15
|
+
}[], {
|
|
16
|
+
label: string;
|
|
17
|
+
value: string;
|
|
18
|
+
type: number;
|
|
19
|
+
}[] | {
|
|
20
|
+
label: string;
|
|
21
|
+
value: string;
|
|
22
|
+
type: number;
|
|
23
|
+
}[]>;
|
|
24
|
+
relationFiledsCopy: import('vue').Ref<{
|
|
25
|
+
label: string;
|
|
26
|
+
value: string;
|
|
27
|
+
}[], {
|
|
28
|
+
label: string;
|
|
29
|
+
value: string;
|
|
30
|
+
}[] | {
|
|
31
|
+
label: string;
|
|
32
|
+
value: string;
|
|
33
|
+
}[]>;
|
|
34
|
+
};
|
|
@@ -0,0 +1,66 @@
|
|
|
1
|
+
import { reactive, ref } from 'vue';
|
|
2
|
+
import { RELATION_FIELDS } from './constants/org.const.mjs';
|
|
3
|
+
|
|
4
|
+
const orgSetting = reactive({
|
|
5
|
+
initialPassword: "123456",
|
|
6
|
+
initialSignPassword: "12345678",
|
|
7
|
+
enableIdentifier: 1,
|
|
8
|
+
enableDeleteAccount: 1,
|
|
9
|
+
enableDeleteUser: 0,
|
|
10
|
+
requiredFields: [],
|
|
11
|
+
// supportLoginFields: ['username_', 'emp_no_'],
|
|
12
|
+
supportLoginFields: ["username_"],
|
|
13
|
+
extFieldConfigs: [],
|
|
14
|
+
orgExtFieldConfigs: []
|
|
15
|
+
});
|
|
16
|
+
const relationFields = ref([...RELATION_FIELDS]);
|
|
17
|
+
const relationFiledsCopy = ref([]);
|
|
18
|
+
function useOrgSetting(isPlatform = true) {
|
|
19
|
+
const postOrgSetting = async () => {
|
|
20
|
+
const setting = JSON.parse(JSON.stringify(orgSetting));
|
|
21
|
+
if (isPlatform) {
|
|
22
|
+
await _api.platform.plat.postOrg(setting);
|
|
23
|
+
} else {
|
|
24
|
+
await _api.apaas.plat.postOrg(setting);
|
|
25
|
+
}
|
|
26
|
+
};
|
|
27
|
+
function setOrgSetting(data) {
|
|
28
|
+
const { value } = data;
|
|
29
|
+
if (!value) return;
|
|
30
|
+
try {
|
|
31
|
+
const setting = JSON.parse(value);
|
|
32
|
+
for (const key in setting) {
|
|
33
|
+
if (key == "supportLoginFields") {
|
|
34
|
+
setting["supportLoginFields"] = setting["supportLoginFields"].filter(
|
|
35
|
+
(i) => i !== "username_"
|
|
36
|
+
);
|
|
37
|
+
}
|
|
38
|
+
}
|
|
39
|
+
Object.assign(orgSetting, setting);
|
|
40
|
+
if (orgSetting.extFieldConfigs && orgSetting.extFieldConfigs.length) {
|
|
41
|
+
orgSetting.extFieldConfigs.forEach((element) => {
|
|
42
|
+
relationFields.value = relationFields.value.filter((i) => {
|
|
43
|
+
if (i.value == element.relationField) {
|
|
44
|
+
relationFiledsCopy.value.push(i);
|
|
45
|
+
}
|
|
46
|
+
return i.value !== element.relationField;
|
|
47
|
+
});
|
|
48
|
+
});
|
|
49
|
+
}
|
|
50
|
+
orgSetting.extFieldConfigs = JSON.parse(
|
|
51
|
+
JSON.stringify(setting.extFieldConfigs)
|
|
52
|
+
);
|
|
53
|
+
} catch (err) {
|
|
54
|
+
console.warn(err);
|
|
55
|
+
}
|
|
56
|
+
}
|
|
57
|
+
return {
|
|
58
|
+
orgSetting,
|
|
59
|
+
setOrgSetting,
|
|
60
|
+
postOrgSetting,
|
|
61
|
+
relationFields,
|
|
62
|
+
relationFiledsCopy
|
|
63
|
+
};
|
|
64
|
+
}
|
|
65
|
+
|
|
66
|
+
export { useOrgSetting };
|
|
@@ -0,0 +1,12 @@
|
|
|
1
|
+
/**
|
|
2
|
+
* 部署设置 Composable
|
|
3
|
+
* 用于管理应用的部署模式配置
|
|
4
|
+
*/
|
|
5
|
+
/** 基础配置信息响应式对象 */
|
|
6
|
+
declare const projectSetting: {};
|
|
7
|
+
declare function setProjectConfig(config: typeof projectSetting): void;
|
|
8
|
+
export declare function useProjectSetting(): {
|
|
9
|
+
projectSetting: {};
|
|
10
|
+
setProjectConfig: typeof setProjectConfig;
|
|
11
|
+
};
|
|
12
|
+
export {};
|
|
@@ -0,0 +1,11 @@
|
|
|
1
|
+
import { reactive } from 'vue';
|
|
2
|
+
|
|
3
|
+
const projectSetting = reactive({});
|
|
4
|
+
function setProjectConfig(config) {
|
|
5
|
+
Object.assign(projectSetting, config);
|
|
6
|
+
}
|
|
7
|
+
function useProjectSetting() {
|
|
8
|
+
return { projectSetting, setProjectConfig };
|
|
9
|
+
}
|
|
10
|
+
|
|
11
|
+
export { useProjectSetting };
|
|
@@ -0,0 +1,11 @@
|
|
|
1
|
+
import { SecurityConfig, SysConfigResponse } from '@gct-paas/api/platform';
|
|
2
|
+
/**
|
|
3
|
+
* 安全设置 Composable 函数
|
|
4
|
+
* @param isPlatform - 是否为平台模式,默认为 true
|
|
5
|
+
* @returns 返回安全设置相关的响应式数据和方法
|
|
6
|
+
*/
|
|
7
|
+
export declare function useSecuritySetting(isPlatform?: boolean): {
|
|
8
|
+
securitySetting: SecurityConfig;
|
|
9
|
+
postSecuritySetting: () => Promise<void>;
|
|
10
|
+
setSecuritySetting: (data: SysConfigResponse) => void;
|
|
11
|
+
};
|
|
@@ -0,0 +1,60 @@
|
|
|
1
|
+
import { reactive } from 'vue';
|
|
2
|
+
|
|
3
|
+
const securitySetting = reactive({
|
|
4
|
+
durationHour: 2,
|
|
5
|
+
durationMinute: 0,
|
|
6
|
+
enableChangePassword: 1,
|
|
7
|
+
enableChangeSignPassword: 0,
|
|
8
|
+
enableSignPassword: 0,
|
|
9
|
+
enableKickOut: 1,
|
|
10
|
+
enablePassphrase: 1,
|
|
11
|
+
signEnablePassphrase: 1,
|
|
12
|
+
enableLockAccount: 1,
|
|
13
|
+
expiryDate: 30,
|
|
14
|
+
signExpiryDate: 30,
|
|
15
|
+
firstTimeChangePassword: 0,
|
|
16
|
+
signFirstTimeChangePassword: 0,
|
|
17
|
+
lockTimeout: 0,
|
|
18
|
+
loginKickOutMode: "SAME_END",
|
|
19
|
+
maxErrorTimes: 2,
|
|
20
|
+
passMinLength: 6,
|
|
21
|
+
signPassMinLength: 6,
|
|
22
|
+
passRule: ["NUMBER"],
|
|
23
|
+
signPassRule: ["NUMBER"],
|
|
24
|
+
signRepeatNum: 1,
|
|
25
|
+
repeatNum: 1,
|
|
26
|
+
timeUnit: "DAYS",
|
|
27
|
+
signTimeUnit: "DAYS",
|
|
28
|
+
noOpRetainHour: 8,
|
|
29
|
+
noOpRetainMinute: 0,
|
|
30
|
+
earlyAlarmMinute: 5,
|
|
31
|
+
earlyAlarmSecond: 0,
|
|
32
|
+
inapplicablePerson: [],
|
|
33
|
+
lockHourTimeout: 0,
|
|
34
|
+
lockMinTimeout: 5
|
|
35
|
+
});
|
|
36
|
+
function useSecuritySetting(isPlatform = true) {
|
|
37
|
+
const postSecuritySetting = async () => {
|
|
38
|
+
if (isPlatform) {
|
|
39
|
+
await _api.platform.plat.postSecurity(securitySetting);
|
|
40
|
+
} else {
|
|
41
|
+
await _api.apaas.plat.postSecurity(securitySetting);
|
|
42
|
+
}
|
|
43
|
+
};
|
|
44
|
+
function setSecuritySetting(data) {
|
|
45
|
+
const { value } = data;
|
|
46
|
+
if (!value) return;
|
|
47
|
+
try {
|
|
48
|
+
Object.assign(securitySetting, JSON.parse(value));
|
|
49
|
+
} catch (err) {
|
|
50
|
+
console.warn(err);
|
|
51
|
+
}
|
|
52
|
+
}
|
|
53
|
+
return {
|
|
54
|
+
securitySetting,
|
|
55
|
+
postSecuritySetting,
|
|
56
|
+
setSecuritySetting
|
|
57
|
+
};
|
|
58
|
+
}
|
|
59
|
+
|
|
60
|
+
export { useSecuritySetting };
|
|
@@ -0,0 +1,16 @@
|
|
|
1
|
+
import { IThemeSetting } from './interfaces/theme-setting.interface';
|
|
2
|
+
import { SysConfigResponse } from '@gct-paas/api/platform';
|
|
3
|
+
/**
|
|
4
|
+
* 主题设置 Composable 函数
|
|
5
|
+
* @returns 返回主题设置相关的响应式数据和方法
|
|
6
|
+
*/
|
|
7
|
+
export declare function useThemeSetting(): {
|
|
8
|
+
themeSetting: IThemeSetting;
|
|
9
|
+
setThemeSetting: (data: SysConfigResponse) => void;
|
|
10
|
+
postThemeSetting: () => Promise<void>;
|
|
11
|
+
menuCollapsed: import('vue').Ref<boolean, boolean>;
|
|
12
|
+
toggleMenuCollapsed: () => void;
|
|
13
|
+
menuCollapsedWidth: number;
|
|
14
|
+
menuWidthRange: number[];
|
|
15
|
+
themeColors: string[];
|
|
16
|
+
};
|
|
@@ -0,0 +1,64 @@
|
|
|
1
|
+
import { reactive, ref, watch } from 'vue';
|
|
2
|
+
import { THEME_COLORS, MENU_WIDTH_RANGE, MENU_COLLAPSED_WIDTH } from './constants/theme.const.mjs';
|
|
3
|
+
|
|
4
|
+
const themeSetting = reactive({
|
|
5
|
+
darkMode: "light",
|
|
6
|
+
themeColor: "#026AC8",
|
|
7
|
+
// menuMode: 'mix-sider',
|
|
8
|
+
menuMode: "classic",
|
|
9
|
+
menuWidth: 232,
|
|
10
|
+
menuCollapsible: true,
|
|
11
|
+
menuSearchable: true,
|
|
12
|
+
menuFilter: false,
|
|
13
|
+
showLogo: true,
|
|
14
|
+
showBreadcrumb: false,
|
|
15
|
+
showBreadcrumbIcon: false,
|
|
16
|
+
showTabs: true,
|
|
17
|
+
pageProgress: true,
|
|
18
|
+
pageLoading: true,
|
|
19
|
+
colorMode: "normal"
|
|
20
|
+
});
|
|
21
|
+
const menuCollapsed = ref(false);
|
|
22
|
+
const menuCollapsedWidth = MENU_COLLAPSED_WIDTH;
|
|
23
|
+
const menuWidthRange = MENU_WIDTH_RANGE;
|
|
24
|
+
const themeColors = THEME_COLORS;
|
|
25
|
+
const toggleColorMode = () => {
|
|
26
|
+
switch (themeSetting.colorMode) {
|
|
27
|
+
}
|
|
28
|
+
};
|
|
29
|
+
watch(
|
|
30
|
+
() => themeSetting.colorMode,
|
|
31
|
+
(value) => {
|
|
32
|
+
if (value) {
|
|
33
|
+
toggleColorMode();
|
|
34
|
+
}
|
|
35
|
+
}
|
|
36
|
+
);
|
|
37
|
+
function useThemeSetting() {
|
|
38
|
+
const postThemeSetting = async () => {
|
|
39
|
+
};
|
|
40
|
+
function setThemeSetting(data) {
|
|
41
|
+
const { value } = data;
|
|
42
|
+
if (!value) return;
|
|
43
|
+
try {
|
|
44
|
+
Object.assign(themeSetting, JSON.parse(value));
|
|
45
|
+
} catch (err) {
|
|
46
|
+
console.warn(err);
|
|
47
|
+
}
|
|
48
|
+
}
|
|
49
|
+
function toggleMenuCollapsed() {
|
|
50
|
+
menuCollapsed.value = !menuCollapsed.value;
|
|
51
|
+
}
|
|
52
|
+
return {
|
|
53
|
+
themeSetting,
|
|
54
|
+
setThemeSetting,
|
|
55
|
+
postThemeSetting,
|
|
56
|
+
menuCollapsed,
|
|
57
|
+
toggleMenuCollapsed,
|
|
58
|
+
menuCollapsedWidth,
|
|
59
|
+
menuWidthRange,
|
|
60
|
+
themeColors
|
|
61
|
+
};
|
|
62
|
+
}
|
|
63
|
+
|
|
64
|
+
export { useThemeSetting };
|
|
@@ -0,0 +1,21 @@
|
|
|
1
|
+
import { SysConfigResponse } from '@gct-paas/api/platform';
|
|
2
|
+
/**
|
|
3
|
+
* 水印设置 Composable 函数
|
|
4
|
+
* @returns 返回水印设置相关的响应式数据和方法
|
|
5
|
+
*/
|
|
6
|
+
export declare function useWatermarkSetting(): {
|
|
7
|
+
watermarkSetting: {
|
|
8
|
+
openWatermark: boolean;
|
|
9
|
+
watermarkContent: string;
|
|
10
|
+
fontSize: number;
|
|
11
|
+
color: string;
|
|
12
|
+
verticalAlign: string;
|
|
13
|
+
textAlign: string;
|
|
14
|
+
text: string;
|
|
15
|
+
transparent: number;
|
|
16
|
+
width: number;
|
|
17
|
+
height: number;
|
|
18
|
+
};
|
|
19
|
+
postWatermarkSetting: () => Promise<void>;
|
|
20
|
+
setWatermarkSetting: (data: SysConfigResponse) => void;
|
|
21
|
+
};
|
|
@@ -0,0 +1,26 @@
|
|
|
1
|
+
import { reactive } from 'vue';
|
|
2
|
+
import { WATERMARK_INIT_DATA } from './constants/watermark.const.mjs';
|
|
3
|
+
|
|
4
|
+
const watermarkSetting = reactive({ ...WATERMARK_INIT_DATA });
|
|
5
|
+
function useWatermarkSetting() {
|
|
6
|
+
const postWatermarkSetting = async () => {
|
|
7
|
+
const value = JSON.stringify(watermarkSetting);
|
|
8
|
+
await _api.platform.plat.postWatermark({ value });
|
|
9
|
+
};
|
|
10
|
+
function setWatermarkSetting(data) {
|
|
11
|
+
const { value } = data;
|
|
12
|
+
if (!value) return;
|
|
13
|
+
try {
|
|
14
|
+
Object.assign(watermarkSetting, JSON.parse(value));
|
|
15
|
+
} catch (err) {
|
|
16
|
+
console.warn(err);
|
|
17
|
+
}
|
|
18
|
+
}
|
|
19
|
+
return {
|
|
20
|
+
watermarkSetting,
|
|
21
|
+
postWatermarkSetting,
|
|
22
|
+
setWatermarkSetting
|
|
23
|
+
};
|
|
24
|
+
}
|
|
25
|
+
|
|
26
|
+
export { useWatermarkSetting };
|
|
@@ -0,0 +1,21 @@
|
|
|
1
|
+
export declare const usePermissionStore: import('pinia').StoreDefinition<"permission", {
|
|
2
|
+
userPermissions: {
|
|
3
|
+
appSuperAdmin: number;
|
|
4
|
+
permissions: IObject;
|
|
5
|
+
};
|
|
6
|
+
}, {
|
|
7
|
+
hasAllPermissions(state: {
|
|
8
|
+
userPermissions: {
|
|
9
|
+
appSuperAdmin: number;
|
|
10
|
+
permissions: IObject;
|
|
11
|
+
};
|
|
12
|
+
} & import('pinia').PiniaCustomStateProperties<{
|
|
13
|
+
userPermissions: {
|
|
14
|
+
appSuperAdmin: number;
|
|
15
|
+
permissions: IObject;
|
|
16
|
+
};
|
|
17
|
+
}>): boolean;
|
|
18
|
+
}, {
|
|
19
|
+
getPermissionByKey(pageId: string, key?: string): boolean;
|
|
20
|
+
initPermission(): Promise<void>;
|
|
21
|
+
}>;
|
|
@@ -0,0 +1,38 @@
|
|
|
1
|
+
import { defineStore } from 'pinia';
|
|
2
|
+
|
|
3
|
+
const usePermissionStore = defineStore("permission", {
|
|
4
|
+
state: () => ({
|
|
5
|
+
//当前应用中用户的权限
|
|
6
|
+
userPermissions: {
|
|
7
|
+
appSuperAdmin: 0,
|
|
8
|
+
permissions: {}
|
|
9
|
+
}
|
|
10
|
+
}),
|
|
11
|
+
getters: {
|
|
12
|
+
hasAllPermissions(state) {
|
|
13
|
+
return !!state.userPermissions.appSuperAdmin || !!state.userPermissions.permissions["POINT.*"];
|
|
14
|
+
}
|
|
15
|
+
},
|
|
16
|
+
actions: {
|
|
17
|
+
getPermissionByKey(pageId, key) {
|
|
18
|
+
if (this.hasAllPermissions) return true;
|
|
19
|
+
if (!key) {
|
|
20
|
+
return this.userPermissions.permissions[pageId];
|
|
21
|
+
}
|
|
22
|
+
const uKey = `${pageId}.${key}`;
|
|
23
|
+
const pageKey = `${pageId}.*`;
|
|
24
|
+
return this.userPermissions.permissions[uKey] || this.userPermissions.permissions[pageKey];
|
|
25
|
+
},
|
|
26
|
+
async initPermission() {
|
|
27
|
+
const res = await _api.apaas.designerCommon.getUserInfo();
|
|
28
|
+
Object.assign(this.userPermissions, {
|
|
29
|
+
...res,
|
|
30
|
+
permissions: Object.fromEntries(
|
|
31
|
+
(res?.permissions ?? []).map((key) => [key, true])
|
|
32
|
+
)
|
|
33
|
+
});
|
|
34
|
+
}
|
|
35
|
+
}
|
|
36
|
+
});
|
|
37
|
+
|
|
38
|
+
export { usePermissionStore };
|
|
@@ -0,0 +1,9 @@
|
|
|
1
|
+
import { UserOfTenantDTO } from '@gct-paas/api/platform';
|
|
2
|
+
export declare const useTenantStore: import('pinia').StoreDefinition<"tenant", {
|
|
3
|
+
tenantId: string;
|
|
4
|
+
tenantUserInfo: {};
|
|
5
|
+
tenantUserPermissions: {};
|
|
6
|
+
}, {}, {
|
|
7
|
+
setTenant(tenantId: string): void;
|
|
8
|
+
getTenantUserInfoAction(): Promise<UserOfTenantDTO | undefined>;
|
|
9
|
+
}>;
|
|
@@ -0,0 +1,24 @@
|
|
|
1
|
+
import { defineStore } from 'pinia';
|
|
2
|
+
|
|
3
|
+
const useTenantStore = defineStore("tenant", {
|
|
4
|
+
state: () => ({
|
|
5
|
+
//selected tenant Id
|
|
6
|
+
tenantId: "",
|
|
7
|
+
// 当前租户中的用户信息
|
|
8
|
+
tenantUserInfo: {},
|
|
9
|
+
tenantUserPermissions: {}
|
|
10
|
+
}),
|
|
11
|
+
actions: {
|
|
12
|
+
setTenant(tenantId) {
|
|
13
|
+
this.tenantId = tenantId;
|
|
14
|
+
},
|
|
15
|
+
async getTenantUserInfoAction() {
|
|
16
|
+
if (!this.tenantId) return;
|
|
17
|
+
const info = await _api.platform.tenant.getUserInfo();
|
|
18
|
+
this.tenantUserInfo = info;
|
|
19
|
+
return info;
|
|
20
|
+
}
|
|
21
|
+
}
|
|
22
|
+
});
|
|
23
|
+
|
|
24
|
+
export { useTenantStore };
|