From 1f9ebfefc376591dac108388a58fe84e00a6c887 Mon Sep 17 00:00:00 2001 From: zhangkang <1752553776@qq.com> Date: Tue, 6 Jun 2023 10:27:50 +0800 Subject: [PATCH] =?UTF-8?q?feat:=20=E9=A1=B9=E7=9B=AE=E7=BB=93=E6=9E=84?= =?UTF-8?q?=E5=90=8C=E6=AD=A5?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- package.json | 28 +- pnpm-lock.yaml | 469 ++++++++---------- public/environments/environment.js | 7 +- src/create-vue-app.ts | 13 +- .../unauthorized-handler.ts | 6 +- src/main.ts | 10 +- src/router/index.ts | 43 +- src/store/app-store/app-store.ts | 10 - src/store/index.ts | 6 - src/store/ui-store/ui-store.ts | 24 - src/store/ui-store/z-index.ts | 53 -- src/util/app-drawer/app-drawer-component.scss | 19 - src/util/app-drawer/app-drawer-component.tsx | 96 ---- src/util/app-modal/app-modal-component.tsx | 101 ---- src/util/app-modal/modal.scss | 28 -- .../app-popover/app-popover-component.tsx | 197 -------- src/util/app-popover/popover.scss | 24 - src/util/index.ts | 8 - src/util/loading-util/loading-util.ts | 99 ---- src/util/message-util/message-util.ts | 61 --- src/util/modal-util/modal-util.ts | 37 -- .../notification-util/notification-util.ts | 53 -- src/util/open-view-util/open-view-util.ts | 149 ------ .../overlay-container/overlay-container.ts | 148 ------ .../overlay-controller/overlay-controller.ts | 93 ---- .../overlay-popover-container.ts | 30 -- .../overlay-view-util/overlay-view-util.ts | 85 ---- src/views/404-view/404-view.scss | 17 - src/views/404-view/404-view.tsx | 49 -- .../app-redirect-view/app-redirect-view.tsx | 32 -- src/views/index.ts | 1 - src/views/login-view/login-view.scss | 78 --- src/views/login-view/login-view.tsx | 162 ------ src/views/todo-redirect/todo-redirect.tsx | 51 -- vite.config.ts | 7 + 35 files changed, 276 insertions(+), 2018 deletions(-) delete mode 100644 src/store/app-store/app-store.ts delete mode 100644 src/store/index.ts delete mode 100644 src/store/ui-store/ui-store.ts delete mode 100644 src/store/ui-store/z-index.ts delete mode 100644 src/util/app-drawer/app-drawer-component.scss delete mode 100644 src/util/app-drawer/app-drawer-component.tsx delete mode 100644 src/util/app-modal/app-modal-component.tsx delete mode 100644 src/util/app-modal/modal.scss delete mode 100644 src/util/app-popover/app-popover-component.tsx delete mode 100644 src/util/app-popover/popover.scss delete mode 100644 src/util/loading-util/loading-util.ts delete mode 100644 src/util/message-util/message-util.ts delete mode 100644 src/util/modal-util/modal-util.ts delete mode 100644 src/util/notification-util/notification-util.ts delete mode 100644 src/util/open-view-util/open-view-util.ts delete mode 100644 src/util/overlay-container/overlay-container.ts delete mode 100644 src/util/overlay-controller/overlay-controller.ts delete mode 100644 src/util/overlay-popover-container/overlay-popover-container.ts delete mode 100644 src/util/overlay-view-util/overlay-view-util.ts delete mode 100644 src/views/404-view/404-view.scss delete mode 100644 src/views/404-view/404-view.tsx delete mode 100644 src/views/app-redirect-view/app-redirect-view.tsx delete mode 100644 src/views/index.ts delete mode 100644 src/views/login-view/login-view.scss delete mode 100644 src/views/login-view/login-view.tsx delete mode 100644 src/views/todo-redirect/todo-redirect.tsx diff --git a/package.json b/package.json index bc5e9a1..8b5ba66 100644 --- a/package.json +++ b/package.json @@ -9,30 +9,30 @@ "preview": "vite preview", "lint": "eslint 'src/**/*.tsx' 'src/**/*.ts' 'src/**/*.vue'", "lint:style": "stylelint 'src/**/*.scss'", - "pub": "ibizlab pub -m /root/workspace/train/TrainSys/trainsys-core/src/main/resources/model/cn/ibizlab/trainsys -t ./template -o ./src/publish --app Web && npm run prettier", + "pub": "ibizlab pub -m /root/Git/full/iBizDemoOld/demo-core/src/main/resources/model/net/ibizsys/demo -t ./template -o ./src/publish --app Sample && npm run prettier", "prettier": "prettier 'src/publish/**/*.ts' -w" }, "dependencies": { - "@floating-ui/dom": "^1.2.7", - "@ibiz-template/core": "^0.0.4-beta.5", - "@ibiz-template/default-view-layout": "^1.0.2", - "@ibiz-template/model-helper": "^0.0.4-beta.5", - "@ibiz-template/runtime": "^0.0.4-beta.5", - "@ibiz-template/theme": "^0.0.4-beta.3", - "@ibiz-template/vue3-components": "^0.0.1-alpha.3", - "@ibiz-template/vue3-util": "^0.0.4-beta.5", - "@ibiz/model-core": "^0.0.7", + "@floating-ui/dom": "^1.2.9", + "@ibiz-template/core": "0.0.4-beta.16", + "@ibiz-template/default-view-layout": "^1.0.16", + "@ibiz-template/model-helper": "0.0.4-beta.16", + "@ibiz-template/runtime": "0.0.4-beta.16", + "@ibiz-template/theme": "0.0.4-beta.16", + "@ibiz-template/vue3-components": "0.0.1-alpha.9", + "@ibiz-template/vue3-util": "0.0.4-beta.16", + "@ibiz/model-core": "^0.0.10", "async-validator": "^4.2.5", "dayjs": "^1.11.7", "element-plus": "^2.3.4", "lodash-es": "^4.17.21", "nprogress": "^0.2.0", "path-browserify": "^1.0.1", - "pinia": "^2.0.35", + "pinia": "^2.1.3", "qs": "^6.11.1", "qx-util": "^0.4.8", "ramda": "^0.29.0", - "vue": "^3.2.47", + "vue": "^3.3.4", "vue-i18n": "^9.2.2", "vue-router": "^4.1.6", "vuedraggable": "^4.1.0" @@ -40,8 +40,8 @@ "devDependencies": { "@commitlint/cli": "^17.6.1", "@commitlint/config-conventional": "^17.6.1", - "@ibizlab/cli": "^0.1.57", "@types/lodash-es": "^4.17.7", + "@ibizlab/cli": "^0.1.57", "@types/node": "^18.16.3", "@types/nprogress": "^0.2.0", "@types/path-browserify": "^1.0.0", @@ -76,7 +76,7 @@ "stylelint-scss": "^5.0.0", "terser": "^5.17.1", "typescript": "^5.0.4", - "vite": "^4.3.4", + "vite": "^4.3.9", "vite-plugin-eslint": "^1.8.1", "vue-eslint-parser": "^9.2.0", "vue-tsc": "^1.6.4" diff --git a/pnpm-lock.yaml b/pnpm-lock.yaml index 2f1067b..64ff1de 100644 --- a/pnpm-lock.yaml +++ b/pnpm-lock.yaml @@ -1,33 +1,37 @@ -lockfileVersion: '6.0' +lockfileVersion: '6.1' + +settings: + autoInstallPeers: true + excludeLinksFromLockfile: false dependencies: '@floating-ui/dom': - specifier: ^1.2.7 - version: 1.2.7 + specifier: ^1.2.9 + version: 1.2.9 '@ibiz-template/core': - specifier: ^0.0.4-beta.5 - version: 0.0.4-beta.5(axios@1.3.5)(lodash-es@4.17.21)(qs@6.11.1)(qx-util@0.4.8)(ramda@0.29.0) + specifier: 0.0.4-beta.16 + version: 0.0.4-beta.16(axios@1.4.0)(lodash-es@4.17.21)(qs@6.11.1)(qx-util@0.4.8)(ramda@0.29.0) '@ibiz-template/default-view-layout': - specifier: ^1.0.2 - version: 1.0.2 + specifier: ^1.0.16 + version: 1.0.16 '@ibiz-template/model-helper': - specifier: ^0.0.4-beta.5 - version: 0.0.4-beta.5(@ibiz-template/runtime@0.0.4-beta.5) + specifier: 0.0.4-beta.16 + version: 0.0.4-beta.16(@ibiz-template/runtime@0.0.4-beta.16) '@ibiz-template/runtime': - specifier: ^0.0.4-beta.5 - version: 0.0.4-beta.5(@ibiz-template/core@0.0.4-beta.5)(@ibiz/model-core@0.0.7)(async-validator@4.2.5)(dayjs@1.11.7)(lodash-es@4.17.21)(qs@6.11.1)(qx-util@0.4.8)(ramda@0.29.0) + specifier: 0.0.4-beta.16 + version: 0.0.4-beta.16(@ibiz-template/core@0.0.4-beta.16)(@ibiz/model-core@0.0.10)(async-validator@4.2.5)(dayjs@1.11.7)(lodash-es@4.17.21)(qs@6.11.1)(qx-util@0.4.8)(ramda@0.29.0) '@ibiz-template/theme': - specifier: ^0.0.4-beta.3 - version: 0.0.4-beta.3 + specifier: 0.0.4-beta.16 + version: 0.0.4-beta.16 '@ibiz-template/vue3-components': - specifier: ^0.0.1-alpha.3 - version: 0.0.1-alpha.3(@ibiz-template/core@0.0.4-beta.5)(@ibiz-template/model-helper@0.0.4-beta.5)(@ibiz-template/runtime@0.0.4-beta.5)(@ibiz-template/vue3-util@0.0.4-beta.5)(@ibiz-template/vue3@0.0.1-alpha.1)(@ibiz/model-core@0.0.7)(qx-util@0.4.8)(vue-router@4.1.6)(vue@3.2.47) + specifier: 0.0.1-alpha.9 + version: 0.0.1-alpha.9(@floating-ui/dom@1.2.9)(@ibiz-template/core@0.0.4-beta.16)(@ibiz-template/model-helper@0.0.4-beta.16)(@ibiz-template/runtime@0.0.4-beta.16)(@ibiz-template/theme@0.0.4-beta.16)(@ibiz-template/vue3-util@0.0.4-beta.16)(@ibiz/model-core@0.0.10)(async-validator@4.2.5)(dayjs@1.11.7)(element-plus@2.3.4)(lodash-es@4.17.21)(nprogress@0.2.0)(pinia@2.1.3)(qs@6.11.1)(qx-util@0.4.8)(ramda@0.29.0)(vue-router@4.1.6)(vue@3.3.4) '@ibiz-template/vue3-util': - specifier: ^0.0.4-beta.5 - version: 0.0.4-beta.5(@ibiz-template/core@0.0.4-beta.5)(@ibiz-template/runtime@0.0.4-beta.5)(@ibiz/model-core@0.0.7)(qs@6.11.1)(qx-util@0.4.8)(ramda@0.29.0)(vue-router@4.1.6)(vue@3.2.47) + specifier: 0.0.4-beta.16 + version: 0.0.4-beta.16(@ibiz-template/core@0.0.4-beta.16)(@ibiz-template/runtime@0.0.4-beta.16)(@ibiz/model-core@0.0.10)(qs@6.11.1)(qx-util@0.4.8)(ramda@0.29.0)(vue-router@4.1.6)(vue@3.3.4) '@ibiz/model-core': - specifier: ^0.0.7 - version: 0.0.7 + specifier: ^0.0.10 + version: 0.0.10 async-validator: specifier: ^4.2.5 version: 4.2.5 @@ -36,7 +40,7 @@ dependencies: version: 1.11.7 element-plus: specifier: ^2.3.4 - version: 2.3.4(vue@3.2.47) + version: 2.3.4(vue@3.3.4) lodash-es: specifier: ^4.17.21 version: 4.17.21 @@ -47,8 +51,8 @@ dependencies: specifier: ^1.0.1 version: 1.0.1 pinia: - specifier: ^2.0.35 - version: 2.0.35(typescript@5.0.4)(vue@3.2.47) + specifier: ^2.1.3 + version: 2.1.3(typescript@5.0.4)(vue@3.3.4) qs: specifier: ^6.11.1 version: 6.11.1 @@ -59,17 +63,17 @@ dependencies: specifier: ^0.29.0 version: 0.29.0 vue: - specifier: ^3.2.47 - version: 3.2.47 + specifier: ^3.3.4 + version: 3.3.4 vue-i18n: specifier: ^9.2.2 - version: 9.2.2(vue@3.2.47) + version: 9.2.2(vue@3.3.4) vue-router: specifier: ^4.1.6 - version: 4.1.6(vue@3.2.47) + version: 4.1.6(vue@3.3.4) vuedraggable: specifier: ^4.1.0 - version: 4.1.0(vue@3.2.47) + version: 4.1.0(vue@3.3.4) devDependencies: '@commitlint/cli': @@ -110,13 +114,13 @@ devDependencies: version: 5.59.2(eslint@8.39.0)(typescript@5.0.4) '@vitejs/plugin-legacy': specifier: ^4.0.3 - version: 4.0.3(terser@5.17.1)(vite@4.3.4) + version: 4.0.3(terser@5.17.1)(vite@4.3.9) '@vitejs/plugin-vue': specifier: ^4.2.1 - version: 4.2.1(vite@4.3.4)(vue@3.2.47) + version: 4.2.1(vite@4.3.9)(vue@3.3.4) '@vitejs/plugin-vue-jsx': specifier: ^3.0.1 - version: 3.0.1(vite@4.3.4)(vue@3.2.47) + version: 3.0.1(vite@4.3.9)(vue@3.3.4) '@vue/babel-helper-vue-jsx-merge-props': specifier: ^1.4.0 version: 1.4.0 @@ -187,11 +191,11 @@ devDependencies: specifier: ^5.0.4 version: 5.0.4 vite: - specifier: ^4.3.4 - version: 4.3.4(@types/node@18.16.3)(sass@1.62.1)(terser@5.17.1) + specifier: ^4.3.9 + version: 4.3.9(@types/node@18.16.3)(sass@1.62.1)(terser@5.17.1) vite-plugin-eslint: specifier: ^1.8.1 - version: 1.8.1(eslint@8.39.0)(vite@4.3.4) + version: 1.8.1(eslint@8.39.0)(vite@4.3.9) vue-eslint-parser: specifier: ^9.2.0 version: 9.2.0(eslint@8.39.0) @@ -578,11 +582,11 @@ packages: /@babel/helper-string-parser@7.19.4: resolution: {integrity: sha512-nHtDoQcuqFmwYNYPz3Rah5ph2p8PFeFCsZk9A/48dPc/rGocJ5J3hAAZ7pb76VWX3fZKu+uEr/FhH5jLx7umrw==} engines: {node: '>=6.9.0'} + dev: true /@babel/helper-string-parser@7.21.5: resolution: {integrity: sha512-5pTUx3hAJaZIdW99sJ6ZUUgWq/Y+Hja7TowEnLNMm1VivRgZQL3vpBY3qUACVsvw+yQU6+YgfBVmcbLaZtrA1w==} engines: {node: '>=6.9.0'} - dev: true /@babel/helper-validator-identifier@7.19.1: resolution: {integrity: sha512-awrNfaMtnHUr653GgGEs++LlAvW6w+DcPrOliSMXWCKo597CwL5Acf/wWdNkf/tfEQE3mjkeD1YOVZOUV/od1w==} @@ -647,6 +651,7 @@ packages: hasBin: true dependencies: '@babel/types': 7.21.2 + dev: true /@babel/parser@7.21.8: resolution: {integrity: sha512-6zavDGdzG3gUqAdWvlLFfk+36RilI+Pwyuuh7HItyeScCWP3k6i8vKclAQ0bM/0y/Kz/xiwvxhMv9MgTJP5gmA==} @@ -654,7 +659,6 @@ packages: hasBin: true dependencies: '@babel/types': 7.21.5 - dev: true /@babel/plugin-bugfix-safari-id-destructuring-collision-in-function-expression@7.18.6(@babel/core@7.21.8): resolution: {integrity: sha512-Dgxsyg54Fx1d4Nge8UnvTrED63vrwOdPmyvPzlNN/boaliRP54pm3pGzZD1SJUwrBA+Cs/xdG8kXX6Mn/RfISQ==} @@ -1559,6 +1563,7 @@ packages: '@babel/helper-string-parser': 7.19.4 '@babel/helper-validator-identifier': 7.19.1 to-fast-properties: 2.0.0 + dev: true /@babel/types@7.21.5: resolution: {integrity: sha512-m4AfNvVF2mVC/F7fDEdH2El3HzUg9It/XsCxZiOTTA3m3qYfcSVSbTfM6Q9xG+hYDniZssYhlXKKUMD5m8tF4Q==} @@ -1567,7 +1572,6 @@ packages: '@babel/helper-string-parser': 7.21.5 '@babel/helper-validator-identifier': 7.19.1 to-fast-properties: 2.0.0 - dev: true /@commitlint/cli@17.6.1: resolution: {integrity: sha512-kCnDD9LE2ySiTnj/VPaxy4/oRayRcdv4aCuVxtoum8SxIU7OADHc0nJPQfheE8bHcs3zZdWzDMWltRosuT13bg==} @@ -1783,12 +1787,12 @@ packages: engines: {node: '>=10'} dev: false - /@element-plus/icons-vue@2.0.10(vue@3.2.47): + /@element-plus/icons-vue@2.0.10(vue@3.3.4): resolution: {integrity: sha512-ygEZ1mwPjcPo/OulhzLE7mtDrQBWI8vZzEWSNB2W/RNCRjoQGwbaK4N8lV4rid7Ts4qvySU3njMN7YCiSlSaTQ==} peerDependencies: vue: ^3.2.0 dependencies: - vue: 3.2.47 + vue: 3.3.4 dev: false /@esbuild/android-arm64@0.17.12: @@ -2030,8 +2034,8 @@ packages: resolution: {integrity: sha512-EvYTiXet5XqweYGClEmpu3BoxmsQ4hkj3QaYA6qEnigCWffTP3vNRwBReTdrwDwo7OoJ3wM8Uoe9Uk4n+d4hfg==} dev: false - /@floating-ui/dom@1.2.7: - resolution: {integrity: sha512-DyqylONj1ZaBnzj+uBnVfzdjjCkFCL2aA9ESHLyUOGSqb03RpbLMImP1ekIQXYs4KLk9jAjJfZAU8hXfWSahEg==} + /@floating-ui/dom@1.2.9: + resolution: {integrity: sha512-sosQxsqgxMNkV3C+3UqTS6LxP7isRLwX8WMepp843Rb3/b0Wz8+MdUkxJksByip3C2WwLugLHN1b4ibn//zKwQ==} dependencies: '@floating-ui/core': 1.2.6 dev: false @@ -2056,8 +2060,8 @@ packages: resolution: {integrity: sha512-ZnQMnLV4e7hDlUvw8H+U8ASL02SS2Gn6+9Ac3wGGLIe7+je2AeAOxPY+izIPJDfFDb7eDjev0Us8MO1iFRN8hA==} dev: true - /@ibiz-template/core@0.0.4-beta.5(axios@1.3.5)(lodash-es@4.17.21)(qs@6.11.1)(qx-util@0.4.8)(ramda@0.29.0): - resolution: {integrity: sha512-h1pffi9Lg4SBRNBVEJPrdICwnvu/8gRzP+8A3Qjhw78qXyxW0USE3IKF+aWMmXj8XArDsXDTPJbN1ugl+ieS2g==} + /@ibiz-template/core@0.0.4-beta.16(axios@1.4.0)(lodash-es@4.17.21)(qs@6.11.1)(qx-util@0.4.8)(ramda@0.29.0): + resolution: {integrity: sha512-GKQmO2oI3AFRJNJMtikGwCsfUB/PxYUACxok1Tq3Htc01/+OqtpHUc0QBWQokHCpcMnqd4vtqMHmK/2RkTMPnw==} peerDependencies: axios: ^1.3.5 lodash-es: ^4.17.21 @@ -2065,7 +2069,7 @@ packages: qx-util: ^0.4.8 ramda: ^0.29.0 dependencies: - axios: 1.3.5 + axios: 1.4.0 lodash-es: 4.17.21 loglevel: 1.8.1 qs: 6.11.1 @@ -2073,29 +2077,29 @@ packages: ramda: 0.29.0 dev: false - /@ibiz-template/default-view-layout@1.0.2: - resolution: {integrity: sha512-GxUNQ64FE7whBgQiN0mYVLOBqmi9Y04WSs3z0NUf9c3XLGXUX/fVaTeO/u8DYKaRLWXdabqnk4f7oXlylO6ijg==} + /@ibiz-template/default-view-layout@1.0.16: + resolution: {integrity: sha512-IZJm4Fx9tdordzZcZ+ssdk36XNiYE5Avmi5mPGR9rTSzMDAAPhstllyWRqfeiveMQL4YmENgn2JcoxVkjyUQMg==} dependencies: '@ibiz/model-core': 0.0.6 '@ibiz/rt-model-api': 0.0.1-beta.10 dev: false - /@ibiz-template/model-helper@0.0.4-beta.5(@ibiz-template/runtime@0.0.4-beta.5): - resolution: {integrity: sha512-csM3Bi6E6UdSd4qovm4ZwmSv5QCBnv9TDc7FFlv2dCzNQnL+/pTDGkhsNxEr3fZbuWONXsz7fbjF2qTy5JMEgg==} + /@ibiz-template/model-helper@0.0.4-beta.16(@ibiz-template/runtime@0.0.4-beta.16): + resolution: {integrity: sha512-h2gbV4gkUpilOvojxnFkpoVb/kkTkXBuftC3kZUAhby0NryBwQairG9DI8FNJr/CKlb3vXUL31jxNSwr8cPLiA==} peerDependencies: - '@ibiz-template/runtime': workspace:^0.0.4-beta.1 + '@ibiz-template/runtime': workspace:^0.0.4-beta.7 dependencies: - '@ibiz-template/runtime': 0.0.4-beta.5(@ibiz-template/core@0.0.4-beta.5)(@ibiz/model-core@0.0.7)(async-validator@4.2.5)(dayjs@1.11.7)(lodash-es@4.17.21)(qs@6.11.1)(qx-util@0.4.8)(ramda@0.29.0) - '@ibiz/model-core': 0.0.6 - '@ibiz/rt-model-api': 0.0.1-beta.10 + '@ibiz-template/runtime': 0.0.4-beta.16(@ibiz-template/core@0.0.4-beta.16)(@ibiz/model-core@0.0.10)(async-validator@4.2.5)(dayjs@1.11.7)(lodash-es@4.17.21)(qs@6.11.1)(qx-util@0.4.8)(ramda@0.29.0) + '@ibiz/model-core': 0.0.10 + '@ibiz/rt-model-api': 0.0.1-beta.14 pluralize: 8.0.0 dev: false - /@ibiz-template/runtime@0.0.4-beta.5(@ibiz-template/core@0.0.4-beta.5)(@ibiz/model-core@0.0.7)(async-validator@4.2.5)(dayjs@1.11.7)(lodash-es@4.17.21)(qs@6.11.1)(qx-util@0.4.8)(ramda@0.29.0): - resolution: {integrity: sha512-w+nxHWujl+TUQThxPZoFI0CLqSIikoGStomUOKDXergNAO010w/sLSTeVQL0N/zm9wMGVfqWFqM0Hqrk5afcdA==} + /@ibiz-template/runtime@0.0.4-beta.16(@ibiz-template/core@0.0.4-beta.16)(@ibiz/model-core@0.0.10)(async-validator@4.2.5)(dayjs@1.11.7)(lodash-es@4.17.21)(qs@6.11.1)(qx-util@0.4.8)(ramda@0.29.0): + resolution: {integrity: sha512-sL0uioeYyWvqgNs98wQ5YbE60T7x86KEyyALh1IYJ+JbYX3kL7b79vogPQvQMtDhUeqMvE+JbyYl7VkhW+EPZQ==} peerDependencies: '@ibiz-template/core': workspace:^0.0.4-beta.1 - '@ibiz/model-core': ^0.0.6 + '@ibiz/model-core': ^0.0.10 async-validator: ^4.2.5 dayjs: ^1.11.7 lodash-es: ^4.17.21 @@ -2103,8 +2107,8 @@ packages: qx-util: ^0.4.8 ramda: ^0.29.0 dependencies: - '@ibiz-template/core': 0.0.4-beta.5(axios@1.3.5)(lodash-es@4.17.21)(qs@6.11.1)(qx-util@0.4.8)(ramda@0.29.0) - '@ibiz/model-core': 0.0.7 + '@ibiz-template/core': 0.0.4-beta.16(axios@1.4.0)(lodash-es@4.17.21)(qs@6.11.1)(qx-util@0.4.8)(ramda@0.29.0) + '@ibiz/model-core': 0.0.10 async-validator: 4.2.5 dayjs: 1.11.7 lodash-es: 4.17.21 @@ -2113,80 +2117,89 @@ packages: ramda: 0.29.0 dev: false - /@ibiz-template/theme@0.0.4-beta.3: - resolution: {integrity: sha512-N8Nu6LsvG2Ar293oNZQ8ZbrnMJUy9I8ChbLA7WJ24gXZLfQJCIi9GzC1JFPQnq+SJF0gCxJv2ccUZa/zk2UEpA==} + /@ibiz-template/theme@0.0.4-beta.16: + resolution: {integrity: sha512-LW3I+XKL4dIMm8ziTwF7u4bqNz53KkQo/XthojckeLfd3Pna0rsvU60KgAf3HRYbvaE4X/rkfvlzrRrZCE7aUQ==} dev: false - /@ibiz-template/vue3-components@0.0.1-alpha.3(@ibiz-template/core@0.0.4-beta.5)(@ibiz-template/model-helper@0.0.4-beta.5)(@ibiz-template/runtime@0.0.4-beta.5)(@ibiz-template/vue3-util@0.0.4-beta.5)(@ibiz-template/vue3@0.0.1-alpha.1)(@ibiz/model-core@0.0.7)(qx-util@0.4.8)(vue-router@4.1.6)(vue@3.2.47): - resolution: {integrity: sha512-Q7teUpXSt0mQkPgPQln2S7avGGQ6yJHwY/3YT2odJY/gHps4+3wVuiu3cRDgsaoXjlTkoWvEeIdSzer2PoM3hg==} + /@ibiz-template/vue3-components@0.0.1-alpha.9(@floating-ui/dom@1.2.9)(@ibiz-template/core@0.0.4-beta.16)(@ibiz-template/model-helper@0.0.4-beta.16)(@ibiz-template/runtime@0.0.4-beta.16)(@ibiz-template/theme@0.0.4-beta.16)(@ibiz-template/vue3-util@0.0.4-beta.16)(@ibiz/model-core@0.0.10)(async-validator@4.2.5)(dayjs@1.11.7)(element-plus@2.3.4)(lodash-es@4.17.21)(nprogress@0.2.0)(pinia@2.1.3)(qs@6.11.1)(qx-util@0.4.8)(ramda@0.29.0)(vue-router@4.1.6)(vue@3.3.4): + resolution: {integrity: sha512-vKPsOzYo1agivGUCgvihAPuLTbtjAfB0l6jI+FQqsoi/ztI3ef87Uox0zNgjM+XzeHWH53FmXfZlUBZh+l4p9g==} peerDependencies: - '@ibiz-template/core': ^0.0.4-beta.2 - '@ibiz-template/model-helper': ^0.0.4-beta.2 - '@ibiz-template/runtime': ^0.0.4-beta.2 - '@ibiz-template/vue3': ^0.0.1-alpha.1 - '@ibiz-template/vue3-util': ^0.0.4-beta.2 - '@ibiz/model-core': ^0.0.4 + '@floating-ui/dom': ^1.2.9 + '@ibiz-template/core': ^0.0.4-beta.5 + '@ibiz-template/model-helper': ^0.0.4-beta.7 + '@ibiz-template/runtime': ^0.0.4-beta.7 + '@ibiz-template/theme': ^0.0.4-beta.3 + '@ibiz-template/vue3-util': ^0.0.4-beta.7 + '@ibiz/model-core': ^0.0.10 + async-validator: ^4.2.5 + dayjs: ^1.11.7 + element-plus: ^2.3.4 + lodash-es: ^4.17.21 + nprogress: ^0.2.0 + pinia: ^2.1.3 + qs: ^6.11.1 qx-util: ^0.4.8 - vue: ^3.2.47 - vue-router: ^4.1.6 - dependencies: - '@ibiz-template/core': 0.0.4-beta.5(axios@1.3.5)(lodash-es@4.17.21)(qs@6.11.1)(qx-util@0.4.8)(ramda@0.29.0) - '@ibiz-template/model-helper': 0.0.4-beta.5(@ibiz-template/runtime@0.0.4-beta.5) - '@ibiz-template/runtime': 0.0.4-beta.5(@ibiz-template/core@0.0.4-beta.5)(@ibiz/model-core@0.0.7)(async-validator@4.2.5)(dayjs@1.11.7)(lodash-es@4.17.21)(qs@6.11.1)(qx-util@0.4.8)(ramda@0.29.0) - '@ibiz-template/theme': 0.0.4-beta.3 - '@ibiz-template/vue3': 0.0.1-alpha.1 - '@ibiz-template/vue3-util': 0.0.4-beta.5(@ibiz-template/core@0.0.4-beta.5)(@ibiz-template/runtime@0.0.4-beta.5)(@ibiz/model-core@0.0.7)(qs@6.11.1)(qx-util@0.4.8)(ramda@0.29.0)(vue-router@4.1.6)(vue@3.2.47) - '@ibiz/model-core': 0.0.7 + ramda: ^0.29.0 + vue: ^3.3.2 + vue-router: ^4.2.0 + dependencies: + '@floating-ui/dom': 1.2.9 + '@ibiz-template/core': 0.0.4-beta.16(axios@1.4.0)(lodash-es@4.17.21)(qs@6.11.1)(qx-util@0.4.8)(ramda@0.29.0) + '@ibiz-template/model-helper': 0.0.4-beta.16(@ibiz-template/runtime@0.0.4-beta.16) + '@ibiz-template/runtime': 0.0.4-beta.16(@ibiz-template/core@0.0.4-beta.16)(@ibiz/model-core@0.0.10)(async-validator@4.2.5)(dayjs@1.11.7)(lodash-es@4.17.21)(qs@6.11.1)(qx-util@0.4.8)(ramda@0.29.0) + '@ibiz-template/theme': 0.0.4-beta.16 + '@ibiz-template/vue3-util': 0.0.4-beta.16(@ibiz-template/core@0.0.4-beta.16)(@ibiz-template/runtime@0.0.4-beta.16)(@ibiz/model-core@0.0.10)(qs@6.11.1)(qx-util@0.4.8)(ramda@0.29.0)(vue-router@4.1.6)(vue@3.3.4) + '@ibiz/model-core': 0.0.10 async-validator: 4.2.5 - element-plus: 2.3.4(vue@3.2.47) + dayjs: 1.11.7 + element-plus: 2.3.4(vue@3.3.4) lodash-es: 4.17.21 + nprogress: 0.2.0 + pinia: 2.1.3(typescript@5.0.4)(vue@3.3.4) + qs: 6.11.1 qx-util: 0.4.8 ramda: 0.29.0 - vue: 3.2.47 - vue-router: 4.1.6(vue@3.2.47) - transitivePeerDependencies: - - '@vue/composition-api' + vue: 3.3.4 + vue-router: 4.1.6(vue@3.3.4) dev: false - /@ibiz-template/vue3-util@0.0.4-beta.5(@ibiz-template/core@0.0.4-beta.5)(@ibiz-template/runtime@0.0.4-beta.5)(@ibiz/model-core@0.0.7)(qs@6.11.1)(qx-util@0.4.8)(ramda@0.29.0)(vue-router@4.1.6)(vue@3.2.47): - resolution: {integrity: sha512-N4Nv0+F+Wjg0BDTrc4CrllZCM3E6MhyhRovsRMPlAsftDYUZlUXaSgrKwzyYWme82iU8hOYws5zM4OYg3699kA==} + /@ibiz-template/vue3-util@0.0.4-beta.16(@ibiz-template/core@0.0.4-beta.16)(@ibiz-template/runtime@0.0.4-beta.16)(@ibiz/model-core@0.0.10)(qs@6.11.1)(qx-util@0.4.8)(ramda@0.29.0)(vue-router@4.1.6)(vue@3.3.4): + resolution: {integrity: sha512-gxQPDKsYjVDwoNvd+MdgB2QkjfIRv0DV2FzcsGMBRBgGcZROuwx7JvxFv0YS0Q8nwwMhu88kE+mImh8I9gNxWw==} peerDependencies: '@ibiz-template/core': workspace:^0.0.4-beta.1 '@ibiz-template/runtime': workspace:^0.0.4-beta.1 - '@ibiz/model-core': ^0.0.6 + '@ibiz/model-core': ^0.0.10 qs: ^6.11.1 qx-util: ^0.4.8 ramda: ^0.29.0 vue: ^3.2.47 vue-router: ^4.1.6 dependencies: - '@ibiz-template/core': 0.0.4-beta.5(axios@1.3.5)(lodash-es@4.17.21)(qs@6.11.1)(qx-util@0.4.8)(ramda@0.29.0) - '@ibiz-template/runtime': 0.0.4-beta.5(@ibiz-template/core@0.0.4-beta.5)(@ibiz/model-core@0.0.7)(async-validator@4.2.5)(dayjs@1.11.7)(lodash-es@4.17.21)(qs@6.11.1)(qx-util@0.4.8)(ramda@0.29.0) - '@ibiz/model-core': 0.0.7 + '@ibiz-template/core': 0.0.4-beta.16(axios@1.4.0)(lodash-es@4.17.21)(qs@6.11.1)(qx-util@0.4.8)(ramda@0.29.0) + '@ibiz-template/runtime': 0.0.4-beta.16(@ibiz-template/core@0.0.4-beta.16)(@ibiz/model-core@0.0.10)(async-validator@4.2.5)(dayjs@1.11.7)(lodash-es@4.17.21)(qs@6.11.1)(qx-util@0.4.8)(ramda@0.29.0) + '@ibiz/model-core': 0.0.10 qs: 6.11.1 qx-util: 0.4.8 ramda: 0.29.0 - vue: 3.2.47 - vue-router: 4.1.6(vue@3.2.47) + vue: 3.3.4 + vue-router: 4.1.6(vue@3.3.4) dev: false - /@ibiz-template/vue3@0.0.1-alpha.1: - resolution: {integrity: sha512-W4ksEK8b8xFQY6NRp/uXs4Dw9GWiafDIHuVZhlObjDgml/HnixP3FvphGeH2tkS/YxYCvlywbcTT1Y6F/TFopQ==} - dependencies: - vue: 3.2.47 + /@ibiz/model-core@0.0.10: + resolution: {integrity: sha512-MJz8w+f6VXQvl3/NlVIPKnX2eqKvoPTAnZ9kVlYUSj5nR9WUyg/bPQcTu0ONn6Va4XeaWRQyPrvJm0m2hJLQxA==} dev: false /@ibiz/model-core@0.0.6: resolution: {integrity: sha512-coLoWZ8CcROS1iUSdNnsw//Y/296vMpy5z3BnBFo7DwBgfS2WW0NmJPJyePUtCEZim6zH2+5RZxkv2GgdTXTjQ==} dev: false - /@ibiz/model-core@0.0.7: - resolution: {integrity: sha512-bVCPoQzkzOvg8IOuVN5KekN0bIHiXGmnmRlFCLDfasl8zzXWQprTlWTBAi0GofhOVgXj5reaEyzaGtKbsyV4Ag==} - dev: false - /@ibiz/rt-model-api@0.0.1-beta.10: resolution: {integrity: sha512-hHOBlmfgOk0fzbGA0DGoaRn3KCk9zjV6sZ2tKMBxjJDYmf9wQPqcM/h4ScLVtJvDDZgqryHhu4eX0qEhxYIt6w==} + /@ibiz/rt-model-api@0.0.1-beta.14: + resolution: {integrity: sha512-+5vSNPA2+lS530k4hcVaxxmjuYjr0Dsdp7Pw947ZK4tdNsiL1iN+jnor2741OlrOO30R8eM/8WaHUQpUEnTmtQ==} + dev: false + /@ibizlab/cli@0.1.57(@ibizlab/model@0.2.15): resolution: {integrity: sha512-7zzwJn9k5nRoLSZqKPm3/wO1S3xHie1pAQPAIX/ufT2X9Hn5VZP5wQOYReIP936EjS9IXTKnX6clgutXR3FwNA==} hasBin: true @@ -2344,7 +2357,6 @@ packages: /@jridgewell/sourcemap-codec@1.4.14: resolution: {integrity: sha512-XPSJHWmi394fuUuzDnGz1wiKqWfo1yXecHQMRf2l6hztTO+nPru658AyDngaBe7isIxEkRsPR3FZh+s7iVa4Uw==} - dev: true /@jridgewell/trace-mapping@0.3.17: resolution: {integrity: sha512-MCNzAp77qzKca9+W/+I0+sEpaUnZoeasnghNeVc41VZCEKaCH73Vq3BZZ/SzWIgrqE4H4ceI+p+b6C0mHf9T4g==} @@ -2608,7 +2620,7 @@ packages: eslint-visitor-keys: 3.4.0 dev: true - /@vitejs/plugin-legacy@4.0.3(terser@5.17.1)(vite@4.3.4): + /@vitejs/plugin-legacy@4.0.3(terser@5.17.1)(vite@4.3.9): resolution: {integrity: sha512-RqDQOSEmFSNL42vITkNp8HE8Ak1yjGgaav4B6BGcZ8/URK0wikzwSyhNRirHDkp+snflEEk7iPZXTXUYA9exbg==} engines: {node: ^14.18.0 || >=16.0.0} peerDependencies: @@ -2623,12 +2635,12 @@ packages: regenerator-runtime: 0.13.11 systemjs: 6.14.1 terser: 5.17.1 - vite: 4.3.4(@types/node@18.16.3)(sass@1.62.1)(terser@5.17.1) + vite: 4.3.9(@types/node@18.16.3)(sass@1.62.1)(terser@5.17.1) transitivePeerDependencies: - supports-color dev: true - /@vitejs/plugin-vue-jsx@3.0.1(vite@4.3.4)(vue@3.2.47): + /@vitejs/plugin-vue-jsx@3.0.1(vite@4.3.9)(vue@3.3.4): resolution: {integrity: sha512-+Jb7ggL48FSPS1uhPnJbJwWa9Sr90vQ+d0InW+AhBM22n+cfuYqJZDckBc+W3QSHe1WDvewMZfa4wZOtk5pRgw==} engines: {node: ^14.18.0 || >=16.0.0} peerDependencies: @@ -2638,21 +2650,21 @@ packages: '@babel/core': 7.21.0 '@babel/plugin-transform-typescript': 7.21.3(@babel/core@7.21.0) '@vue/babel-plugin-jsx': 1.1.1(@babel/core@7.21.0) - vite: 4.3.4(@types/node@18.16.3)(sass@1.62.1)(terser@5.17.1) - vue: 3.2.47 + vite: 4.3.9(@types/node@18.16.3)(sass@1.62.1)(terser@5.17.1) + vue: 3.3.4 transitivePeerDependencies: - supports-color dev: true - /@vitejs/plugin-vue@4.2.1(vite@4.3.4)(vue@3.2.47): + /@vitejs/plugin-vue@4.2.1(vite@4.3.9)(vue@3.3.4): resolution: {integrity: sha512-ZTZjzo7bmxTRTkb8GSTwkPOYDIP7pwuyV+RV53c9PYUouwcbkIZIvWvNWlX2b1dYZqtOv7D6iUAnJLVNGcLrSw==} engines: {node: ^14.18.0 || >=16.0.0} peerDependencies: vite: ^4.0.0 vue: ^3.2.25 dependencies: - vite: 4.3.4(@types/node@18.16.3)(sass@1.62.1)(terser@5.17.1) - vue: 3.2.47 + vite: 4.3.9(@types/node@18.16.3)(sass@1.62.1)(terser@5.17.1) + vue: 3.3.4 dev: true /@volar/language-core@1.4.1: @@ -2681,10 +2693,10 @@ packages: dependencies: '@volar/language-core': 1.4.1 '@volar/source-map': 1.4.1 - '@vue/compiler-dom': 3.3.0-beta.3 - '@vue/compiler-sfc': 3.3.0-beta.3 + '@vue/compiler-dom': 3.3.4 + '@vue/compiler-sfc': 3.3.4 '@vue/reactivity': 3.3.0-beta.3 - '@vue/shared': 3.3.0-beta.3 + '@vue/shared': 3.3.4 minimatch: 9.0.0 muggle-string: 0.2.2 vue-template-compiler: 2.7.14 @@ -2725,77 +2737,39 @@ packages: - supports-color dev: true - /@vue/compiler-core@3.2.47: - resolution: {integrity: sha512-p4D7FDnQb7+YJmO2iPEv0SQNeNzcbHdGByJDsT4lynf63AFkOTFN07HsiRSvjGo0QrxR/o3d0hUyNCUnBU2Tig==} - dependencies: - '@babel/parser': 7.21.2 - '@vue/shared': 3.2.47 - estree-walker: 2.0.2 - source-map: 0.6.1 - - /@vue/compiler-core@3.3.0-beta.3: - resolution: {integrity: sha512-mv2rPo4JHou6ebm7+U/wO1HpA6W1zDfTqbt4fqjoXrMwU4DWNgRcLKTXG6G3cXV4mOe+2YgWspfxEzo7fPTMKg==} + /@vue/compiler-core@3.3.4: + resolution: {integrity: sha512-cquyDNvZ6jTbf/+x+AgM2Arrp6G4Dzbb0R64jiG804HRMfRiFXWI6kqUVqZ6ZR0bQhIoQjB4+2bhNtVwndW15g==} dependencies: '@babel/parser': 7.21.8 - '@vue/shared': 3.3.0-beta.3 + '@vue/shared': 3.3.4 estree-walker: 2.0.2 source-map-js: 1.0.2 - dev: true - - /@vue/compiler-dom@3.2.47: - resolution: {integrity: sha512-dBBnEHEPoftUiS03a4ggEig74J2YBZ2UIeyfpcRM2tavgMWo4bsEfgCGsu+uJIL/vax9S+JztH8NmQerUo7shQ==} - dependencies: - '@vue/compiler-core': 3.2.47 - '@vue/shared': 3.2.47 - - /@vue/compiler-dom@3.3.0-beta.3: - resolution: {integrity: sha512-e7VpjN9wYiuJdJos6Uoe501CzdMkfaEr/27Ks4Ss7Irtcj5YA/S1OROZ35Xl2Pc3ctx6beq5RpcOvnMqh0hcaA==} - dependencies: - '@vue/compiler-core': 3.3.0-beta.3 - '@vue/shared': 3.3.0-beta.3 - dev: true - /@vue/compiler-sfc@3.2.47: - resolution: {integrity: sha512-rog05W+2IFfxjMcFw10tM9+f7i/+FFpZJJ5XHX72NP9eC2uRD+42M3pYcQqDXVYoj74kHMSEdQ/WmCjt8JFksQ==} + /@vue/compiler-dom@3.3.4: + resolution: {integrity: sha512-wyM+OjOVpuUukIq6p5+nwHYtj9cFroz9cwkfmP9O1nzH68BenTTv0u7/ndggT8cIQlnBeOo6sUT/gvHcIkLA5w==} dependencies: - '@babel/parser': 7.21.2 - '@vue/compiler-core': 3.2.47 - '@vue/compiler-dom': 3.2.47 - '@vue/compiler-ssr': 3.2.47 - '@vue/reactivity-transform': 3.2.47 - '@vue/shared': 3.2.47 - estree-walker: 2.0.2 - magic-string: 0.25.9 - postcss: 8.4.23 - source-map: 0.6.1 + '@vue/compiler-core': 3.3.4 + '@vue/shared': 3.3.4 - /@vue/compiler-sfc@3.3.0-beta.3: - resolution: {integrity: sha512-6shZNooetShjSMHJvgVoE0EM8pOMV5vnrzsHoCU06stzV+kqRJQpbN7xf2s9wK2fgHMIBSMINrM9AuZiQnNCJg==} + /@vue/compiler-sfc@3.3.4: + resolution: {integrity: sha512-6y/d8uw+5TkCuzBkgLS0v3lSM3hJDntFEiUORM11pQ/hKvkhSKZrXW6i69UyXlJQisJxuUEJKAWEqWbWsLeNKQ==} dependencies: '@babel/parser': 7.21.8 - '@vue/compiler-core': 3.3.0-beta.3 - '@vue/compiler-dom': 3.3.0-beta.3 - '@vue/compiler-ssr': 3.3.0-beta.3 - '@vue/reactivity-transform': 3.3.0-beta.3 - '@vue/shared': 3.3.0-beta.3 + '@vue/compiler-core': 3.3.4 + '@vue/compiler-dom': 3.3.4 + '@vue/compiler-ssr': 3.3.4 + '@vue/reactivity-transform': 3.3.4 + '@vue/shared': 3.3.4 estree-walker: 2.0.2 magic-string: 0.30.0 postcss: 8.4.23 source-map-js: 1.0.2 - dev: true - - /@vue/compiler-ssr@3.2.47: - resolution: {integrity: sha512-wVXC+gszhulcMD8wpxMsqSOpvDZ6xKXSVWkf50Guf/S+28hTAXPDYRTbLQ3EDkOP5Xz/+SY37YiwDquKbJOgZw==} - dependencies: - '@vue/compiler-dom': 3.2.47 - '@vue/shared': 3.2.47 - /@vue/compiler-ssr@3.3.0-beta.3: - resolution: {integrity: sha512-egJ0lEVAod3Hpnw96cJ/0a9qv5f5h5/VCBpKYT8scqkzoMsikh8AJant2omokBCL/Ut5UAMLVQlA5b66+2Ys/g==} + /@vue/compiler-ssr@3.3.4: + resolution: {integrity: sha512-m0v6oKpup2nMSehwA6Uuu+j+wEwcy7QmwMkVNVfrV9P2qE5KshC6RwOCq8fjGS/Eak/uNb8AaWekfiXxbBB6gQ==} dependencies: - '@vue/compiler-dom': 3.3.0-beta.3 - '@vue/shared': 3.3.0-beta.3 - dev: true + '@vue/compiler-dom': 3.3.4 + '@vue/shared': 3.3.4 /@vue/devtools-api@6.4.5: resolution: {integrity: sha512-JD5fcdIuFxU4fQyXUu3w2KpAJHzTVdN+p4iOX2lMWSHMOoQdMAcpFLZzm9Z/2nmsoZ1a96QEhZ26e50xLBsgOQ==} @@ -2805,29 +2779,14 @@ packages: resolution: {integrity: sha512-o9KfBeaBmCKl10usN4crU53fYtC1r7jJwdGKjPT24t348rHxgfpZ0xL3Xm/gLUYnc0oTp8LAmrxOeLyu6tbk2Q==} dev: false - /@vue/reactivity-transform@3.2.47: - resolution: {integrity: sha512-m8lGXw8rdnPVVIdIFhf0LeQ/ixyHkH5plYuS83yop5n7ggVJU+z5v0zecwEnX7fa7HNLBhh2qngJJkxpwEEmYA==} - dependencies: - '@babel/parser': 7.21.2 - '@vue/compiler-core': 3.2.47 - '@vue/shared': 3.2.47 - estree-walker: 2.0.2 - magic-string: 0.25.9 - - /@vue/reactivity-transform@3.3.0-beta.3: - resolution: {integrity: sha512-aM3TgBca9QMMu/9B9ASRVvckeZpAdJO9nmQh5UCznhoDYjVxQPS+sCQvH6TLOjPB1MDQMVQYg4ZiPqfVVo7NbA==} + /@vue/reactivity-transform@3.3.4: + resolution: {integrity: sha512-MXgwjako4nu5WFLAjpBnCj/ieqcjE2aJBINUNQzkZQfzIZA4xn+0fV1tIYBJvvva3N3OvKGofRLvQIwEQPpaXw==} dependencies: '@babel/parser': 7.21.8 - '@vue/compiler-core': 3.3.0-beta.3 - '@vue/shared': 3.3.0-beta.3 + '@vue/compiler-core': 3.3.4 + '@vue/shared': 3.3.4 estree-walker: 2.0.2 magic-string: 0.30.0 - dev: true - - /@vue/reactivity@3.2.47: - resolution: {integrity: sha512-7khqQ/75oyyg+N/e+iwV6lpy1f5wq759NdlS1fpAhFXa8VeAIKGgk2E/C4VF59lx5b+Ezs5fpp/5WsRYXQiKxQ==} - dependencies: - '@vue/shared': 3.2.47 /@vue/reactivity@3.3.0-beta.3: resolution: {integrity: sha512-9VjWfWgZJ18YXEkfnDfZr33RyLBa6zc0RARLkMqMApWvM26eusZAZ4hhyxlgODBU/mEFk4XOGIAtwwSQedA0MQ==} @@ -2835,42 +2794,47 @@ packages: '@vue/shared': 3.3.0-beta.3 dev: true - /@vue/runtime-core@3.2.47: - resolution: {integrity: sha512-RZxbLQIRB/K0ev0K9FXhNbBzT32H9iRtYbaXb0ZIz2usLms/D55dJR2t6cIEUn6vyhS3ALNvNthI+Q95C+NOpA==} + /@vue/reactivity@3.3.4: + resolution: {integrity: sha512-kLTDLwd0B1jG08NBF3R5rqULtv/f8x3rOFByTDz4J53ttIQEDmALqKqXY0J+XQeN0aV2FBxY8nJDf88yvOPAqQ==} dependencies: - '@vue/reactivity': 3.2.47 - '@vue/shared': 3.2.47 + '@vue/shared': 3.3.4 - /@vue/runtime-dom@3.2.47: - resolution: {integrity: sha512-ArXrFTjS6TsDei4qwNvgrdmHtD930KgSKGhS5M+j8QxXrDJYLqYw4RRcDy1bz1m1wMmb6j+zGLifdVHtkXA7gA==} + /@vue/runtime-core@3.3.4: + resolution: {integrity: sha512-R+bqxMN6pWO7zGI4OMlmvePOdP2c93GsHFM/siJI7O2nxFRzj55pLwkpCedEY+bTMgp5miZ8CxfIZo3S+gFqvA==} dependencies: - '@vue/runtime-core': 3.2.47 - '@vue/shared': 3.2.47 - csstype: 2.6.21 + '@vue/reactivity': 3.3.4 + '@vue/shared': 3.3.4 - /@vue/server-renderer@3.2.47(vue@3.2.47): - resolution: {integrity: sha512-dN9gc1i8EvmP9RCzvneONXsKfBRgqFeFZLurmHOveL7oH6HiFXJw5OGu294n1nHc/HMgTy6LulU/tv5/A7f/LA==} - peerDependencies: - vue: 3.2.47 + /@vue/runtime-dom@3.3.4: + resolution: {integrity: sha512-Aj5bTJ3u5sFsUckRghsNjVTtxZQ1OyMWCr5dZRAPijF/0Vy4xEoRCwLyHXcj4D0UFbJ4lbx3gPTgg06K/GnPnQ==} dependencies: - '@vue/compiler-ssr': 3.2.47 - '@vue/shared': 3.2.47 - vue: 3.2.47 + '@vue/runtime-core': 3.3.4 + '@vue/shared': 3.3.4 + csstype: 3.1.2 - /@vue/shared@3.2.47: - resolution: {integrity: sha512-BHGyyGN3Q97EZx0taMQ+OLNuZcW3d37ZEVmEAyeoA9ERdGvm9Irc/0Fua8SNyOtV1w6BS4q25wbMzJujO9HIfQ==} + /@vue/server-renderer@3.3.4(vue@3.3.4): + resolution: {integrity: sha512-Q6jDDzR23ViIb67v+vM1Dqntu+HUexQcsWKhhQa4ARVzxOY2HbC7QRW/ggkDBd5BU+uM1sV6XOAP0b216o34JQ==} + peerDependencies: + vue: 3.3.4 + dependencies: + '@vue/compiler-ssr': 3.3.4 + '@vue/shared': 3.3.4 + vue: 3.3.4 /@vue/shared@3.3.0-beta.3: resolution: {integrity: sha512-st1SnB/Bkbb9TsieeI4TRX9TqHYIR5wvIma3ZtEben55EYSWa1q5u2BhTNgABSdH+rv3Xwfrvpwh5PmCw6Y53g==} dev: true - /@vueuse/core@9.9.0(vue@3.2.47): + /@vue/shared@3.3.4: + resolution: {integrity: sha512-7OjdcV8vQ74eiz1TZLzZP4JwqM5fA94K6yntPS5Z25r9HDuGNzaGdgvwKYq6S+MxwF0TFRwe50fIR/MYnakdkQ==} + + /@vueuse/core@9.9.0(vue@3.3.4): resolution: {integrity: sha512-JdDb7TrE0imZnwBhMF4+0PCJqGD3AxzH8S2sfk54P0rqvklK+EAtAR/mPb1HwV/JPujQFQJhghQ190Yq03YpVw==} dependencies: '@types/web-bluetooth': 0.0.16 '@vueuse/metadata': 9.9.0 - '@vueuse/shared': 9.9.0(vue@3.2.47) - vue-demi: 0.13.8(vue@3.2.47) + '@vueuse/shared': 9.9.0(vue@3.3.4) + vue-demi: 0.13.8(vue@3.3.4) transitivePeerDependencies: - '@vue/composition-api' - vue @@ -2880,10 +2844,10 @@ packages: resolution: {integrity: sha512-pgxsUJv/d7IjKpLeB6TthggEsaBwM3ffc5jPrr5TmxAm/fup0mGR5VTzrdA/PSx85tpb+CIvP92D+55qBNc8ag==} dev: false - /@vueuse/shared@9.9.0(vue@3.2.47): + /@vueuse/shared@9.9.0(vue@3.3.4): resolution: {integrity: sha512-+D0XFwHG0T+uaIbCSlROBwm1wzs71B7n3KyDOxnvfEMMHDOzl09rYKwaE2AENmYwYPXfHPbSBRDD2gBVHbvTcg==} dependencies: - vue-demi: 0.13.8(vue@3.2.47) + vue-demi: 0.14.5(vue@3.3.4) transitivePeerDependencies: - '@vue/composition-api' - vue @@ -3069,8 +3033,8 @@ packages: engines: {node: '>= 0.4'} dev: true - /axios@1.3.5: - resolution: {integrity: sha512-glL/PvG/E+xCWwV8S6nCHcrfg1exGx7vxyUIivIA1iL7BIh6bePylCfVHwp6k13ao7SATxB6imau2kqY+I67kw==} + /axios@1.4.0: + resolution: {integrity: sha512-S4XCWMEmzvo64T9GfvQDOXgYRDJ/wsSZc7Jvdgx5u1sd0JwsuPLqb3SYmusag+edF6ziyMensPVqLTSc1PiSEA==} dependencies: follow-redirects: 1.15.2 form-data: 4.0.0 @@ -3452,8 +3416,8 @@ packages: hasBin: true dev: true - /csstype@2.6.21: - resolution: {integrity: sha512-Z1PhmomIfypOpoMjRQB70jfvy/wxT50qW08YXO5lMIJkrdq4yOTR+AW7FqutScmB9NkLwxo+jU+kZLbofZZq/w==} + /csstype@3.1.2: + resolution: {integrity: sha512-I7K1Uu0MBPzaFKg4nI5Q7Vs2t+3gWWW648spaF+Rg7pI9ds18Ugn+lvg4SHczUdKlHI5LWBXyqfS8+DufyBsgQ==} /dargs@7.0.0: resolution: {integrity: sha512-2iy1EkLdlBzQGvbweYRFxmFath8+K7+AKB0TlhHWkNuH+TmovaMH/Wp7V7R4u7f4SnX3OgLsU9t1NI9ioDnUpg==} @@ -3575,18 +3539,18 @@ packages: resolution: {integrity: sha512-h70iRscrNluMZPVICXYl5SSB+rBKo22XfuIS1ER0OQxQZpKTnFpuS6coj7wY9M/3trv7OR88rRMOlKmRvDty7Q==} dev: true - /element-plus@2.3.4(vue@3.2.47): + /element-plus@2.3.4(vue@3.3.4): resolution: {integrity: sha512-SQr0J9z7N4z48WYk/l9NE2tizl8Q7j2OhqlpTc42k4pGncry3+rVX6dsmcsglFynn6vt3NzYxWJqmLFyDKQq+g==} peerDependencies: vue: ^3.2.0 dependencies: '@ctrl/tinycolor': 3.5.0 - '@element-plus/icons-vue': 2.0.10(vue@3.2.47) - '@floating-ui/dom': 1.2.7 + '@element-plus/icons-vue': 2.0.10(vue@3.3.4) + '@floating-ui/dom': 1.2.9 '@popperjs/core': /@sxzz/popperjs-es@2.11.7 '@types/lodash': 4.14.184 '@types/lodash-es': 4.17.7 - '@vueuse/core': 9.9.0(vue@3.2.47) + '@vueuse/core': 9.9.0(vue@3.3.4) async-validator: 4.2.5 dayjs: 1.11.7 escape-html: 1.0.3 @@ -3595,7 +3559,7 @@ packages: lodash-unified: 1.0.3(@types/lodash-es@4.17.7)(lodash-es@4.17.21)(lodash@4.17.21) memoize-one: 6.0.0 normalize-wheel-es: 1.2.0 - vue: 3.2.47 + vue: 3.3.4 transitivePeerDependencies: - '@vue/composition-api' dev: false @@ -4995,17 +4959,11 @@ packages: engines: {node: 14 || >=16.14} dev: true - /magic-string@0.25.9: - resolution: {integrity: sha512-RmF0AsMzgt25qzqqLc1+MbHmhdx0ojF2Fvs4XnOqz2ZOBXzzkEwc/dJQZCYHAn7v1jbVOjAZfK8msRn4BxO4VQ==} - dependencies: - sourcemap-codec: 1.4.8 - /magic-string@0.30.0: resolution: {integrity: sha512-LA+31JYDJLs82r2ScLrlz1GjSgu66ZV518eyWT+S8VhyQn/JL0u9MeBOvQMGYiPk1DBiSN9DDMOcXvigJZaViQ==} engines: {node: '>=12'} dependencies: '@jridgewell/sourcemap-codec': 1.4.14 - dev: true /make-error@1.3.6: resolution: {integrity: sha512-s8UhlNe7vPKomQhC1qFelMokr/Sc3AgNbso3n74mVPA5LTZwkB9NlXf4XPamLxJE8h0gh73rM94xvwRT2CVInw==} @@ -5460,12 +5418,12 @@ packages: hasBin: true dev: true - /pinia@2.0.35(typescript@5.0.4)(vue@3.2.47): - resolution: {integrity: sha512-P1IKKQWhxGXiiZ3atOaNI75bYlFUbRxtJdhPLX059Z7+b9Z04rnTZdSY8Aph1LA+/4QEMAYHsTQ638Wfe+6K5g==} + /pinia@2.1.3(typescript@5.0.4)(vue@3.3.4): + resolution: {integrity: sha512-XNA/z/ye4P5rU1pieVmh0g/hSuDO98/a5UC8oSP0DNdvt6YtetJNHTrXwpwsQuflkGT34qKxAEcp7lSxXNjf/A==} peerDependencies: '@vue/composition-api': ^1.4.0 typescript: '>=4.4.4' - vue: ^2.6.14 || ^3.2.0 + vue: ^2.6.14 || ^3.3.0 peerDependenciesMeta: '@vue/composition-api': optional: true @@ -5474,8 +5432,8 @@ packages: dependencies: '@vue/devtools-api': 6.5.0 typescript: 5.0.4 - vue: 3.2.47 - vue-demi: 0.13.8(vue@3.2.47) + vue: 3.3.4 + vue-demi: 0.14.5(vue@3.3.4) dev: false /pluralize@8.0.0: @@ -5934,10 +5892,6 @@ packages: engines: {node: '>= 8'} dev: true - /sourcemap-codec@1.4.8: - resolution: {integrity: sha512-9NykojV5Uih4lgo5So5dtw+f0JgJX30KCNI8gwhz2J9A15wD0Ml6tjHKwf6fTSa6fAdVBdZeNOs9eJ71qCk8vA==} - deprecated: Please use @jridgewell/sourcemap-codec instead - /spdx-correct@3.1.1: resolution: {integrity: sha512-cOYcUWwhCuHCXi49RhFRCyJEK3iPj1Ziz9DpViV3tbZOwXD49QzIN3MpOLJNxh2qwq2lJJZaKMVw9qNi4jTC0w==} dependencies: @@ -6516,7 +6470,7 @@ packages: spdx-expression-parse: 3.0.1 dev: true - /vite-plugin-eslint@1.8.1(eslint@8.39.0)(vite@4.3.4): + /vite-plugin-eslint@1.8.1(eslint@8.39.0)(vite@4.3.9): resolution: {integrity: sha512-PqdMf3Y2fLO9FsNPmMX+//2BF5SF8nEWspZdgl4kSt7UvHDRHVVfHvxsD7ULYzZrJDGRxR81Nq7TOFgwMnUang==} peerDependencies: eslint: '>=7' @@ -6526,11 +6480,11 @@ packages: '@types/eslint': 8.4.5 eslint: 8.39.0 rollup: 2.78.1 - vite: 4.3.4(@types/node@18.16.3)(sass@1.62.1)(terser@5.17.1) + vite: 4.3.9(@types/node@18.16.3)(sass@1.62.1)(terser@5.17.1) dev: true - /vite@4.3.4(@types/node@18.16.3)(sass@1.62.1)(terser@5.17.1): - resolution: {integrity: sha512-f90aqGBoxSFxWph2b39ae2uHAxm5jFBBdnfueNxZAT1FTpM13ccFQExCaKbR2xFW5atowjleRniQ7onjJ22QEg==} + /vite@4.3.9(@types/node@18.16.3)(sass@1.62.1)(terser@5.17.1): + resolution: {integrity: sha512-qsTNZjO9NoJNW7KnOrgYwczm0WctJ8m/yqYAMAK9Lxt4SoySUfS5S8ia9K7JHpa3KEeMfyF8LoJ3c5NeBJy6pg==} engines: {node: ^14.18.0 || >=16.0.0} hasBin: true peerDependencies: @@ -6564,7 +6518,7 @@ packages: fsevents: 2.3.2 dev: true - /vue-demi@0.13.8(vue@3.2.47): + /vue-demi@0.13.8(vue@3.3.4): resolution: {integrity: sha512-Vy1zbZhCOdsmvGR6tJhAvO5vhP7eiS8xkbYQSoVa7o6KlIy3W8Rc53ED4qI4qpeRDjv3mLfXSEpYU6Yq4pgXRg==} engines: {node: '>=12'} hasBin: true @@ -6576,7 +6530,22 @@ packages: '@vue/composition-api': optional: true dependencies: - vue: 3.2.47 + vue: 3.3.4 + dev: false + + /vue-demi@0.14.5(vue@3.3.4): + resolution: {integrity: sha512-o9NUVpl/YlsGJ7t+xuqJKx8EBGf1quRhCiT6D/J0pfwmk9zUwYkC7yrF4SZCe6fETvSM3UNL2edcbYrSyc4QHA==} + engines: {node: '>=12'} + hasBin: true + requiresBuild: true + peerDependencies: + '@vue/composition-api': ^1.0.0-rc.1 + vue: ^3.0.0-0 || ^2.6.0 + peerDependenciesMeta: + '@vue/composition-api': + optional: true + dependencies: + vue: 3.3.4 dev: false /vue-eslint-parser@9.2.0(eslint@8.39.0): @@ -6597,7 +6566,7 @@ packages: - supports-color dev: true - /vue-i18n@9.2.2(vue@3.2.47): + /vue-i18n@9.2.2(vue@3.3.4): resolution: {integrity: sha512-yswpwtj89rTBhegUAv9Mu37LNznyu3NpyLQmozF3i1hYOhwpG8RjcjIFIIfnu+2MDZJGSZPXaKWvnQA71Yv9TQ==} engines: {node: '>= 14'} peerDependencies: @@ -6607,16 +6576,16 @@ packages: '@intlify/shared': 9.2.2 '@intlify/vue-devtools': 9.2.2 '@vue/devtools-api': 6.4.5 - vue: 3.2.47 + vue: 3.3.4 dev: false - /vue-router@4.1.6(vue@3.2.47): + /vue-router@4.1.6(vue@3.3.4): resolution: {integrity: sha512-DYWYwsG6xNPmLq/FmZn8Ip+qrhFEzA14EI12MsMgVxvHFDYvlr4NXpVF5hrRH1wVcDP8fGi5F4rxuJSl8/r+EQ==} peerDependencies: vue: ^3.2.0 dependencies: '@vue/devtools-api': 6.4.5 - vue: 3.2.47 + vue: 3.3.4 dev: false /vue-template-compiler@2.7.14: @@ -6638,22 +6607,22 @@ packages: typescript: 5.0.4 dev: true - /vue@3.2.47: - resolution: {integrity: sha512-60188y/9Dc9WVrAZeUVSDxRQOZ+z+y5nO2ts9jWXSTkMvayiWxCWOWtBQoYjLeccfXkiiPZWAHcV+WTPhkqJHQ==} + /vue@3.3.4: + resolution: {integrity: sha512-VTyEYn3yvIeY1Py0WaYGZsXnz3y5UnGi62GjVEqvEGPl6nxbOrCXbVOTQWBEJUqAyTUk2uJ5JLVnYJ6ZzGbrSw==} dependencies: - '@vue/compiler-dom': 3.2.47 - '@vue/compiler-sfc': 3.2.47 - '@vue/runtime-dom': 3.2.47 - '@vue/server-renderer': 3.2.47(vue@3.2.47) - '@vue/shared': 3.2.47 + '@vue/compiler-dom': 3.3.4 + '@vue/compiler-sfc': 3.3.4 + '@vue/runtime-dom': 3.3.4 + '@vue/server-renderer': 3.3.4(vue@3.3.4) + '@vue/shared': 3.3.4 - /vuedraggable@4.1.0(vue@3.2.47): + /vuedraggable@4.1.0(vue@3.3.4): resolution: {integrity: sha512-FU5HCWBmsf20GpP3eudURW3WdWTKIbEIQxh9/8GE806hydR9qZqRRxRE3RjqX7PkuLuMQG/A7n3cfj9rCEchww==} peerDependencies: vue: ^3.0.1 dependencies: sortablejs: 1.14.0 - vue: 3.2.47 + vue: 3.3.4 dev: false /which-boxed-primitive@1.0.2: diff --git a/public/environments/environment.js b/public/environments/environment.js index c57644e..5520663 100644 --- a/public/environments/environment.js +++ b/public/environments/environment.js @@ -9,8 +9,11 @@ window.Environment = { // appId: 'centralstudio__centralstudio', // mockDcSystemId: 'demo-centralstudio', // mockDcSystemId: '941127f9d839f87308f1c4db3b0a2de4', - appId: 'trainsys__web', - mockDcSystemId: '84847aa970ba3db7bbe00754aed3888d', + // appId: 'trainsys__web', + // mockDcSystemId: '84847aa970ba3db7bbe00754aed3888d', // 应用标题 AppTitle: '应用首页', + appId: 'ibizdemoold__sample', + mockDcSystemId: 'ibizdemoold', + }; diff --git a/src/create-vue-app.ts b/src/create-vue-app.ts index 9d5fe79..5930aa5 100644 --- a/src/create-vue-app.ts +++ b/src/create-vue-app.ts @@ -1,11 +1,10 @@ +import { piniaInstance } from '@ibiz-template/vue3-components'; import { App, Component, createApp } from 'vue'; import ElementPlus from 'element-plus'; import zhCn from 'element-plus/dist/locale/zh-cn.mjs'; import { AppRegister } from './app-register'; import UserRegister from './user-register'; -import { piniaInstance } from './store'; import { i18n } from './locale'; - /** * 创建 vue3 实例,避免多实例情况下全局方法未成功挂载 * @@ -27,7 +26,15 @@ export function createVueApp( app.use(ElementPlus, { locale: zhCn, }); - + // 模态等销毁的时候删除全局的app + if (rootProps) { + const oldUnMounted = rootProps.unmounted; + // eslint-disable-next-line no-param-reassign + rootProps.unmounted = () => { + oldUnMounted(); + window.vueInstances.delete(app); + }; + } app.use(piniaInstance); app.use(AppRegister); app.use(UserRegister); diff --git a/src/guard/unauthorized-handler/unauthorized-handler.ts b/src/guard/unauthorized-handler/unauthorized-handler.ts index e5661cb..6b475ff 100644 --- a/src/guard/unauthorized-handler/unauthorized-handler.ts +++ b/src/guard/unauthorized-handler/unauthorized-handler.ts @@ -1,6 +1,5 @@ import qs from 'qs'; import { LoginMode, RuntimeError, UrlHelper } from '@ibiz-template/core'; -import { AppRouter } from '@/router'; /** * 没有权限的处理器 @@ -63,8 +62,9 @@ export class UnauthorizedHandler { */ protected static async normalLogin(): Promise { const ru = window.location.hash.replace('#', ''); - const router = AppRouter.getRouter(); - router.push({ path: '/login', query: { ru } }); + const targetUrl = `${UrlHelper.routeBase}/login?ru=${ru}`; + // 跳转登录地址 + window.location.href = targetUrl; } /** diff --git a/src/main.ts b/src/main.ts index 588317a..bdaf8f8 100644 --- a/src/main.ts +++ b/src/main.ts @@ -2,21 +2,22 @@ import '@ibiz-template/theme/style/index.scss'; import { install as installCore } from '@ibiz-template/core'; import { install as installRuntime } from '@ibiz-template/runtime'; import { install as installDefaultViewLayout } from '@ibiz-template/default-view-layout'; -import App from './App'; import { - ErrorHandler, LoadingUtil, MessageUtil, ModalUtil, NotificationUtil, OpenViewUtil, OverlayController, -} from './util'; + OverlayContainer, +} from '@ibiz-template/vue3-components'; +import App from './App'; import { attachEnvironmentConfig } from './attach-environment-config'; import { PluginFactory } from './plugin'; import { createVueApp } from './create-vue-app'; import { AppRouter } from '@/router'; import '@ibiz/model-core'; +import { ErrorHandler } from './util'; async function createApp(): Promise { window.vueInstances = new Map(); @@ -28,6 +29,7 @@ async function createApp(): Promise { ibiz.plugin = new PluginFactory(); const app = createVueApp(App); + OverlayContainer.createVueApp = createVueApp; // 全局 Vue 异常处理 app.config.errorHandler = function (err: unknown) { @@ -60,7 +62,7 @@ async function createApp(): Promise { await attachEnvironmentConfig(); app.use(AppRouter.getRouter()); - ibiz.openView = new OpenViewUtil(); + ibiz.openView = new OpenViewUtil(AppRouter.getRouter()); ibiz.message = new MessageUtil(); ibiz.modal = new ModalUtil(); ibiz.notification = new NotificationUtil(); diff --git a/src/router/index.ts b/src/router/index.ts index 10d564e..958c0c1 100644 --- a/src/router/index.ts +++ b/src/router/index.ts @@ -1,8 +1,12 @@ +import { + TodoRedirect, + View404, + AppRedirectView, + LoginView, +} from '@ibiz-template/vue3-components'; import { createRouter, createWebHashHistory, Router } from 'vue-router'; import NProgress from 'nprogress'; import { AuthGuard } from '../guard'; -import appRedirectView from '@/views/app-redirect-view/app-redirect-view'; -import todoRedirect from '@/views/todo-redirect/todo-redirect'; import 'nprogress/nprogress.css'; export class AppRouter { @@ -22,12 +26,12 @@ export class AppRouter { { path: '/login', name: 'loginView', - component: () => import('../views/login-view/login-view'), + component: LoginView, }, { path: '/404', name: '404View1', - component: () => import('../views/404-view/404-view'), + component: View404, }, { path: '/:appContext/index/:params1', @@ -43,31 +47,8 @@ export class AppRouter { next(false); } }, - component: () => import('../publish/pages/app-index/app-index.vue'), - children: [ - { - path: 'bookgridview/:params2', - name: 'bookgridview', - props: { - level: 2, - }, - component: () => - import( - '../publish/pages/book/book-grid-view/book-grid-view.vue' - ), - }, - { - path: 'reginfostuinfolist/:params2', - name: 'regInfoStuInfoList', - props: { - level: 2, - }, - component: () => - import( - '../publish/pages/reginfo/reginfo-stu-info-list/reginfo-stu-info-list.vue' - ), - }, - ], + component: () => import('../publish/pages/sample/sample.vue'), + children: [], }, { path: '/appredirectview', @@ -80,7 +61,7 @@ export class AppRouter { next(false); } }, - component: appRedirectView, + component: AppRedirectView, }, { path: '/todoredirect', @@ -93,7 +74,7 @@ export class AppRouter { next(false); } }, - component: todoRedirect, + component: TodoRedirect, }, ], }); diff --git a/src/store/app-store/app-store.ts b/src/store/app-store/app-store.ts deleted file mode 100644 index 06c5be0..0000000 --- a/src/store/app-store/app-store.ts +++ /dev/null @@ -1,10 +0,0 @@ -import { defineStore } from 'pinia'; -import { reactive } from 'vue'; - -export interface IAppStore {} - -export const useAppStore = defineStore('appStore', () => { - const appStore = reactive({}); - - return { appStore }; -}); diff --git a/src/store/index.ts b/src/store/index.ts deleted file mode 100644 index ead684c..0000000 --- a/src/store/index.ts +++ /dev/null @@ -1,6 +0,0 @@ -import { createPinia } from 'pinia'; - -export * from './app-store/app-store'; -export * from './ui-store/ui-store'; - -export const piniaInstance = createPinia(); diff --git a/src/store/ui-store/ui-store.ts b/src/store/ui-store/ui-store.ts deleted file mode 100644 index d067f22..0000000 --- a/src/store/ui-store/ui-store.ts +++ /dev/null @@ -1,24 +0,0 @@ -import { defineStore } from 'pinia'; -import { reactive, Ref } from 'vue'; -import { useZIndexStore } from './z-index'; - -export interface IUIState { - /** - * ui层级 - * - * @author lxm - * @date 2022-08-18 21:08:48 - * @type {number} - */ - zIndex: Ref; -} - -export const useUIStore = defineStore('uiStore', () => { - const zIndex = useZIndexStore(); - - const UIStore = reactive({ - zIndex: zIndex.zIndex, - }); - - return { UIStore, zIndex }; -}); diff --git a/src/store/ui-store/z-index.ts b/src/store/ui-store/z-index.ts deleted file mode 100644 index 46fe547..0000000 --- a/src/store/ui-store/z-index.ts +++ /dev/null @@ -1,53 +0,0 @@ -import { Ref, ref } from 'vue'; - -export interface IzIndexStore { - /** - * 当前最高的ui层级 - * - * @author lxm - * @date 2022-08-18 21:08:48 - * @type {number} - */ - zIndex: Ref; - - /** - * 增加Ui层级,返回增加后的层级 - * - * @author lxm - * @date 2022-08-18 21:08:22 - */ - increment(): number; - - /** - * 减少Ui层级 - * - * @author lxm - * @date 2022-08-18 21:08:22 - */ - decrement(): void; -} - -/** - * 定义zIndex的全局状态变量 - * - * @author lxm - * @date 2022-08-18 21:08:26 - * @export - * @returns {*} - */ -export function useZIndexStore(): IzIndexStore { - const DEFAULT_INDEX = 500; - const INCREMENT_VALUE = 1; - const zIndex = ref(DEFAULT_INDEX); - - function increment(): number { - zIndex.value += INCREMENT_VALUE; - return zIndex.value; - } - - function decrement() { - zIndex.value -= INCREMENT_VALUE; - } - - return { zIndex, increment, decrement }; -} diff --git a/src/util/app-drawer/app-drawer-component.scss b/src/util/app-drawer/app-drawer-component.scss deleted file mode 100644 index 98066c8..0000000 --- a/src/util/app-drawer/app-drawer-component.scss +++ /dev/null @@ -1,19 +0,0 @@ -@include b(drawer) { - @include set-component-css-var('drawer', $drawer); - - // 覆盖iView计算的z-index,使用变量 - .ivu-drawer-mask, - .ivu-drawer-wrap { - z-index: getCssVar('drawer', 'z-index') !important; - } - - .ivu-drawer-content { - @include flex(column); - - height: 100%; - - .ivu-drawer-body { - padding: 0; - } - } -} diff --git a/src/util/app-drawer/app-drawer-component.tsx b/src/util/app-drawer/app-drawer-component.tsx deleted file mode 100644 index 024849b..0000000 --- a/src/util/app-drawer/app-drawer-component.tsx +++ /dev/null @@ -1,96 +0,0 @@ -import { defineComponent, PropType, ref, VNode } from 'vue'; -import { useNamespace } from '@ibiz-template/vue3-util'; -import { IDrawerOptions, IOverlayContainer } from '@ibiz-template/runtime'; -import { useUIStore } from '@/store'; -import { OverlayContainer } from '../overlay-container/overlay-container'; -import './app-drawer-component.scss'; - -export const AppDrawerComponent = defineComponent({ - props: { - opts: { - type: Object as PropType, - default: () => ({}), - }, - }, - setup(props, ctx) { - const ns = useNamespace('drawer'); - - const isShow = ref(false); - - const { zIndex } = useUIStore(); - const drawerZIndex = zIndex.increment(); - - // 所有关闭方式最终都走这个 - const onClose = () => { - zIndex.decrement(); - ctx.emit('dismiss'); - }; - - const dismiss = () => { - isShow.value = false; - }; - - const present = () => { - isShow.value = true; - }; - - let direction = ''; - - switch (props.opts.placement) { - case 'left': - direction = 'ltr'; - break; - case 'top': - direction = 'ttb'; - break; - case 'bottom': - direction = 'btt'; - break; - default: - direction = 'rtl'; - } - - return { - ns, - isShow, - direction, - drawerZIndex, - dismiss, - present, - onClose, - }; - }, - render() { - return ( - - {this.$slots.default?.()} - - ); - }, -}); - -/** - * 创建抽屉 - * - * @author chitanda - * @date 2022-12-29 15:12:57 - * @export - * @param {() => VNode} render - * @param {(IDrawerOptions | undefined)} [opts] - * @return {*} {IOverlayContainer} - */ -export function createDrawer( - render: () => VNode, - opts?: IDrawerOptions | undefined, -): IOverlayContainer { - return new OverlayContainer(AppDrawerComponent, render, opts); -} diff --git a/src/util/app-modal/app-modal-component.tsx b/src/util/app-modal/app-modal-component.tsx deleted file mode 100644 index 4ac8eaf..0000000 --- a/src/util/app-modal/app-modal-component.tsx +++ /dev/null @@ -1,101 +0,0 @@ -import { defineComponent, PropType, reactive, ref, VNode } from 'vue'; -import { useNamespace } from '@ibiz-template/vue3-util'; -import { isNumber } from 'lodash-es'; -import { IModalOptions, IOverlayContainer } from '@ibiz-template/runtime'; -import { useUIStore } from '@/store'; -import './modal.scss'; -import { OverlayContainer } from '../overlay-container/overlay-container'; - -export const AppModalComponent = defineComponent({ - props: { - opts: { - type: Object as PropType, - default: () => ({}), - }, - }, - setup(props, ctx) { - const ns = useNamespace('modal'); - - const isShow = ref(false); - - const { zIndex } = useUIStore(); - const modalZIndex = zIndex.increment(); - - // 处理自定义样式,添加z-index变量 - const customStyle = reactive({ - [ns.cssVarBlockName('z-index')]: modalZIndex, - }); - const { width, height } = props.opts; - if (width) { - customStyle.width = isNumber(width) ? `${width}px` : width; - } - if (height) { - customStyle.height = isNumber(height) ? `${height}px` : height; - } - - // 合并options - const options = ref({ footerHide: true, modalClass: '' }); - if (props.opts) { - Object.assign(options.value, props.opts); - } - - // 所有关闭方式最终都走这个 - const onClose = () => { - zIndex.decrement(); - ctx.emit('dismiss'); - }; - - const dismiss = () => { - isShow.value = false; - }; - - const present = () => { - isShow.value = true; - }; - - return { - ns, - isShow, - options, - modalZIndex, - customStyle, - present, - dismiss, - onClose, - }; - }, - render() { - return ( - - {this.$slots.default?.()} - - ); - }, -}); - -/** - * 创建模态框 - * - * @author chitanda - * @date 2022-12-29 15:12:50 - * @export - * @param {() => VNode} render - * @param {(IModalOptions | undefined)} [opts] - * @return {*} {IOverlayContainer} - */ -export function createModal( - render: () => VNode, - opts?: IModalOptions | undefined, -): IOverlayContainer { - return new OverlayContainer(AppModalComponent, render, opts); -} diff --git a/src/util/app-modal/modal.scss b/src/util/app-modal/modal.scss deleted file mode 100644 index 5d61c01..0000000 --- a/src/util/app-modal/modal.scss +++ /dev/null @@ -1,28 +0,0 @@ -@include b(modal) { - @include set-component-css-var('modal', $modal); - - // 覆盖element计算的z-index,使用变量 - &.el-dialog{ - z-index: getCssVar('modal', 'z-index') !important; - overflow: auto; - } - - .el-dialog__header{ - position: relative; - padding: 0; - } - - .el-dialog__body { - height: 100%; - padding: 0; - } - - // 模态关闭图标位置 - .el-dialog__headerbtn { - top: 0; - right: -16px; - z-index: getCssVar('modal', 'z-index'); - } - - -} diff --git a/src/util/app-popover/app-popover-component.tsx b/src/util/app-popover/app-popover-component.tsx deleted file mode 100644 index c9aeef8..0000000 --- a/src/util/app-popover/app-popover-component.tsx +++ /dev/null @@ -1,197 +0,0 @@ -/* eslint-disable @typescript-eslint/no-explicit-any */ -import { arrow, computePosition, flip, offset, shift } from '@floating-ui/dom'; -import { IPopoverOptions } from '@ibiz-template/runtime'; -import { useNamespace } from '@ibiz-template/vue3-util'; -import { - computed, - defineComponent, - onUnmounted, - PropType, - ref, - VNode, -} from 'vue'; -import './popover.scss'; -import { OverlayPopoverContainer } from '../overlay-popover-container/overlay-popover-container'; - -/** - * 计算飘窗显示 - * - * @author chitanda - * @date 2022-11-08 21:11:18 - * @param {HTMLElement} element - * @param {HTMLElement} el - * @param {HTMLElement} arrEl - * @param {IPopoverOptions} opts - * @return {*} {Promise} - */ -async function computePos( - element: HTMLElement, - el: HTMLElement, - arrEl: HTMLElement, - opts: IPopoverOptions, -): Promise { - const middlewareArr = [offset(opts.offsetOpts || 6), flip(), shift()]; - if (!opts.noArrow) { - middlewareArr.push(arrow({ element: arrEl! })); - } - const options = await computePosition(element, el, { - placement: opts.placement, - strategy: 'absolute', - middleware: middlewareArr, - }); - { - const { x, y, placement, middlewareData } = options; - const { style } = el; - style.left = `${x}px`; - style.top = `${y}px`; - - if (!opts.noArrow) { - // 箭头位置 - const { x: arrowX, y: arrowY } = middlewareData.arrow!; - - const staticSide: any = { - top: 'bottom', - right: 'left', - bottom: 'top', - left: 'right', - }[placement.split('-')[0]]; - - Object.assign(arrEl.style, { - left: arrowX != null ? `${arrowX}px` : '', - top: arrowY != null ? `${arrowY}px` : '', - right: '', - bottom: '', - [staticSide]: '-4px', - }); - } - } -} - -const AppPopoverComponent = defineComponent({ - props: { - opts: { - type: Object as PropType, - default: () => ({}), - }, - }, - setup(props, ctx) { - // 样式命名空间 - const ns = useNamespace('popover'); - // 是否显示 - const isShow = ref(false); - // 是否悬浮在内容区,当悬浮在内容区时 autoClose 禁用 - const isHover = ref(false); - // 跟 dom 元素 - const el = ref(); - // arrow dom 元素 - const arrEl = ref(); - // 是否可以自动关闭 - const autoClose = computed(() => { - return props.opts.autoClose === true && isHover.value === false; - }); - - // 鼠标入飘窗内容区 - function onMouseenter(e: MouseEvent): void { - e.stopPropagation(); - isHover.value = true; - } - - // 鼠标出飘窗内容区 - function onMouseleave(e: MouseEvent): void { - e.stopPropagation(); - isHover.value = false; - } - - // 点击容器关闭飘窗 - function dismiss(): void { - ctx.emit('dismiss'); - } - - // 组件销毁用于事件触发 - function destroy(e: Event): void { - e.stopPropagation(); - if (autoClose.value) { - dismiss(); - } - } - - function addEvents(): void { - window.addEventListener('mousedown', destroy, { capture: true }); - window.addEventListener('blur', destroy, { capture: true }); - window.addEventListener('resize', destroy, { capture: true }); - } - - function removeEvents(): void { - window.removeEventListener('mousedown', destroy, { capture: true }); - window.removeEventListener('blur', destroy, { capture: true }); - window.removeEventListener('resize', destroy, { capture: true }); - } - - addEvents(); - - onUnmounted(() => { - removeEvents(); - }); - - /** - * 飘窗显示并计算位置 - * - * @author chitanda - * @date 2022-11-09 12:11:04 - * @param {HTMLElement} target - * @return {*} {Promise} - */ - async function present(target: HTMLElement): Promise { - isShow.value = true; - await computePos(target, el.value!, arrEl.value!, props.opts); - } - - return { - ns, - el, - arrEl, - isShow, - isHover, - present, - dismiss, - onMouseenter, - onMouseleave, - }; - }, - render() { - return ( -
- {!this.opts.noArrow && ( -
- )} - {this.$slots.default?.()} -
- ); - }, -}); - -/** - * 创建飘窗 - * - * @author chitanda - * @date 2022-12-29 15:12:59 - * @export - * @param {() => VNode} render - * @param {IPopoverOptions} [opts] - * @return {*} {OverlayPopoverContainer} - */ -export function createPopover( - render: () => VNode, - opts?: IPopoverOptions, -): OverlayPopoverContainer { - return new OverlayPopoverContainer(AppPopoverComponent, render, opts); -} diff --git a/src/util/app-popover/popover.scss b/src/util/app-popover/popover.scss deleted file mode 100644 index 9cc6d76..0000000 --- a/src/util/app-popover/popover.scss +++ /dev/null @@ -1,24 +0,0 @@ -@include b(popover) { - position: absolute; - top: 0; - left: 0; - z-index: 1; - display: none; - width: max-content; - padding: calc(getCssVar('padding') / 2); - background-color: getCssVar('bg-color'); - border: getCssVar('border'); - border-radius: getCssVar('border-radius', 'base'); - - @include e(arrow) { - position: absolute; - width: 8px; - height: 8px; - background: getCssVar('bg-color'); - transform: rotate(45deg); - } - - @include when(show) { - display: block; - } -} diff --git a/src/util/index.ts b/src/util/index.ts index a58bcd5..927ad2f 100644 --- a/src/util/index.ts +++ b/src/util/index.ts @@ -1,9 +1 @@ -export { LoadingUtil } from './loading-util/loading-util'; -export { MessageUtil } from './message-util/message-util'; -export { ModalUtil } from './modal-util/modal-util'; -export { NotificationUtil } from './notification-util/notification-util'; -export { OpenViewUtil } from './open-view-util/open-view-util'; export { ErrorHandler } from './error-handler/error-handler'; -export { OverlayContainer } from './overlay-container/overlay-container'; -export { OverlayController } from './overlay-controller/overlay-controller'; -export { OverlayPopoverContainer } from './overlay-popover-container/overlay-popover-container'; diff --git a/src/util/loading-util/loading-util.ts b/src/util/loading-util/loading-util.ts deleted file mode 100644 index 28065c2..0000000 --- a/src/util/loading-util/loading-util.ts +++ /dev/null @@ -1,99 +0,0 @@ -import { ILoadingUtil } from '@ibiz-template/runtime'; -import { ElLoading } from 'element-plus'; -import NProgress from 'nprogress'; - -/** - * 全局加载动画工具 - * - * @author chitanda - * @date 2022-08-17 17:08:44 - * @export - * @class LoadingUtil - * @implements {ILoadingUtil} - */ -export class LoadingUtil implements ILoadingUtil { - /** - * 当前只在触发的全局加载次数 - * - * @author chitanda - * @date 2022-08-17 17:08:44 - * @protected - */ - protected count = 0; - - /** - * 当前在触发的重定向加载动画次数 - * - * @author chitanda - * @date 2022-10-08 17:10:02 - * @protected - */ - protected countRedirect = 0; - - /** - * element plus loading 实例 - * - * @author chitanda - * @date 2022-12-29 15:12:26 - * @protected - */ - protected loading!: { close: () => void }; - - /** - * 显示全局加载动画 - * - * @author chitanda - * @date 2022-12-29 15:12:26 - */ - show(): void { - if (this.count === 0) { - this.loading = ElLoading.service({ lock: true, fullscreen: true }); - } - this.count += 1; - } - - /** - * 隐藏全局加载动画 - * - * @author chitanda - * @date 2022-08-17 17:08:11 - */ - hide(): void { - if (this.count > 0) { - this.count -= 1; - } - if (this.count === 0) { - if (this.loading) { - this.loading.close(); - } - } - } - - /** - * 显示顶部加载动画 - * - * @author chitanda - * @date 2022-10-08 16:10:01 - */ - showRedirect(): void { - if (this.countRedirect === 0) { - NProgress.start(); - } - this.countRedirect += 1; - } - - /** - * 隐藏顶部加载动画 - * - * @author chitanda - * @date 2022-10-08 16:10:09 - */ - hideRedirect(): void { - if (this.countRedirect > 0) { - this.countRedirect -= 1; - } - if (this.countRedirect === 0) { - NProgress.done(); - } - } -} diff --git a/src/util/message-util/message-util.ts b/src/util/message-util/message-util.ts deleted file mode 100644 index 795e3aa..0000000 --- a/src/util/message-util/message-util.ts +++ /dev/null @@ -1,61 +0,0 @@ -import { IMessageUtil } from '@ibiz-template/runtime'; -import { ElMessage } from 'element-plus'; - -/** - * 消息通知 - * - * @author chitanda - * @date 2022-08-17 16:08:24 - * @export - * @class MessageUtil - * @implements {IMessageUtil} - */ -export class MessageUtil implements IMessageUtil { - info( - msg: string, - duration?: number | undefined, - closable?: boolean | undefined, - ): void { - ElMessage.info({ - message: msg, - duration: duration ? duration * 1000 : duration, - showClose: closable, - }); - } - - success( - msg: string, - duration?: number | undefined, - closable?: boolean | undefined, - ): void { - ElMessage.success({ - message: msg, - duration: duration ? duration * 1000 : duration, - showClose: closable, - }); - } - - warning( - msg: string, - duration?: number | undefined, - closable?: boolean | undefined, - ): void { - ElMessage.warning({ - message: msg, - duration: duration ? duration * 1000 : duration, - showClose: closable, - }); - } - - error( - msg: string, - duration?: number | undefined, - closable?: boolean | undefined, - ): void { - ElMessage.error({ - message: msg, - duration: duration ? duration * 1000 : duration, - showClose: closable, - }); - } -} diff --git a/src/util/modal-util/modal-util.ts b/src/util/modal-util/modal-util.ts deleted file mode 100644 index b4a9c9d..0000000 --- a/src/util/modal-util/modal-util.ts +++ /dev/null @@ -1,37 +0,0 @@ -import { IModalUtil, ModalParams } from '@ibiz-template/runtime'; -import { ElMessageBox } from 'element-plus'; - -/** - * 简洁确认操作框 - * - * @author chitanda - * @date 2022-08-17 16:08:52 - * @export - * @class ModalUtil - * @implements {IModalUtil} - */ -export class ModalUtil implements IModalUtil { - async info(params: ModalParams): Promise { - ElMessageBox.alert(params.desc, params.title, { type: 'info' }); - } - - async success(params: ModalParams): Promise { - ElMessageBox.alert(params.desc, params.title, { type: 'success' }); - } - - async warning(params: ModalParams): Promise { - ElMessageBox.alert(params.desc, params.title, { type: 'warning' }); - } - - async error(params: ModalParams): Promise { - ElMessageBox.alert(params.desc, params.title, { type: 'error' }); - } - - async confirm(params: ModalParams): Promise { - return new Promise(resolve => { - ElMessageBox.confirm(params.desc, params.title) - .then(() => resolve(true)) - .catch(() => resolve(false)); - }); - } -} diff --git a/src/util/notification-util/notification-util.ts b/src/util/notification-util/notification-util.ts deleted file mode 100644 index 92e64fc..0000000 --- a/src/util/notification-util/notification-util.ts +++ /dev/null @@ -1,53 +0,0 @@ -import { INotificationUtil, NotificationParams } from '@ibiz-template/runtime'; -import { ElNotification } from 'element-plus'; - -/** - * 在界面右上角显示可关闭的全局通知 - * - * @author chitanda - * @date 2022-08-17 16:08:26 - * @export - * @class NotificationUtil - * @implements {INotificationUtil} - */ -export class NotificationUtil implements INotificationUtil { - info(params: NotificationParams): void { - const duration = params.duration ? params.duration * 1000 : params.duration; - ElNotification({ - title: params.title, - message: params.desc, - type: 'info', - duration, - }); - } - - success(params: NotificationParams): void { - const duration = params.duration ? params.duration * 1000 : params.duration; - ElNotification({ - title: params.title, - message: params.desc, - type: 'success', - duration, - }); - } - - warning(params: NotificationParams): void { - const duration = params.duration ? params.duration * 1000 : params.duration; - ElNotification({ - title: params.title, - message: params.desc, - type: 'warning', - duration, - }); - } - - error(params: NotificationParams): void { - const duration = params.duration ? params.duration * 1000 : params.duration; - ElNotification({ - title: params.title, - message: params.desc, - type: 'error', - duration, - }); - } -} diff --git a/src/util/open-view-util/open-view-util.ts b/src/util/open-view-util/open-view-util.ts deleted file mode 100644 index d26f0a7..0000000 --- a/src/util/open-view-util/open-view-util.ts +++ /dev/null @@ -1,149 +0,0 @@ -import { IAppView } from '@ibiz/model-core'; -import { - IModal, - IModalData, - IOpenViewUtil, - ViewMode, -} from '@ibiz-template/runtime'; -import { generateRoutePath } from '@ibiz-template/vue3-util'; -import { AppRouter } from '@/router'; -import { - getDrawerPlacement, - openViewDrawer, - openViewModal, - openViewPopover, -} from '../overlay-view-util/overlay-view-util'; - -/** - * 打开视图方式工具类 - * - * @description 此实现类挂载在 ibiz.openViewUtil - * @author chitanda - * @date 2022-08-16 20:08:54 - * @export - * @class OpenViewUtil - * @implements {IOpenViewUtil} - */ -export class OpenViewUtil implements IOpenViewUtil { - root( - appView: IAppView, - context: IContext, - params?: IParams | undefined, - ): void { - const router = AppRouter.getRouter(); - - const { path } = generateRoutePath( - appView, - router.currentRoute.value, - context, - params, - ); - - router.push({ path }); - } - - /** - * 模态打开视图 - * - * @author lxm - * @date 2022-09-12 01:09:06 - * @param {IAppView} appView - * @param {(IContext | undefined)} [context] - * @param {(IParams | undefined)} [params] - * @returns {*} {Promise} - */ - async modal( - appView: IAppView, - context: IContext, - params?: IParams | undefined, - ): Promise { - // 获取视图path - // const modelPath = appView.modelPath!; - - // 设置默认的modal参数 - const opts = { - width: appView.width || '80%', - height: appView.height || '80%', - footerHide: true, - }; - - const modal: IModal = { mode: ViewMode.MODAL }; - return openViewModal( - { - context, - params, - // modelPath, - modal, - }, - opts, - ); - } - - async popover( - appView: IAppView, - event: MouseEvent, - context: IContext, - params?: IParams | undefined, - ): Promise { - // 获取视图path - // const modelPath = appView.modelPath!; - - const modal: IModal = { mode: ViewMode.POPOVER }; - return openViewPopover( - event, - { - context, - params, - // modelPath, - modal, - }, - { autoClose: true, placement: 'bottom' }, - ); - } - - /** - * 抽屉打开视图 - * - * @author lxm - * @date 2022-09-15 15:09:50 - * @param {IAppView} appView - * @param {(IContext | undefined)} [context] - * @param {(IParams | undefined)} [params] - * @returns {*} {Promise} - */ - async drawer( - appView: IAppView, - context: IContext, - params?: IParams | undefined, - ): Promise { - // 获取视图path - const placement = getDrawerPlacement(appView.openMode!); - - // 设置默认的modal参数 - const opts = { - width: appView.width || '800', - height: appView.height || '600', - placement, - }; - - const modal: IModal = { mode: ViewMode.DRAWER }; - return openViewDrawer( - { - context, - params, - // modelPath:, - modal, - }, - opts, - ); - } - - async custom( - appView: IAppView, - context: IContext, - params?: IParams | undefined, - ): Promise { - ibiz.log.warn('openUserCustom', appView, context, params); - throw new Error(); - } -} diff --git a/src/util/overlay-container/overlay-container.ts b/src/util/overlay-container/overlay-container.ts deleted file mode 100644 index 4ef3d6a..0000000 --- a/src/util/overlay-container/overlay-container.ts +++ /dev/null @@ -1,148 +0,0 @@ -/* eslint-disable no-unused-vars */ -/* eslint-disable @typescript-eslint/no-explicit-any */ -import { QXEvent } from 'qx-util'; -import { IOverlayContainer } from '@ibiz-template/runtime'; -import { App, h, VNode } from 'vue'; -import { createVueApp } from '@/create-vue-app'; - -/** - * 全局弹出承载组件 - * - * @author chitanda - * @date 2022-11-09 12:11:09 - * @export - * @class OverlayContainer - */ -export class OverlayContainer implements IOverlayContainer { - protected vm?: App; - - /** - * 具体模态组件 - * - * @author chitanda - * @date 2022-11-09 12:11:34 - * @protected - * @type {*} - */ - protected modal: any; - - /** - * 外面调用dismiss时传的result结果 - * - * @author lxm - * @date 2022-11-09 20:11:06 - * @protected - * @type {unknown} - */ - protected result?: unknown; - - /** - * 内部事件 - * - * @author chitanda - * @date 2022-11-09 12:11:42 - * @protected - */ - protected evt: QXEvent<{ dismiss: (data?: unknown) => void }> = new QXEvent(); - - /** - * 创建全局呈现 - * - * @author chitanda - * @date 2022-11-09 14:11:52 - * @param {unknown} component - * @param {(h: CreateElement) => VNode} render - * @param {IPopoverOptions} [opts] - */ - constructor( - protected component: unknown, - protected render: () => VNode, - protected opts?: O, - ) { - this.init(); - } - - /** - * 初始化飘窗 - * - * @author chitanda - * @date 2022-11-09 12:11:55 - * @protected - * @return {*} {void} - */ - protected init(): void { - const self = this; - const { render, opts } = this; - const container = document.createElement('div'); - document.body.appendChild(container); - const vm = createVueApp({ - mounted() { - self.modal = this.$refs.root; - }, - unmounted() { - document.body.removeChild(container); - self.evt.emit('dismiss', self.result); - window.vueInstances.delete(vm); - }, - render() { - return h( - self.component as string, - { - ref: 'root', - opts, - onDismiss() { - vm.unmount(); - }, - }, - { default: render }, - ); - }, - }); - ibiz.plugin.register(vm); - vm.mount(container); - this.vm = vm; - } - - /** - * 打开飘窗 - * - * @author chitanda - * @date 2022-11-09 12:11:52 - * @param {HTMLElement} target - * @return {*} {Promise} - */ - async present(): Promise { - return this.modal.present(); - } - - /** - * 手动调用关闭飘窗 - * - * @author chitanda - * @date 2022-11-09 12:11:39 - * @param {unknown} [data] - * @return {*} {Promise} - */ - async dismiss(data?: unknown): Promise { - this.result = data; - this.modal.dismiss(); - } - - /** - * 订阅窗口关闭 - * - * @author chitanda - * @date 2022-11-09 12:11:20 - * @template T - * @return {*} {Promise} - */ - async onWillDismiss(): Promise { - return new Promise(resolve => { - const callback = (data: unknown) => { - resolve(data as T); - this.evt.off('dismiss', callback); - }; - this.evt.on('dismiss', callback); - }); - } -} diff --git a/src/util/overlay-controller/overlay-controller.ts b/src/util/overlay-controller/overlay-controller.ts deleted file mode 100644 index 29b63b7..0000000 --- a/src/util/overlay-controller/overlay-controller.ts +++ /dev/null @@ -1,93 +0,0 @@ -import { - IOverlayController, - IDrawerOptions, - IPopoverOptions, - IModalOptions, - IOverlayContainer, - IOverlayPopoverContainer, -} from '@ibiz-template/runtime'; -import { isFunction } from 'lodash-es'; -import { h, resolveComponent } from 'vue'; -import { createPopover } from '../app-popover/app-popover-component'; -import { createModal } from '../app-modal/app-modal-component'; -import { createDrawer } from '../app-drawer/app-drawer-component'; -/** - * 用不同呈现方式绘制组件的通用工具类 - * - * @author lxm - * @date 2022-11-08 16:11:09 - * @export - * @class OverlayController - * @implements {IOverlayController} - */ -export class OverlayController implements IOverlayController { - popover( - element: HTMLElement, - component: unknown, - props?: IParams | undefined, - opts?: IPopoverOptions | undefined, - ): Promise { - const popover = this.createPopover(component, props, opts); - popover.present(element); - return popover.onWillDismiss(); - } - - createPopover( - component: unknown, - props?: IParams | undefined, - opts?: IPopoverOptions | undefined, - ): IOverlayPopoverContainer { - return createPopover( - isFunction(component) - ? component - : () => h(resolveComponent(component as string), { ...props }), - opts, - ); - } - - drawer( - component: unknown, - props?: IParams | undefined, - opts?: IDrawerOptions | undefined, - ): Promise { - const drawer = this.createDrawer(component, props, opts); - drawer.present(); - return drawer.onWillDismiss(); - } - - createDrawer( - component: unknown, - props?: IParams | undefined, - opts?: IDrawerOptions | undefined, - ): IOverlayContainer { - return createDrawer( - isFunction(component) - ? component - : () => h(resolveComponent(component as string), { ...props }), - opts, - ); - } - - async modal( - component: unknown, - props?: IParams | undefined, - opts?: IModalOptions | undefined, - ): Promise { - const modal = this.createModal(component, props, opts); - modal.present(); - return modal.onWillDismiss(); - } - - createModal( - component: unknown, - props?: IParams | undefined, - opts?: IModalOptions | undefined, - ): IOverlayContainer { - return createModal( - isFunction(component) - ? component - : () => h(resolveComponent(component as string), { ...props }), - opts, - ); - } -} diff --git a/src/util/overlay-popover-container/overlay-popover-container.ts b/src/util/overlay-popover-container/overlay-popover-container.ts deleted file mode 100644 index 659a206..0000000 --- a/src/util/overlay-popover-container/overlay-popover-container.ts +++ /dev/null @@ -1,30 +0,0 @@ -/* eslint-disable no-unused-vars */ -/* eslint-disable no-dupe-class-members */ -import { - IPopoverOptions, - IOverlayPopoverContainer, -} from '@ibiz-template/runtime'; -import { OverlayContainer } from '../overlay-container/overlay-container'; - -/** - * 飘窗组件呈现容器 - * - * @author chitanda - * @date 2022-11-09 14:11:46 - * @export - * @class OverlayPopoverContainer - * @extends {OverlayContainer} - * @implements {IOverlayPopoverContainer} - */ -export class OverlayPopoverContainer - extends OverlayContainer - implements IOverlayPopoverContainer -{ - present(): Promise; - - present(target: HTMLElement): Promise; - - present(target?: HTMLElement): Promise { - return this.modal.present(target); - } -} diff --git a/src/util/overlay-view-util/overlay-view-util.ts b/src/util/overlay-view-util/overlay-view-util.ts deleted file mode 100644 index 374d164..0000000 --- a/src/util/overlay-view-util/overlay-view-util.ts +++ /dev/null @@ -1,85 +0,0 @@ -import { - IDrawerOptions, - IModal, - IModalData, - IModalOptions, - IPopoverOptions, - ViewMode, -} from '@ibiz-template/runtime'; -import { h, resolveComponent, VNode } from 'vue'; - -export function createOverlayView( - close: (_res: IModalData) => void, - props?: IParams | undefined, -): () => VNode { - return () => { - const viewShell = resolveComponent('ViewShell'); - return h(viewShell, { - ...props, - // onNeuronInit: (neuron: ViewNeuron) => { - // neuron.on('onCloseView', event => { - // close({ ok: event.ok, data: event.data }); - // }); - // }, - }); - }; -} - -export async function openViewModal( - props?: IParams | undefined, - opts?: IModalOptions | undefined, -): Promise { - const modal: IModal = { mode: ViewMode.MODAL }; - const overlay = ibiz.overlay.createModal( - createOverlayView(res => overlay.dismiss(res), { ...props, modal }), - undefined, - opts, - ); - overlay.present(); - const result: IModalData | undefined = await overlay.onWillDismiss(); - return result || { ok: false }; -} - -export async function openViewDrawer( - props?: IParams | undefined, - opts?: IDrawerOptions | undefined, -): Promise { - const modal: IModal = { mode: ViewMode.DRAWER }; - const overlay = ibiz.overlay.createDrawer( - createOverlayView(res => overlay.dismiss(res), { ...props, modal }), - undefined, - opts, - ); - overlay.present(); - const result: IModalData | undefined = await overlay.onWillDismiss(); - return result || { ok: false }; -} - -export async function openViewPopover( - event: MouseEvent, - props?: IParams | undefined, - opts?: IPopoverOptions | undefined, -): Promise { - const modal: IModal = { mode: ViewMode.DRAWER }; - const overlay = ibiz.overlay.createPopover( - createOverlayView(res => overlay.dismiss(res), { ...props, modal }), - undefined, - opts, - ); - overlay.present(event.target as HTMLElement); - const result: IModalData | undefined = await overlay.onWillDismiss(); - return result || { ok: false }; -} - -const PlacementMap: IData = { - DRAWER_LEFT: 'left', - DRAWER_RIGHT: 'right', - DRAWER_TOP: 'top', - DRAWER_BOTTOM: 'bottom', -}; - -export function getDrawerPlacement( - openMode: string, -): IDrawerOptions['placement'] { - return PlacementMap[openMode] || 'right'; -} diff --git a/src/views/404-view/404-view.scss b/src/views/404-view/404-view.scss deleted file mode 100644 index c84e648..0000000 --- a/src/views/404-view/404-view.scss +++ /dev/null @@ -1,17 +0,0 @@ -@include b(404-view) { - @include flex(row, center, center); - - width: 100%; - height: 100%; - background-color: #fff; - @include b(404-view-text) { - @include e(text1) { - margin-bottom: 20px; - } - } - - @include when(top) { - width: 100vw; - height: 100vh; - } -} diff --git a/src/views/404-view/404-view.tsx b/src/views/404-view/404-view.tsx deleted file mode 100644 index 49f3201..0000000 --- a/src/views/404-view/404-view.tsx +++ /dev/null @@ -1,49 +0,0 @@ -import { useNamespace } from '@ibiz-template/vue3-util'; -import { computed, defineComponent, onMounted } from 'vue'; -import './404-view.scss'; -import { useRoute, useRouter } from 'vue-router'; - -export default defineComponent({ - setup() { - const ns = useNamespace('404-view'); - const router = useRouter(); - const route = useRoute(); - const gotoIndexView = () => { - router.push('/'); - }; - - onMounted(() => { - setTimeout(() => { - const el = document.querySelector('.app-loading-x') as HTMLDivElement; - if (el) { - el.style.display = 'none'; - } - }, 300); - }); - - const isTop = computed(() => { - return !route.params.view1; - }); - - return { ns, isTop, gotoIndexView }; - }, - render() { - return ( -
- -
-
- 抱歉,您访问的页面不存在! -
- {this.isTop ? ( -
- 您要找的页面不存在,请返回 - 首页 - 继续浏览 -
- ) : null} -
-
- ); - }, -}); diff --git a/src/views/app-redirect-view/app-redirect-view.tsx b/src/views/app-redirect-view/app-redirect-view.tsx deleted file mode 100644 index 0260e35..0000000 --- a/src/views/app-redirect-view/app-redirect-view.tsx +++ /dev/null @@ -1,32 +0,0 @@ -import { defineComponent, onMounted, onUnmounted } from 'vue'; -import { IBizContext } from '@ibiz-template/core'; -// import { toLocalOpenWFRedirectView } from '@ibiz-template/runtime'; - -export default defineComponent({ - setup() { - const context = IBizContext.create(ibiz.appData?.context || {}); - - onUnmounted(() => { - context.destroy(); - }); - - // const { href } = window.location; - - async function toRedirect(): Promise { - // const modelService = await ibiz.model.getModelService(); - // await toLocalOpenWFRedirectView(modelService, context, href); - } - - onMounted(() => { - const el = document.querySelector('.app-loading-x') as HTMLDivElement; - if (el) { - el.style.display = 'block'; - } - }); - - toRedirect(); - }, - render() { - return
重定向跳转中
; - }, -}); diff --git a/src/views/index.ts b/src/views/index.ts deleted file mode 100644 index 5adf2da..0000000 --- a/src/views/index.ts +++ /dev/null @@ -1 +0,0 @@ -export * from './login-view/login-view'; diff --git a/src/views/login-view/login-view.scss b/src/views/login-view/login-view.scss deleted file mode 100644 index ac4b922..0000000 --- a/src/views/login-view/login-view.scss +++ /dev/null @@ -1,78 +0,0 @@ -/* stylelint-disable selector-class-pattern */ -@include b(login-view) { - display: flex; - align-items: center; - justify-content: center; - width: 100vw; - height: 100vh; - background: linear-gradient(120deg, #a1c4fd 0%, #c2e9fb 100%); -} - - -@include b(login-view-box) { - width: 430px; - margin-bottom: 80px; - overflow: hidden; - background: #fff; -} - -@media screen and (max-width: 720px) { - @include b(login-view-box) { - width: 340px; - margin-top: 0; - } -} - -@include b(login-view-box-header) { - background: #ccf; - - > img { - display: block; - width: 430px; - margin: 0 auto; - user-select: none; - } -} - -@include b(login-view-box-main) { - position: relative; - - @include e(avatar) { - position: absolute; - top: -50px; - right: calc(50% - 50px); - z-index: 2; - display: block; - width: 100px; - height: 100px; - user-select: none; - border: 4px solid #fff; - border-radius: 50%; - } -} - -@include b(login-view-box-main-content) { - padding: 100px 40px 40px; - - // 浏览器自动填写之后的输入框的背景色和文字颜色 - .el-input__inner:-webkit-autofill{ - box-shadow:0 0 0 1000px #fff inset; - -webkit-text-fill-color: #606266; - } - - .el-button { - width: 100%; - margin-top: 15px; - font-weight: 300; - letter-spacing: 2px; - } - - .el-input__prefix{ - width: 20px; - margin-left: -1px; - } - - ion-icon { - font-size: 16px; - } -} diff --git a/src/views/login-view/login-view.tsx b/src/views/login-view/login-view.tsx deleted file mode 100644 index 9f1de6c..0000000 --- a/src/views/login-view/login-view.tsx +++ /dev/null @@ -1,162 +0,0 @@ -import { CoreConst } from '@ibiz-template/core'; -import { defineComponent, onMounted, reactive, ref } from 'vue'; -import { setCookie } from 'qx-util'; -import { useNamespace } from '@ibiz-template/vue3-util'; -import { useRoute, useRouter } from 'vue-router'; -import './login-view.scss'; - -interface LoginData { - username: string; - password: string; -} - -const rules = { - username: [ - { - required: true, - message: '请输入账号', - trigger: 'blur', - }, - ], - password: [ - { - required: true, - message: '请输入密码', - trigger: 'blur', - }, - { - type: 'string', - min: 6, - message: '密码长度不能少于6位', - trigger: 'blur', - }, - ], -}; - -export default defineComponent({ - setup() { - const ns = useNamespace('login-view'); - - const loginData = reactive({ - username: '', - password: '', - }); - - const formRef = ref(null); - - const route = useRoute(); - const router = useRouter(); - const ru = (route.query.ru as string) || '/'; - - onMounted(() => { - setTimeout(() => { - const el = document.querySelector('.app-loading-x') as HTMLDivElement; - if (el) { - el.style.display = 'none'; - } - }, 300); - }); - - const loading = ref(false); - - ibiz.appData = undefined; - ibiz.orgData = undefined; - - const onClick = async () => { - formRef.value!.validate(async (vaild: boolean) => { - if (vaild) { - try { - loading.value = true; - const res = await ibiz.auth.v7login( - loginData.username, - loginData.password, - ); - if (res.ok) { - const { data } = res; - if (data && data.token) { - setCookie(CoreConst.TOKEN, data.token, 0, true); - const expiredDate = - new Date().getTime() + (data.expirein || 7199) * 1000; - setCookie(CoreConst.TOKEN_EXPIRES, `${expiredDate}`, 0, true); - router.push({ path: ru }); - return; - } - } - ibiz.notification.error({ - title: res.data?.message || '登录失败', - }); - loading.value = false; - } catch (error) { - ibiz.notification.error({ - title: (error as IData).response?.data?.message || '登录失败', - }); - loading.value = false; - } - } - }); - }; - - // 支持enter登录 - const onKeyUp = (e: KeyboardEvent) => { - if (e.key === 'Enter') { - onClick(); - } - }; - - return () => ( -
-
-
- -
-
- -
- - - onKeyUp(e)} - > - {{ - prefix: () => , - }} - - - - onKeyUp(e)} - > - {{ - prefix: () => , - }} - - - - - 登录 - - - -
-
-
-
- ); - }, -}); diff --git a/src/views/todo-redirect/todo-redirect.tsx b/src/views/todo-redirect/todo-redirect.tsx deleted file mode 100644 index a0a3beb..0000000 --- a/src/views/todo-redirect/todo-redirect.tsx +++ /dev/null @@ -1,51 +0,0 @@ -import qs from 'qs'; -import { defineComponent } from 'vue'; -import { useRouter } from 'vue-router'; - -export default defineComponent({ - setup() { - const router = useRouter(); - - const { href } = window.location; - - const i = href.lastIndexOf('?'); - - const queryStr: string = decodeURIComponent( - href.substring(i + 1, href.length), - ); - - if (!queryStr) { - throw new Error(`重定向参数不足无法跳转`); - } - - const params = qs.parse(queryStr, { delimiter: ';' }) as IData; - - const { apptype, todotype, todoid } = params; - - const data: IData = { srfapptype: 'pc', srfapp: '' }; - - if (!apptype) { - data.todourltype = 'RouterUrl'; - } - - async function getLinkUrl(): Promise { - const res = await ibiz.net.post(`/systodos/${todoid}/getlinkurl`, data); - let url: string = res.data.linkurl; - // apptype存在,带ip、端口等完整数据 - if (apptype) { - window.location.href = url; - } else { - if (url.indexOf('/') !== 0) { - url = `/${url}`; - } - url += `;srfwf=${todotype}`; - router.push(`/index${url}`); - } - } - - getLinkUrl(); - }, - render() { - return
待办列表重定向
; - }, -}); diff --git a/vite.config.ts b/vite.config.ts index ff4907b..8423a72 100644 --- a/vite.config.ts +++ b/vite.config.ts @@ -96,6 +96,13 @@ export default defineConfig({ target: 'http://172.16.103.130:30041', changeOrigin: true, }, + '/api/ibizdemoold__sample': { + rewrite(path) { + return path.replace('/api', ''); + }, + target: 'http://172.16.103.130:30202', + changeOrigin: true, + }, // '/plugins': { // target: 'http://nginx:20003', // changeOrigin: true -- Gitee