From 9b9f66b5afd2c6dc6229ccadb45f1a4f964f933d Mon Sep 17 00:00:00 2001 From: rd <1344903914@qq.com> Date: Thu, 14 Aug 2025 14:46:51 +0800 Subject: [PATCH] =?UTF-8?q?perf:=20=E6=8B=B7=E8=B4=9D=E4=B8=80=E4=BB=BD?= =?UTF-8?q?=E6=96=B0=E7=9A=84=E8=B7=AF=E7=94=B1=E9=85=8D=E7=BD=AE=E3=80=81?= =?UTF-8?q?=E6=B3=A8=E9=87=8A=E4=BA=A7=E5=93=81=E8=B7=AF=E7=94=B1=E6=A0=A1?= =?UTF-8?q?=E9=AA=8C?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- package.json | 1 + pnpm-lock.yaml | 230 +++++++++++++++++- src/router copy/app-menus/index.ts | 20 ++ src/router copy/constants.ts | 30 +++ src/router copy/guard/index.ts | 27 ++ src/router copy/guard/permission.ts | 29 +++ src/router copy/guard/userLoginInfo.ts | 45 ++++ src/router copy/index.ts | 48 ++++ src/router copy/routes/base.ts | 35 +++ src/router copy/routes/index.ts | 22 ++ src/router copy/routes/modules/agent.ts | 65 +++++ src/router copy/routes/modules/dataEngine.ts | 89 +++++++ src/router copy/routes/modules/management.ts | 56 +++++ .../routes/modules/propertyMarketing.ts | 227 +++++++++++++++++ src/router copy/routes/types.ts | 19 ++ src/router copy/typeings.d.ts | 20 ++ src/router/guard/userLoginInfo.ts | 20 +- src/views/home/index.vue | 17 ++ src/views/home/style.scss | 0 vite.config.ts | 2 +- 20 files changed, 989 insertions(+), 13 deletions(-) create mode 100644 src/router copy/app-menus/index.ts create mode 100644 src/router copy/constants.ts create mode 100644 src/router copy/guard/index.ts create mode 100644 src/router copy/guard/permission.ts create mode 100644 src/router copy/guard/userLoginInfo.ts create mode 100644 src/router copy/index.ts create mode 100644 src/router copy/routes/base.ts create mode 100644 src/router copy/routes/index.ts create mode 100644 src/router copy/routes/modules/agent.ts create mode 100644 src/router copy/routes/modules/dataEngine.ts create mode 100644 src/router copy/routes/modules/management.ts create mode 100644 src/router copy/routes/modules/propertyMarketing.ts create mode 100644 src/router copy/routes/types.ts create mode 100644 src/router copy/typeings.d.ts create mode 100644 src/views/home/index.vue create mode 100644 src/views/home/style.scss diff --git a/package.json b/package.json index 04e8e0a..152a3a6 100644 --- a/package.json +++ b/package.json @@ -15,6 +15,7 @@ "@types/nprogress": "^0.2.0", "@vueuse/core": "^9.12.0", "ali-oss": "^6.17.1", + "ant-design-x-vue": "^1.3.2", "axios": "^1.3.0", "dayjs": "^1.11.7", "dompurify": "^3.2.6", diff --git a/pnpm-lock.yaml b/pnpm-lock.yaml index 46a84df..86ec473 100644 --- a/pnpm-lock.yaml +++ b/pnpm-lock.yaml @@ -20,6 +20,9 @@ importers: ali-oss: specifier: ^6.17.1 version: 6.20.0 + ant-design-x-vue: + specifier: ^1.3.2 + version: 1.3.2(ant-design-vue@4.2.6(vue@3.2.45))(vue@3.2.45) axios: specifier: ^1.3.0 version: 1.3.0 @@ -205,6 +208,21 @@ packages: resolution: {integrity: sha512-qRmjj8nj9qmLTQXXmaR1cck3UXSRMPrbsLJAasZpF+t3riI71BXed5ebIOYwQntykeZuhjsdweEc9BxH5Jc26w==} engines: {node: '>=6.0.0'} + '@ant-design/colors@6.0.0': + resolution: {integrity: sha512-qAZRvPzfdWHtfameEGP2Qvuf838NhergR35o+EuVyB5XvSA98xod5r4utvi4TJ3ywmevm290g9nsCG5MryrdWQ==} + + '@ant-design/fast-color@2.0.6': + resolution: {integrity: sha512-y2217gk4NqL35giHl72o6Zzqji9O7vHh9YmhUVkPtAOpoTCH4uWxo/pr4VE8t0+ChEPs0qo4eJRC5Q1eXWo3vA==} + engines: {node: '>=8.x'} + + '@ant-design/icons-svg@4.4.2': + resolution: {integrity: sha512-vHbT+zJEVzllwP+CM+ul7reTEfBR0vgxFe7+lREAsAA7YGsYpboiq2sQNeQeRvh09GfQgs/GyFEvZpJ9cLXpXA==} + + '@ant-design/icons-vue@7.0.1': + resolution: {integrity: sha512-eCqY2unfZK6Fe02AwFlDHLfoyEFreP6rBwAZMIJ1LugmfMiVgwWDYlp1YsRugaPtICYOabV1iWxXdP12u9U43Q==} + peerDependencies: + vue: '>=3.0.3' + '@antfu/install-pkg@0.1.1': resolution: {integrity: sha512-LyB/8+bSfa0DFGC06zpCEfs89/XoWZwws5ygEa5D+Xsm3OfI+aXQ86VgVG7Acyef+rSZ5HE7J8rrxzrQeM3PjQ==} @@ -389,6 +407,19 @@ packages: resolution: {integrity: sha512-WaMsgi6Q8zMgMth93GvWPXkhAIEobfsIkLTacoVZoK1J0CevIPGYY2Vo5YvJGqyHqXM6P4ppOYGsIRU8MM9pFQ==} engines: {node: '>=6.9.0'} + '@ctrl/tinycolor@3.6.1': + resolution: {integrity: sha512-SITSV6aIXsuVNV3f3O0f2n/cgyEDWoSqtZMYiAmcsYHydcKrOz3gUxB/iXd/Qf08+IZX4KpgNbvUdMBmWz+kcA==} + engines: {node: '>=10'} + + '@emotion/hash@0.9.2': + resolution: {integrity: sha512-MyqliTZGuOm3+5ZRSaaBGP3USLw6+EGykkwZns2EPC5g8jJ4z9OrdZY9apkl3+UP9+sdz76YYkwCKP5gh8iY3g==} + + '@emotion/unitless@0.10.0': + resolution: {integrity: sha512-dFoMUuQA20zvtVTuxZww6OHoJYgrzfKM1t52mVySDJnMSEa08ruEvdYQbhvyu6soU+NeLVd3yKfTfT0NeV6qGg==} + + '@emotion/unitless@0.8.1': + resolution: {integrity: sha512-KOEGMu6dmJZtpadb476IsZBclKvILjopjUii3V+7MnXIQCYh8W3NgNcgwo21n9LXZX6EDIKvqfjYxXebDwxKmQ==} + '@esbuild/android-arm64@0.16.17': resolution: {integrity: sha512-MIGl6p5sc3RDTLLkYL1MyL8BMRN4tLMRCn+yRJJmEDvYZ2M7tmAf80hx1kbNEUX2KJ50RRtxZ4JHLvCfuB6kBg==} engines: {node: '>=12'} @@ -696,6 +727,9 @@ packages: '@rushstack/eslint-patch@1.2.0': resolution: {integrity: sha512-sXo/qW2/pAcmT43VoRKOJbDOfV3cYpq3szSVfIThQXNt+E4DfKj361vaAt3c88U5tPUxzEswam7GW48PJqtKAg==} + '@simonwep/pickr@1.8.2': + resolution: {integrity: sha512-/l5w8BIkrpP6n1xsetx9MWPWlU6OblN5YgZZphxan0Tq4BByTCETL6lyIeY8lagalS2Nbt4F2W034KHLIiunKA==} + '@trysound/sax@0.2.0': resolution: {integrity: sha512-L7z9BgrNEcYyUYtF+HaEfiS5ebkh9jXqbszz7pC0hRBPaatV0XjSD3+eHrpqFemQfgwiFF0QPIarnIihIDn7OA==} engines: {node: '>=10.13.0'} @@ -736,6 +770,9 @@ packages: '@types/web-bluetooth@0.0.16': resolution: {integrity: sha512-oh8q2Zc32S6gd/j50GowEjKLoOVOwHP/bWVjKJInBwQqdOYMdPrf1oVlelTlyfFK3CKxL1uahMDAr+vy8T7yMQ==} + '@types/web-bluetooth@0.0.21': + resolution: {integrity: sha512-oIQLCGWtcFZy2JW77j9k8nHzAOpqMHLQejDA48XXMWH6tjCQHz5RCFz1bzsmROyL6PUm+LLnUiI4BCn221inxA==} + '@typescript-eslint/eslint-plugin@5.50.0': resolution: {integrity: sha512-vwksQWSFZiUhgq3Kv7o1Jcj0DUNylwnIlGvKvLLYsq8pAWha6/WCnXUeaSoNNha/K7QSf2+jvmkxggC1u3pIwQ==} engines: {node: ^12.22.0 || ^14.17.0 || >=16.0.0} @@ -981,12 +1018,25 @@ packages: '@types/node': optional: true + '@vueuse/core@13.6.0': + resolution: {integrity: sha512-DJbD5fV86muVmBgS9QQPddVX7d9hWYswzlf4bIyUD2dj8GC46R1uNClZhVAmsdVts4xb2jwp1PbpuiA50Qee1A==} + peerDependencies: + vue: ^3.5.0 + '@vueuse/core@9.12.0': resolution: {integrity: sha512-h/Di8Bvf6xRcvS/PvUVheiMYYz3U0tH3X25YxONSaAUBa841ayMwxkuzx/DGUMCW/wHWzD8tRy2zYmOC36r4sg==} + '@vueuse/metadata@13.6.0': + resolution: {integrity: sha512-rnIH7JvU7NjrpexTsl2Iwv0V0yAx9cw7+clymjKuLSXG0QMcLD0LDgdNmXic+qL0SGvgSVPEpM9IDO/wqo1vkQ==} + '@vueuse/metadata@9.12.0': resolution: {integrity: sha512-9oJ9MM9lFLlmvxXUqsR1wLt1uF7EVbP5iYaHJYqk+G2PbMjY6EXvZeTjbdO89HgoF5cI6z49o2zT/jD9SVoNpQ==} + '@vueuse/shared@13.6.0': + resolution: {integrity: sha512-pDykCSoS2T3fsQrYqf9SyF0QXWHmcGPQ+qiOVjlYSzlWd9dgppB2bFSM1GgKKkt7uzn0BBMV3IbJsUfHG2+BCg==} + peerDependencies: + vue: ^3.5.0 + '@vueuse/shared@9.12.0': resolution: {integrity: sha512-TWuJLACQ0BVithVTRbex4Wf1a1VaRuSpVeyEd4vMUWl54PzlE0ciFUshKCXnlLuD0lxIaLK4Ypj3NXYzZh4+SQ==} @@ -1184,6 +1234,18 @@ packages: resolution: {integrity: sha512-6E3D4BQLXHLl3c/NwirWVZ+BCkMq2qsYxdeAGGOijKrx09FaqU+HktFL6QwAwNvgJiMLnv6AQ2C1gFZx0h1CBg==} engines: {node: '>=0.10.0'} + ant-design-vue@4.2.6: + resolution: {integrity: sha512-t7eX13Yj3i9+i5g9lqFyYneoIb3OzTvQjq9Tts1i+eiOd3Eva/6GagxBSXM1fOCjqemIu0FYVE1ByZ/38epR3Q==} + engines: {node: '>=12.22.0'} + peerDependencies: + vue: '>=3.2.0' + + ant-design-x-vue@1.3.2: + resolution: {integrity: sha512-17me/rUGAj5w8zN98ngGSqjtTckZT4nKexnta4TBw7SNC4+gXB4jTzQqk4ZCLVuoXSZ0w3Qa4FfyTEP8z6Fx4g==} + peerDependencies: + ant-design-vue: '>=4.0.0' + vue: '>=3.5.0' + any-promise@1.3.0: resolution: {integrity: sha512-7UvmKalWRt1wgjL1RrGxoSJW/0QZFIegpeGvZG9kjp8vrRu55XTHbwnqq2GpXm9uLbcuhxm3IqX9OB4MZR1b2A==} @@ -1229,6 +1291,9 @@ packages: resolution: {integrity: sha512-BNcM+RXxndPxiZ2rd76k6nyQLRZr2/B/sdi8pQ+Joafr5AH279L40dfokSUTp8O+AaqYjXWhblBWa2st2nc4fQ==} engines: {node: '>=0.10.0'} + array-tree-filter@2.1.0: + resolution: {integrity: sha512-4ROwICNlNw/Hqa9v+rk5h22KjmzB1JGTMVKP2AKJBOCgb0yL0ASf0+YvCcLNNwquOHNX48jkeZIJ3a+oOQqKcw==} + array-union@2.1.0: resolution: {integrity: sha512-HGyxoOTYUyCM6stUe6EJgnd4EoewAI7zMdfqO+kGjnlZmBDz/cR5pf8r/cR4Wq60sL/p0IkcjUEEPwS3GFrIyw==} engines: {node: '>=8'} @@ -1326,6 +1391,9 @@ packages: async-settle@0.2.1: resolution: {integrity: sha512-3b4i8Bf/9Zw3V/EsLtMx+qj2r0mDYotjMhzXJQxjvESOe5LgevY5KaH5BHROVZWHE7TlSY2FkeTgIgDvdkRFYQ==} + async-validator@4.2.5: + resolution: {integrity: sha512-7HhHjtERjqlNbZtqNqy2rckN/SpOOlmDliet+lP7k+eKZEjPk3DgyeU9lIXLdeLz0uBbbVp+9Qdow9wJWgwwfg==} + async@1.5.2: resolution: {integrity: sha512-nSVgobk4rv61R9PUSDtYt7mPVB2olxNR5RWJcAsH676/ef11bUZwvu7+RGYrYauVdDPcO519v68wRhXQtxsV9w==} @@ -1607,6 +1675,9 @@ packages: resolution: {integrity: sha512-qOhPa/Fj7s6TY8H8esGu5QNpMMQxz79h+urzrNYN6mn+9BnxlDGf5QZ+XeCDsxSjPqsSR56XOZOJmpeurnLMeg==} engines: {node: '>=0.10.0'} + classnames@2.5.1: + resolution: {integrity: sha512-saHYOzhIQs6wy2sVxTM6bUDsQO4F50V9RQ22qBpEdCW+I+/Wmke2HOl6lS6dTpdxVhb88/I6+Hs+438c3lfUow==} + clean-stack@2.2.0: resolution: {integrity: sha512-4diC9HaTE+KRAMWhDhrGOECgWZxoevMc5TlkObMqNSsVU62PYzXZ/SMTjzyGAFF1YusgxGcSWTEXBhp0CPwQ1A==} engines: {node: '>=6'} @@ -1809,6 +1880,9 @@ packages: csstype@2.6.21: resolution: {integrity: sha512-Z1PhmomIfypOpoMjRQB70jfvy/wxT50qW08YXO5lMIJkrdq4yOTR+AW7FqutScmB9NkLwxo+jU+kZLbofZZq/w==} + csstype@3.1.3: + resolution: {integrity: sha512-M1uQkMl8rQK/szD0LNhtqxIPLpimGm8sOBwU7lLnCpSbTyY3yeU1Vc7l4KT5zT4s/yOxHH5O7tIuuLOCnLADRw==} + cwd@0.10.0: resolution: {integrity: sha512-YGZxdTTL9lmLkCUTpg4j0zQ7IhRB5ZmqNBbGCl3Tg6MP/d5/6sY7L5mmTjzbc6JKgVZYiqTQTNhPFsbXNGlRaA==} engines: {node: '>=0.8'} @@ -1957,6 +2031,12 @@ packages: resolution: {integrity: sha512-yS+Q5i3hBf7GBkd4KG8a7eBNNWNGLTaEwwYWUijIYM7zrlYDM0BFXHjjPWlWZ1Rg7UaddZeIDmi9jF3HmqiQ2w==} engines: {node: '>=6.0.0'} + dom-align@1.12.4: + resolution: {integrity: sha512-R8LUSEay/68zE5c8/3BDxiTEvgb4xZTF0RKmAHfiEVN3klfIpXfi2/QCoiWPccVQ0J/ZGdz9OjzL4uJEP/MRAw==} + + dom-scroll-into-view@2.0.1: + resolution: {integrity: sha512-bvVTQe1lfaUr1oFzZX80ce9KLDlZ3iU+XGNE/bz9HnGdklTieqsbmsLHe+rT2XWqopvL0PckkYqN7ksmm5pe3w==} + dom-serializer@0.2.2: resolution: {integrity: sha512-2/xPb3ORsQ42nHYiSunXkDjPLBaEj/xTwUO4B7XCZQTRk7EBtTOPaygh10YAAh2OI1Qrp6NWfpAhzswj0ydt9g==} @@ -3083,6 +3163,10 @@ packages: resolution: {integrity: sha512-h5PpgXkWitc38BBMYawTYMWJHFZJVnBquFE57xFpjB8pJFiF6gZ+bU+WyI/yqXiFR5mdLsgYNaPe8uao6Uv9Og==} engines: {node: '>=0.10.0'} + is-plain-object@3.0.1: + resolution: {integrity: sha512-Xnpx182SBMrr/aBik8y+GuR4U1L9FqMSojwDQwPMmxyC6bvEqly9UBCxhauBF5vNh2gwWJNX6oDV7O+OM4z34g==} + engines: {node: '>=0.10.0'} + is-posix-bracket@0.1.1: resolution: {integrity: sha512-Yu68oeXJ7LeWNmZ3Zov/xg/oDBnBK2RNxwYY1ilNJX+tKKZqgPK+qOn/Gs9jEu66KDY9Netf5XLKNGzas/vPfQ==} engines: {node: '>=0.10.0'} @@ -3552,6 +3636,10 @@ packages: resolution: {integrity: sha512-k+yt5n3l48JU4k8ftnKG6V7u32wyH2NfKzeMto9F/QRE0amxy/LayxwlvjjkZEIzqR+19IrtFO8p5kB9QaYUFg==} engines: {node: '>=0.10.0'} + loose-envify@1.4.0: + resolution: {integrity: sha512-lyuxPGr/Wfhrlem2CL/UcnUc1zcqKAImBDzukY7Y5F/yQiNdko6+fRLevlw1HgMySw7f611UIY408EtxRSoK3Q==} + hasBin: true + lower-case@1.1.4: resolution: {integrity: sha512-2Fgx1Ycm599x+WGpIYwJOvsjmXFzTSc34IwDWALRA/8AopUKAVPwfJ+h5+f85BCp0PWmmJcWzEpxOpoXycMpdA==} @@ -3805,6 +3893,9 @@ packages: resolution: {integrity: sha512-fpoe2T0RbHwBTBUOftAfBPaDEi06ufaUai0mE6Yn1kacc3SnTErfb/h+X94VXzI64rKFHYImXSvdwGGCmwOqCA==} engines: {node: '>=0.10.0'} + nanopop@2.4.2: + resolution: {integrity: sha512-NzOgmMQ+elxxHeIha+OG/Pv3Oc3p4RU2aBhwWwAqDpXrdTbtRylbRLQztLy8dMMwfl6pclznBdfUhccEn9ZIzw==} + nanoseconds@0.1.0: resolution: {integrity: sha512-6yOHqTvJNI9xGmVHWQ4ZTYhGpT0O4h9N+uk/UuRVPI8TskViB4s4QL3y+jY/Yxsdz7gvoBGPCHWRUibOyyYMwA==} engines: {node: '>=0.10.0'} @@ -4592,6 +4683,9 @@ packages: resolution: {integrity: sha512-J1zdXCky5GmNnuauESROVu31MQSnLoYvlyEn6j2Ztk6Q5EHFIhxkMhYcv6vuDzl2XEzoRr856QwzMgWM/TmZgw==} engines: {node: '>=0.10.0'} + shallow-equal@1.2.1: + resolution: {integrity: sha512-S4vJDjHHMBaiZuT9NPb616CSmLf618jawtv3sufLl6ivK8WocjAo58cXwbRV1cgqxH0Qbv+iUt6m05eqEa2IRA==} + shebang-command@1.2.0: resolution: {integrity: sha512-EV3L1+UQWGor21OmnvojK36mhg+TyIKDh3iFBKBohr5xeXIhNBcx8oWdgkTEEQ+BEFFYdLRuqMfd5L84N1V5Vg==} engines: {node: '>=0.10.0'} @@ -4888,6 +4982,9 @@ packages: strip-literal@1.0.0: resolution: {integrity: sha512-5o4LsH1lzBzO9UFH63AJ2ad2/S2AVx6NtjOcaz+VTT2h1RiRvbipW72z8M/lxEhcPHDBQwpDrnTF7sXy/7OwCQ==} + stylis@4.3.6: + resolution: {integrity: sha512-yQ3rwFWRfwNUY7H5vpU0wfdkNSnvnJinhF9830Swlaxl03zsOjCfmX0ugac+3LtK0lYSgwL/KXc8oYL3mG4YFQ==} + success-symbol@0.1.0: resolution: {integrity: sha512-7S6uOTxPklNGxOSbDIg4KlVLBQw1UiGVyfCUYgYxrZUKRblUkmGj7r8xlfQoFudvqLv6Ap5gd76/IIFfI9JG2A==} engines: {node: '>=0.10.0'} @@ -4964,6 +5061,10 @@ packages: thenify@3.3.1: resolution: {integrity: sha512-RVZSIV5IG10Hk3enotrhvz0T9em6cyHBLkH/YAZuKqd8hRkKhSfCGIcP2KUY0EPxndzANBmNllzWPwak+bheSw==} + throttle-debounce@5.0.2: + resolution: {integrity: sha512-B71/4oyj61iNH0KeCamLuE2rmKuTO5byTOSVwECM5FA7TiAiAW+UqTKZ9ERueC4qvgSttUhdmq1mXC3kJqGX7A==} + engines: {node: '>=12.22'} + through2-filter@2.0.0: resolution: {integrity: sha512-miwWajb1B80NvIVKXFPN/o7+vJc4jYUvnZCwvhicRAoTxdD9wbcjri70j+BenCrN/JXEPKDjhpw4iY7yiNsCGg==} @@ -5392,6 +5493,12 @@ packages: peerDependencies: typescript: '*' + vue-types@3.0.2: + resolution: {integrity: sha512-IwUC0Aq2zwaXqy74h4WCvFCUtoV0iSWr0snWnE9TnU18S66GAQyqQbRf2qfJtUuiFsBf6qp0MEwdonlwznlcrw==} + engines: {node: '>=10.15.0'} + peerDependencies: + vue: ^3.0.0 + vue@3.2.45: resolution: {integrity: sha512-9Nx/Mg2b2xWlXykmCwiTUCWHbWIj53bnkizBxKai1g61f2Xit700A1ljowpTIM11e3uipOeiPcSqnmBg6gyiaA==} @@ -5404,6 +5511,9 @@ packages: resolution: {integrity: sha512-1S0lwbHo3kNUKA4VomBAhqn4DPjQkIKSdbOin5K7EFUQNwyIKx+wZMGXKI53RUjla8V2B8ouQduUlgtx8LoSMw==} engines: {node: '>=0.10.0'} + warning@4.0.3: + resolution: {integrity: sha512-rpJyN222KWIvHJ/F53XSZv0Zl/accqHR8et1kpaMTD/fLCRxtV8iX8czMzY7sVZupTI3zcUTg8eycS2kNF9l6w==} + webpack-sources@3.2.3: resolution: {integrity: sha512-/DyMEOrDgLKKIG0fmvtz+4dUX/3Ghozwgm6iPp8KRhvn+eQf9+Q7GWxVNMk3+uCPWfdXYC4ExGBckIXdFEfH1w==} engines: {node: '>=10.13.0'} @@ -5528,6 +5638,22 @@ snapshots: '@jridgewell/gen-mapping': 0.1.1 '@jridgewell/trace-mapping': 0.3.17 + '@ant-design/colors@6.0.0': + dependencies: + '@ctrl/tinycolor': 3.6.1 + + '@ant-design/fast-color@2.0.6': + dependencies: + '@babel/runtime': 7.28.2 + + '@ant-design/icons-svg@4.4.2': {} + + '@ant-design/icons-vue@7.0.1(vue@3.2.45)': + dependencies: + '@ant-design/colors': 6.0.0 + '@ant-design/icons-svg': 4.4.2 + vue: 3.2.45 + '@antfu/install-pkg@0.1.1': dependencies: execa: 5.1.1 @@ -5769,6 +5895,14 @@ snapshots: '@babel/helper-validator-identifier': 7.24.6 to-fast-properties: 2.0.0 + '@ctrl/tinycolor@3.6.1': {} + + '@emotion/hash@0.9.2': {} + + '@emotion/unitless@0.10.0': {} + + '@emotion/unitless@0.8.1': {} + '@esbuild/android-arm64@0.16.17': optional: true @@ -6038,6 +6172,11 @@ snapshots: '@rushstack/eslint-patch@1.2.0': {} + '@simonwep/pickr@1.8.2': + dependencies: + core-js: 3.44.0 + nanopop: 2.4.2 + '@trysound/sax@0.2.0': {} '@types/estree@1.0.0': {} @@ -6068,6 +6207,8 @@ snapshots: '@types/web-bluetooth@0.0.16': {} + '@types/web-bluetooth@0.0.21': {} + '@typescript-eslint/eslint-plugin@5.50.0(@typescript-eslint/parser@5.50.0(eslint@8.33.0)(typescript@4.9.5))(eslint@8.33.0)(typescript@4.9.5)': dependencies: '@typescript-eslint/parser': 5.50.0(eslint@8.33.0)(typescript@4.9.5) @@ -6464,6 +6605,13 @@ snapshots: optionalDependencies: '@types/node': 18.11.18 + '@vueuse/core@13.6.0(vue@3.2.45)': + dependencies: + '@types/web-bluetooth': 0.0.21 + '@vueuse/metadata': 13.6.0 + '@vueuse/shared': 13.6.0(vue@3.2.45) + vue: 3.2.45 + '@vueuse/core@9.12.0(vue@3.2.45)': dependencies: '@types/web-bluetooth': 0.0.16 @@ -6474,8 +6622,14 @@ snapshots: - '@vue/composition-api' - vue + '@vueuse/metadata@13.6.0': {} + '@vueuse/metadata@9.12.0': {} + '@vueuse/shared@13.6.0(vue@3.2.45)': + dependencies: + vue: 3.2.45 + '@vueuse/shared@9.12.0(vue@3.2.45)': dependencies: vue-demi: 0.13.11(vue@3.2.45) @@ -6742,6 +6896,44 @@ snapshots: dependencies: ansi-wrap: 0.1.0 + ant-design-vue@4.2.6(vue@3.2.45): + dependencies: + '@ant-design/colors': 6.0.0 + '@ant-design/icons-vue': 7.0.1(vue@3.2.45) + '@babel/runtime': 7.28.2 + '@ctrl/tinycolor': 3.6.1 + '@emotion/hash': 0.9.2 + '@emotion/unitless': 0.8.1 + '@simonwep/pickr': 1.8.2 + array-tree-filter: 2.1.0 + async-validator: 4.2.5 + csstype: 3.1.3 + dayjs: 1.11.7 + dom-align: 1.12.4 + dom-scroll-into-view: 2.0.1 + lodash: 4.17.21 + lodash-es: 4.17.21 + resize-observer-polyfill: 1.5.1 + scroll-into-view-if-needed: 2.2.31 + shallow-equal: 1.2.1 + stylis: 4.3.6 + throttle-debounce: 5.0.2 + vue: 3.2.45 + vue-types: 3.0.2(vue@3.2.45) + warning: 4.0.3 + + ant-design-x-vue@1.3.2(ant-design-vue@4.2.6(vue@3.2.45))(vue@3.2.45): + dependencies: + '@ant-design/fast-color': 2.0.6 + '@emotion/hash': 0.9.2 + '@emotion/unitless': 0.10.0 + '@vueuse/core': 13.6.0(vue@3.2.45) + ant-design-vue: 4.2.6(vue@3.2.45) + classnames: 2.5.1 + csstype: 3.1.3 + stylis: 4.3.6 + vue: 3.2.45 + any-promise@1.3.0: {} anymatch@3.1.3: @@ -6784,6 +6976,8 @@ snapshots: get-value: 2.0.6 kind-of: 5.1.0 + array-tree-filter@2.1.0: {} + array-union@2.1.0: {} array-unique@0.2.1: {} @@ -6918,6 +7112,8 @@ snapshots: dependencies: async-done: 0.4.0 + async-validator@4.2.5: {} + async@1.5.2: {} asynckit@0.4.0: {} @@ -7491,6 +7687,8 @@ snapshots: isobject: 3.0.1 static-extend: 0.1.2 + classnames@2.5.1: {} + clean-stack@2.2.0: {} cli-cursor@1.0.2: @@ -7649,8 +7847,7 @@ snapshots: copy-to@2.0.1: {} - core-js@3.44.0: - optional: true + core-js@3.44.0: {} core-util-is@1.0.3: {} @@ -7707,6 +7904,8 @@ snapshots: csstype@2.6.21: {} + csstype@3.1.3: {} + cwd@0.10.0: dependencies: find-pkg: 0.1.2 @@ -7855,6 +8054,10 @@ snapshots: dependencies: esutils: 2.0.3 + dom-align@1.12.4: {} + + dom-scroll-into-view@2.0.1: {} + dom-serializer@0.2.2: dependencies: domelementtype: 2.3.0 @@ -9258,6 +9461,8 @@ snapshots: dependencies: isobject: 3.0.1 + is-plain-object@3.0.1: {} + is-posix-bracket@0.1.1: {} is-primitive@2.0.0: {} @@ -9783,6 +9988,10 @@ snapshots: longest@1.0.1: {} + loose-envify@1.4.0: + dependencies: + js-tokens: 4.0.0 + lower-case@1.1.4: {} lru-cache@5.1.1: @@ -10092,6 +10301,8 @@ snapshots: transitivePeerDependencies: - supports-color + nanopop@2.4.2: {} + nanoseconds@0.1.0: {} natural-compare-lite@1.4.0: {} @@ -11027,6 +11238,8 @@ snapshots: lazy-cache: 0.2.7 mixin-object: 2.0.1 + shallow-equal@1.2.1: {} + shebang-command@1.2.0: dependencies: shebang-regex: 1.0.0 @@ -11345,6 +11558,8 @@ snapshots: dependencies: acorn: 8.8.2 + stylis@4.3.6: {} + success-symbol@0.1.0: {} supports-color@2.0.0: {} @@ -11472,6 +11687,8 @@ snapshots: dependencies: any-promise: 1.3.0 + throttle-debounce@5.0.2: {} + through2-filter@2.0.0: dependencies: through2: 2.0.5 @@ -12088,6 +12305,11 @@ snapshots: '@volar/vue-typescript': 1.0.24 typescript: 4.9.5 + vue-types@3.0.2(vue@3.2.45): + dependencies: + is-plain-object: 3.0.1 + vue: 3.2.45 + vue@3.2.45: dependencies: '@vue/compiler-dom': 3.2.45 @@ -12103,6 +12325,10 @@ snapshots: warning-symbol@0.1.0: {} + warning@4.0.3: + dependencies: + loose-envify: 1.4.0 + webpack-sources@3.2.3: {} webpack-virtual-modules@0.5.0: {} diff --git a/src/router copy/app-menus/index.ts b/src/router copy/app-menus/index.ts new file mode 100644 index 0000000..9a8a4f0 --- /dev/null +++ b/src/router copy/app-menus/index.ts @@ -0,0 +1,20 @@ +/* + * @Author: RenXiaoDong + * @Date: 2025-06-19 01:45:53 + */ +import { appRoutes } from '../routes'; + +const mixinRoutes = [...appRoutes]; + +const appClientMenus = mixinRoutes.map((el) => { + const { name, path, meta, redirect, children } = el; + return { + name, + path, + meta, + redirect, + children, + }; +}); + +export default mixinRoutes; diff --git a/src/router copy/constants.ts b/src/router copy/constants.ts new file mode 100644 index 0000000..1b17254 --- /dev/null +++ b/src/router copy/constants.ts @@ -0,0 +1,30 @@ +/* + * @Author: RenXiaoDong + * @Date: 2025-06-24 16:50:35 + */ +export const WHITE_LIST = [ + { name: 'notFound', children: [] }, + { name: 'login', children: [] }, +]; + +export const NOT_FOUND = { + name: 'notFound', +}; + +export const REDIRECT_ROUTE_NAME = 'Redirect'; + +export const DEFAULT_ROUTE_NAME = 'main'; + +export const DEFAULT_ROUTE = { + title: '首页', + name: DEFAULT_ROUTE_NAME, + fullPath: '/', +}; + +export const MENU_GROUP_IDS = { + DATA_ENGINE_ID: 1, // 全域数据分析 + MANAGEMENT_ID: -1, // 管理中心 + PROPERTY_ID: 10, // 资产营销平台 + WORK_BENCH_ID: -99, // 工作台 + AGENT: 2, // 智能体 +}; diff --git a/src/router copy/guard/index.ts b/src/router copy/guard/index.ts new file mode 100644 index 0000000..983ba1a --- /dev/null +++ b/src/router copy/guard/index.ts @@ -0,0 +1,27 @@ +/* + * @Author: 田鑫 + * @Date: 2023-03-05 18:14:17 + * @LastEditors: Please set LastEditors + * @LastEditTime: 2025-06-23 04:10:41 + * @Description: + */ +import type { Router } from 'vue-router'; +import { setRouteEmitter } from '@/utils/route-listener'; +import setupUserLoginInfoGuard from './userLoginInfo'; +import { MENU_GROUP_IDS } from '@/router/constants'; +// import setupPermissionGuard from './permission'; + +function setupPageGuard(router: Router) { + router.beforeEach(async (to) => { + // emit route change + setRouteEmitter(to); + }); +} + + +export default function createRouteGuard(router: Router) { + + setupPageGuard(router); + setupUserLoginInfoGuard(router); + // setupPermissionGuard(router); +} diff --git a/src/router copy/guard/permission.ts b/src/router copy/guard/permission.ts new file mode 100644 index 0000000..9b32487 --- /dev/null +++ b/src/router copy/guard/permission.ts @@ -0,0 +1,29 @@ +/* + * @Author: 田鑫 + * @Date: 2023-03-05 14:46:43 + * @LastEditors: Please set LastEditors + * @LastEditTime: 2025-06-23 04:07:43 + * @Description: 路由权限守卫 + */ +// import type { Router, RouteRecordNormalized } from 'vue-router'; +// import NProgress from 'nprogress'; // progress bar +// import { useAppStore } from '@/stores'; + +// export default function setupPermissionGuard(router: Router) { +// router.beforeEach(async (to, from, next) => { +// console.log('access permission router guard'); +// const appStore = useAppStore(); +// //* 菜单是否为服务端渲染 +// if (appStore.menuFromServer) { +// //* 没有服务端渲染的菜单 +// if (!appStore.appAsyncMenus) { +// // todo 请求服务端渲染菜单的接口,当前为mock数据 +// // await appStore.fetchServerMenuConfig(); +// } +// next(); +// } else { +// next(); +// } +// NProgress.done(); +// }); +// } diff --git a/src/router copy/guard/userLoginInfo.ts b/src/router copy/guard/userLoginInfo.ts new file mode 100644 index 0000000..2d83b6b --- /dev/null +++ b/src/router copy/guard/userLoginInfo.ts @@ -0,0 +1,45 @@ +/* + * @Author: RenXiaoDong + * @Date: 2025-06-22 22:59:16 + */ +import type { Router } from 'vue-router'; +import NProgress from 'nprogress'; +import { goUserLogin } from '@/utils/user'; +// import router from '@/router'; +import { checkRoutePermission } from '@/permission/permission'; + +import { useUserStore } from '@/stores/modules/user'; + +export default function setupUserLoginInfoGuard(router: Router) { + router.beforeEach(async (to, from, next) => { + NProgress.start(); + const userStore = useUserStore(); + + const routeName = to?.name as string; + const requiresAuth = to?.meta?.requiresAuth || false; + const requireLogin = to?.meta?.requireLogin || false; + const query = to?.query ?? {}; + + if (requireLogin && !userStore.isLogin) { + goUserLogin(query); + next(); + return; + } + + // if (requiresAuth) { + // const hasPermission = checkRoutePermission(routeName); + // if (!hasPermission) { + // AMessage.error('您没有权限访问该页面'); + // next('/'); + // return; + // } + // next(); + // return; + // } + + next(); + }); + router.afterEach((to) => { + NProgress.done(); + }); +} diff --git a/src/router copy/index.ts b/src/router copy/index.ts new file mode 100644 index 0000000..0af8eb0 --- /dev/null +++ b/src/router copy/index.ts @@ -0,0 +1,48 @@ +/* + * @Author: RenXiaoDong + * @Date: 2025-06-22 22:59:16 + */ +import { createRouter, createWebHistory } from 'vue-router'; +import { appRoutes } from './routes'; +import { NOT_FOUND_ROUTE } from './routes/base'; +import NProgress from 'nprogress'; +import 'nprogress/nprogress.css'; +import { MENU_GROUP_IDS } from './constants'; +import createRouteGuard from './guard'; + +NProgress.configure({ showSpinner: false }); // NProgress Configuration + +export const router = createRouter({ + history: createWebHistory(import.meta.env.BASE_URL), + routes: [ + { + path: '/login', + name: 'UserLogin', + component: () => import('@/views/components/login'), + meta: { + requiresAuth: false, + requireLogin: false, + }, + }, + { + path: '/', + name: 'Home', + component: () => import('@/views/components/workplace'), + meta: { + hideSidebar: true, + requiresAuth: false, + requireLogin: true, + id: MENU_GROUP_IDS.WORK_BENCH_ID, + }, + }, + ...appRoutes, + NOT_FOUND_ROUTE, + ], + scrollBehavior() { + return { top: 0 }; + }, +}); + +createRouteGuard(router); + +export default router; diff --git a/src/router copy/routes/base.ts b/src/router copy/routes/base.ts new file mode 100644 index 0000000..f10ef89 --- /dev/null +++ b/src/router copy/routes/base.ts @@ -0,0 +1,35 @@ +import type { RouteRecordRaw } from 'vue-router'; +import { REDIRECT_ROUTE_NAME } from '@/router/constants'; + +// export const REDIRECT_MAIN: RouteRecordRaw = { +// path: '/redirect', +// name: 'redirect', +// meta: { +// requiresAuth: false, +// requireLogin: false, +// hideInMenu: true, +// }, +// children: [ +// { +// path: '/redirect/:path', +// name: REDIRECT_ROUTE_NAME, +// component: () => import('@/layouts/Basic.vue'), +// meta: { +// requiresAuth: false, +// requireLogin: false, +// hideInMenu: true, +// }, +// }, +// ], +// }; + +export const NOT_FOUND_ROUTE: RouteRecordRaw = { + path: '/:pathMatch(.*)*', + name: 'notFound', + component: () => import('@/layouts/NotFound.vue'), + meta: { + requiresAuth: false, + hideInMenu: true, + hideSidebar: true, + }, +}; diff --git a/src/router copy/routes/index.ts b/src/router copy/routes/index.ts new file mode 100644 index 0000000..433925f --- /dev/null +++ b/src/router copy/routes/index.ts @@ -0,0 +1,22 @@ +import type { RouteRecordNormalized } from 'vue-router'; +// import { REDIRECT_MAIN, NOT_FOUND_ROUTE } from './base'; +import { MENU_GROUP_IDS } from '@/router/constants'; + +const modules = import.meta.glob('./modules/*.ts', { eager: true }); +// const externalModules = import.meta.glob('./externalModules/*.ts', { +// eager: true, +// }); + +function formatModules(_modules: any, result: RouteRecordNormalized[]) { + Object.keys(_modules).forEach((key) => { + const defaultModule = _modules[key].default; + if (!defaultModule) return; + const moduleList = Array.isArray(defaultModule) ? [...defaultModule] : [defaultModule]; + result.push(...moduleList); + }); + return result; +} + +export const appRoutes: RouteRecordNormalized[] = formatModules(modules, []); + +// export const appExternalRoutes: RouteRecordNormalized[] = formatModules(externalModules, []); diff --git a/src/router copy/routes/modules/agent.ts b/src/router copy/routes/modules/agent.ts new file mode 100644 index 0000000..3617ce0 --- /dev/null +++ b/src/router copy/routes/modules/agent.ts @@ -0,0 +1,65 @@ +import type { AppRouteRecordRaw } from '../types'; +import { MENU_GROUP_IDS } from '@/router/constants'; + +import IconRepository from '@/assets/svg/svg-agent.svg'; + +const COMPONENTS: AppRouteRecordRaw[] = [ + { + path: '/agent', + name: 'Agent', + redirect: 'agent/index', + meta: { + locale: '灵机ai', + icon: IconRepository, + requiresAuth: true, + requireLogin: true, + roles: ['*'], + id: MENU_GROUP_IDS.AGENT, + }, + children: [ + { + path: 'index', + name: 'AgentIndex', + component: () => import('@/views/agent/index'), + meta: { + locale:'智能体应用', + requiresAuth: false, + requireLogin: true, + hideFooter: true, + isAgentRoute: true + }, + }, + { + path: 'chat', + name: 'AgentChat', + component: () => import('@/views/agent/chat'), + meta: { + hideSidebar: true, + requiresAuth: false, + requireLogin: true, + hideFooter: true, + id: MENU_GROUP_IDS.AGENT, + isAgentRoute: true, + hideInMenu: true, + }, + }, + + { + path: 'workFlow', + name: 'AgentWorkFlow', + component: () => import('@/views/agent/work-flow'), + meta: { + hideSidebar: true, + requiresAuth: false, + requireLogin: true, + hideFooter: true, + id: MENU_GROUP_IDS.AGENT, + isAgentRoute: true, + hideInMenu: true, + }, + }, + ], + }, +]; + +export default COMPONENTS; diff --git a/src/router copy/routes/modules/dataEngine.ts b/src/router copy/routes/modules/dataEngine.ts new file mode 100644 index 0000000..60828fc --- /dev/null +++ b/src/router copy/routes/modules/dataEngine.ts @@ -0,0 +1,89 @@ +import { IconBookmark } from '@arco-design/web-vue/es/icon'; +import type { AppRouteRecordRaw } from '../types'; +import { MENU_GROUP_IDS } from '@/router/constants'; + +const COMPONENTS: AppRouteRecordRaw[] = [ + { + path: '/dataEngine', + name: 'DataEngine', + redirect: 'dataEngine/hotTranslation', + meta: { + locale: '全域数据引擎', + icon: IconBookmark, + requiresAuth: true, + requireLogin: true, + roles: ['*'], + id: MENU_GROUP_IDS.DATA_ENGINE_ID, + }, + children: [ + { + path: 'hotTranslation', + name: 'DataEngineHotTranslation', + meta: { + locale: '行业热门话题洞察', + requiresAuth: true, + requireLogin: true, + roles: ['*'], + }, + component: () => import('@/views/components/dataEngine/hotTranslation.vue'), + }, + { + path: 'hotCloud', + name: 'DataEngineHotCloud', + meta: { + locale: '行业词云', + requiresAuth: true, + requireLogin: true, + roles: ['*'], + }, + component: () => import('@/views/components/dataEngine/hotCloud.vue'), + }, + { + path: 'keyWord', + name: 'DataEngineKeyWord', + meta: { + locale: '行业关键词动向', + requiresAuth: true, + requireLogin: true, + roles: ['*'], + }, + component: () => import('@/views/components/dataEngine/keyWord.vue'), + }, + { + path: 'userPainPoints', + name: 'DataEngineUserPainPoints', + meta: { + locale: '用户痛点观察', + requiresAuth: true, + requireLogin: true, + roles: ['*'], + }, + component: () => import('@/views/components/dataEngine/userPainPoints.vue'), + }, + { + path: 'keyBrandMovement', + name: 'DataEngineKeyBrandMovement', + meta: { + locale: '重点品牌动向', + requiresAuth: true, + requireLogin: true, + roles: ['*'], + }, + component: () => import('@/views/components/dataEngine/keyBrandMovement.vue'), + }, + { + path: 'userPersona', + name: 'DataEngineUserPersona', + meta: { + locale: '用户画像', + requiresAuth: true, + requireLogin: true, + roles: ['*'], + }, + component: () => import('@/views/components/dataEngine/userPersona.vue'), + }, + ], + }, +]; + +export default COMPONENTS; diff --git a/src/router copy/routes/modules/management.ts b/src/router copy/routes/modules/management.ts new file mode 100644 index 0000000..4539afc --- /dev/null +++ b/src/router copy/routes/modules/management.ts @@ -0,0 +1,56 @@ +import { IconBookmark } from '@arco-design/web-vue/es/icon'; +import type { AppRouteRecordRaw } from '../types'; +import { MENU_GROUP_IDS } from '@/router/constants'; + +const COMPONENTS: AppRouteRecordRaw[] = [ + { + path: '/management', + name: 'Management', + redirect: 'management/person', + meta: { + locale: '管理中心', + icon: IconBookmark, + requiresAuth: false, + requireLogin: true, + roles: ['*'], + id: MENU_GROUP_IDS.MANAGEMENT_ID, + }, + children: [ + { + path: 'person', + name: 'ManagementPerson', + component: () => import('@/views/components/management/person'), + meta: { + locale: '个人信息', + requiresAuth: false, + requireLogin: true, + roles: ['*'], + }, + }, + { + path: 'enterprise', + name: 'ManagementEnterprise', + component: () => import('@/views/components/management/enterprise'), + meta: { + locale: '企业信息', + requiresAuth: false, + requireLogin: true, + roles: ['*'], + }, + }, + { + path: 'account', + name: 'ManagementAccount', + component: () => import('@/views/components/management/account'), + meta: { + locale: '账号管理', + requiresAuth: false, + requireLogin: true, + roles: ['*'], + }, + }, + ], + }, +]; + +export default COMPONENTS; diff --git a/src/router copy/routes/modules/propertyMarketing.ts b/src/router copy/routes/modules/propertyMarketing.ts new file mode 100644 index 0000000..f47428b --- /dev/null +++ b/src/router copy/routes/modules/propertyMarketing.ts @@ -0,0 +1,227 @@ +/** + * 资产营销平台 + */ + +import type { AppRouteRecordRaw } from '../types'; +import { MENU_GROUP_IDS } from '@/router/constants'; + +import IconRepository from '@/assets/svg/svg-repository.svg'; +import IconMediaAccount from '@/assets/svg/svg-mediaAccount.svg'; +import IconPutAccount from '@/assets/svg/svg-putAccount.svg'; +import IconIntelligentSolution from '@/assets/svg/svg-intelligentSolution.svg'; +import IconProjectManagement from '@/assets/svg/svg-projectManagement.svg'; + +const COMPONENTS: AppRouteRecordRaw[] = [ + { + path: '/repository', + name: 'Repository', + redirect: 'repository/brandMaterials', + meta: { + locale: '品牌资产管理', + icon: IconRepository, + requiresAuth: true, + requireLogin: true, + roles: ['*'], + id: MENU_GROUP_IDS.PROPERTY_ID, + }, + children: [ + { + path: 'brandMaterials', + name: 'RepositoryBrandMaterials', + meta: { + locale: '品牌信息', + requiresAuth: true, + requireLogin: true, + roles: ['*'], + }, + component: () => import('@/views/property-marketing/brands/brand-materials/index.vue'), + }, + ], + }, + { + path: '/media-account', + name: 'MediaAccount', + redirect: 'media-account/accountManagement', + meta: { + locale: '账号资源中心', + icon: IconMediaAccount, + requiresAuth: true, + requireLogin: true, + roles: ['*'], + id: MENU_GROUP_IDS.PROPERTY_ID, + }, + children: [ + { + path: 'manage', + name: 'MediaAccountAccountManagement', + meta: { + locale: '账号管理', + requiresAuth: true, + requireLogin: true, + roles: ['*'], + }, + component: () => import('@/views/property-marketing/media-account/account-manage'), + }, + { + path: 'dashboard', + name: 'MediaAccountAccountDashboard', + meta: { + locale: '账号数据看板', + requiresAuth: true, + requireLogin: true, + roles: ['*'], + }, + component: () => import('@/views/property-marketing/media-account/account-dashboard'), + }, + { + path: 'detail/:id', + name: 'MediaAccountAccountDetails', + meta: { + locale: '账号详情', + requiresAuth: true, + requireLogin: true, + roles: ['*'], + hideInMenu: true, + activeMenu: 'MediaAccountAccountDashboard', + }, + component: () => import('@/views/property-marketing/media-account/account-detail'), + }, + ], + }, + { + path: '/put-account', + name: 'PutAccount', + redirect: 'put-account/accountManagement', + meta: { + locale: '投放资源中心', + icon: IconPutAccount, + requiresAuth: true, + requireLogin: true, + roles: ['*'], + id: MENU_GROUP_IDS.PROPERTY_ID, + }, + children: [ + { + path: 'manage', + name: 'PutAccountAccountManagement', + meta: { + locale: '账户管理', + requiresAuth: true, + requireLogin: true, + roles: ['*'], + }, + component: () => import('@/views/property-marketing/put-account/account-manage'), + }, + { + path: 'data', + name: 'PutAccountAccountData', + meta: { + locale: '账户数据', + requiresAuth: true, + requireLogin: true, + roles: ['*'], + }, + component: () => import('@/views/property-marketing/put-account/account-data'), + }, + { + path: 'account-dashboard', + name: 'PutAccountAccountDashboard', + meta: { + locale: '投放表现分析', + requiresAuth: true, + requireLogin: true, + roles: ['*'], + }, + component: () => import('@/views/property-marketing/put-account/account-dashboard'), + }, + { + path: 'investmentGuidelines', + name: 'PutAccountInvestmentGuidelines', + meta: { + locale: '投放指南', + requiresAuth: true, + requireLogin: true, + roles: ['*'], + }, + component: () => import('@/views/property-marketing/put-account/investment-guidelines'), + }, + { + path: 'detail/:id', + name: 'guideDetail', + meta: { + locale: '投放指南详情', + requiresAuth: true, + hideInMenu: true, + roles: ['*'], + activeMenu: 'PutAccountInvestmentGuidelines', + }, + component: () => import('@/views/property-marketing/put-account/investment-guidelines/detail'), + }, + ], + }, + // { + // path: '/intelligent-solution', + // name: 'IntelligentSolution', + // redirect: 'intelligent-solution/businessAnalysisReport', + // meta: { + // locale: '智能方案管理', + // icon: IconIntelligentSolution, + // requiresAuth: true, + // requireLogin: true, + // roles: ['*'], + // id: MENU_GROUP_IDS.PROPERTY_ID, + // }, + // children: [ + // { + // path: 'businessAnalysisReport', + // name: 'IntelligentSolutionBusinessAnalysisReport', + // meta: { + // locale: '业务洞察报告', + // requiresAuth: true, + // requireLogin: true, + // roles: ['*'], + // }, + // component: () => import('@/views/property-marketing/intelligent-solution/businessAnalysisReport'), + // }, + // { + // path: 'competitiveProductAnalysisReport', + // name: 'IntelligentSolutionCompetitiveProductAnalysisReport', + // meta: { + // locale: '竟品对比报告', + // requiresAuth: true, + // requireLogin: true, + // roles: ['*'], + // }, + // component: () => import('@/views/property-marketing/intelligent-solution/competitiveProductAnalysisReport'), + // }, + // ], + // }, + { + path: '/project-manage', + name: 'ProjectManagement', + redirect: 'project-manage/project-list', + meta: { + locale: '项目管理', + icon: IconProjectManagement, + requiresAuth: true, + requireLogin: true, + roles: ['*'], + id: MENU_GROUP_IDS.PROPERTY_ID, + }, + children: [ + { + path: 'project-list', + name: 'ProjectList', + meta: { + locale: '项目列表', + requiresAuth: true, + requireLogin: true, + roles: ['*'], + }, + component: () => import('@/views/property-marketing/project-manage/project-list'), + }, + ], + }, +]; + +export default COMPONENTS; diff --git a/src/router copy/routes/types.ts b/src/router copy/routes/types.ts new file mode 100644 index 0000000..ab069b8 --- /dev/null +++ b/src/router copy/routes/types.ts @@ -0,0 +1,19 @@ +/* + * @Author: RenXiaoDong + * @Date: 2025-06-19 01:45:53 + */ +import type { RouteMeta, NavigationGuard, RouteComponent } from 'vue-router'; + +export interface AppRouteRecordRaw { + id?: number; + path: string; + name?: string | symbol; + meta?: RouteMeta; + redirect?: string; + component?: RouteComponent; + children?: AppRouteRecordRaw[]; + alias?: string | string[]; + props?: Record; + beforeEnter?: NavigationGuard | NavigationGuard[]; + fullPath?: string; +} diff --git a/src/router copy/typeings.d.ts b/src/router copy/typeings.d.ts new file mode 100644 index 0000000..c9ab096 --- /dev/null +++ b/src/router copy/typeings.d.ts @@ -0,0 +1,20 @@ +import { RouteComponent } from 'vue-router'; + +declare module 'vue-router' { + interface RouteMeta { + roles?: string[]; // Controls roles that have access to the page + requiresAuth?: boolean; // Whether login is required to access the current page (every route must declare) + icon?: RouteComponent | string; // The icon show in the side menu + locale?: string; // The locale name show in side menu and breadcrumb + needNavigate?: boolean; // if set true, the breadcrumb will support navigate + hideInMenu?: boolean; // If true, it is not displayed in the side menu + hideChildrenInMenu?: boolean; // if set true, the children are not displayed in the side menu + activeMenu?: string; // if set name, the menu will be highlighted according to the name you set + order?: number; // Sort routing menu items. If set key, the higher the value, the more forward it is + noAffix?: boolean; // if set true, the tag will not affix in the tab-bar + ignoreCache?: boolean; // if set true, the page will not be cached + hideSidebar?: boolean; + isAgentRoute?:boolean; + requireLogin?: boolean; // 是否需要登陆才能访问 + } +} diff --git a/src/router/guard/userLoginInfo.ts b/src/router/guard/userLoginInfo.ts index cc3f891..2d83b6b 100644 --- a/src/router/guard/userLoginInfo.ts +++ b/src/router/guard/userLoginInfo.ts @@ -26,16 +26,16 @@ export default function setupUserLoginInfoGuard(router: Router) { return; } - if (requiresAuth) { - const hasPermission = checkRoutePermission(routeName); - if (!hasPermission) { - AMessage.error('您没有权限访问该页面'); - next('/'); - return; - } - next(); - return; - } + // if (requiresAuth) { + // const hasPermission = checkRoutePermission(routeName); + // if (!hasPermission) { + // AMessage.error('您没有权限访问该页面'); + // next('/'); + // return; + // } + // next(); + // return; + // } next(); }); diff --git a/src/views/home/index.vue b/src/views/home/index.vue new file mode 100644 index 0000000..d3af21e --- /dev/null +++ b/src/views/home/index.vue @@ -0,0 +1,17 @@ + + + \ No newline at end of file diff --git a/src/views/home/style.scss b/src/views/home/style.scss new file mode 100644 index 0000000..e69de29 diff --git a/vite.config.ts b/vite.config.ts index 1b6d5a9..60742a1 100644 --- a/vite.config.ts +++ b/vite.config.ts @@ -39,7 +39,7 @@ export default defineConfig(({ mode }: ConfigEnv): UserConfig => { '/api': { changeOrigin: true, rewrite: (path) => path.replace(/^\/api/, ''), - target: 'https://lingjiapi.lvfunai.com/api' + target: 'https://lingjiapi.lvfunai.com/api', }, }, },