diff --git a/urbanLifelineWeb/packages/bidding/package.json b/urbanLifelineWeb/packages/bidding/package.json index 9035ebcc..1bfcd3c0 100644 --- a/urbanLifelineWeb/packages/bidding/package.json +++ b/urbanLifelineWeb/packages/bidding/package.json @@ -15,10 +15,12 @@ "element-plus": "^2.12.0", "@element-plus/icons-vue": "^2.3.2", "@vueuse/core": "^11.3.0", - "axios": "^1.7.9" + "axios": "^1.7.9", + "lucide-vue-next": "^0.561.0" }, "devDependencies": { - "@types/node": "^22.0.0", + "@module-federation/vite": "^1.9.3", + "@types/node": "^20.10.0", "@vitejs/plugin-vue": "^5.2.1", "@vitejs/plugin-vue-jsx": "^4.1.1", "typescript": "^5.7.2", diff --git a/urbanLifelineWeb/packages/bidding/pnpm-lock.yaml b/urbanLifelineWeb/packages/bidding/pnpm-lock.yaml index 6b03b240..4ea2b16c 100644 --- a/urbanLifelineWeb/packages/bidding/pnpm-lock.yaml +++ b/urbanLifelineWeb/packages/bidding/pnpm-lock.yaml @@ -17,6 +17,9 @@ dependencies: element-plus: specifier: ^2.12.0 version: 2.12.0(vue@3.5.25) + lucide-vue-next: + specifier: ^0.561.0 + version: 0.561.0(vue@3.5.25) pinia: specifier: ^2.2.8 version: 2.3.1(typescript@5.9.3)(vue@3.5.25) @@ -28,9 +31,12 @@ dependencies: version: 4.6.3(vue@3.5.25) devDependencies: + '@module-federation/vite': + specifier: ^1.9.3 + version: 1.9.4 '@types/node': - specifier: ^22.0.0 - version: 22.19.1 + specifier: ^20.10.0 + version: 20.19.27 '@vitejs/plugin-vue': specifier: ^5.2.1 version: 5.2.4(vite@6.4.1)(vue@3.5.25) @@ -42,7 +48,7 @@ devDependencies: version: 5.9.3 vite: specifier: ^6.0.3 - version: 6.4.1(@types/node@22.19.1) + version: 6.4.1(@types/node@20.19.27) vue-tsc: specifier: ^2.2.0 version: 2.2.12(typescript@5.9.3) @@ -596,10 +602,61 @@ packages: '@jridgewell/sourcemap-codec': 1.5.5 dev: true + /@module-federation/error-codes@0.21.6: + resolution: {integrity: sha512-MLJUCQ05KnoVl8xd6xs9a5g2/8U+eWmVxg7xiBMeR0+7OjdWUbHwcwgVFatRIwSZvFgKHfWEiI7wsU1q1XbTRQ==} + dev: true + + /@module-federation/runtime-core@0.21.6: + resolution: {integrity: sha512-5Hd1Y5qp5lU/aTiK66lidMlM/4ji2gr3EXAtJdreJzkY+bKcI5+21GRcliZ4RAkICmvdxQU5PHPL71XmNc7Lsw==} + dependencies: + '@module-federation/error-codes': 0.21.6 + '@module-federation/sdk': 0.21.6 + dev: true + + /@module-federation/runtime@0.21.6: + resolution: {integrity: sha512-+caXwaQqwTNh+CQqyb4mZmXq7iEemRDrTZQGD+zyeH454JAYnJ3s/3oDFizdH6245pk+NiqDyOOkHzzFQorKhQ==} + dependencies: + '@module-federation/error-codes': 0.21.6 + '@module-federation/runtime-core': 0.21.6 + '@module-federation/sdk': 0.21.6 + dev: true + + /@module-federation/sdk@0.21.6: + resolution: {integrity: sha512-x6hARETb8iqHVhEsQBysuWpznNZViUh84qV2yE7AD+g7uIzHKiYdoWqj10posbo5XKf/147qgWDzKZoKoEP2dw==} + dev: true + + /@module-federation/vite@1.9.4: + resolution: {integrity: sha512-7UckjGCqpN6mCRs8J9+T/we0s4msl4SFJERG1uVQslIQJvomuOeu/+keIAbK6M4vjgRwXxkHKyWPhr95uhdulg==} + dependencies: + '@module-federation/runtime': 0.21.6 + '@module-federation/sdk': 0.21.6 + '@rollup/pluginutils': 5.3.0 + defu: 6.1.4 + estree-walker: 2.0.2 + magic-string: 0.30.21 + pathe: 1.1.2 + transitivePeerDependencies: + - rollup + dev: true + /@rolldown/pluginutils@1.0.0-beta.53: resolution: {integrity: sha512-vENRlFU4YbrwVqNDZ7fLvy+JR1CRkyr01jhSiDpE1u6py3OMzQfztQU2jxykW3ALNxO4kSlqIDeYyD0Y9RcQeQ==} dev: true + /@rollup/pluginutils@5.3.0: + resolution: {integrity: sha512-5EdhGZtnu3V88ces7s53hhfK5KSASnJZv8Lulpc04cWO3REESroJXg73DFsOmgbU2BhwV0E20bu2IDZb3VKW4Q==} + engines: {node: '>=14.0.0'} + peerDependencies: + rollup: ^1.20.0||^2.0.0||^3.0.0||^4.0.0 + peerDependenciesMeta: + rollup: + optional: true + dependencies: + '@types/estree': 1.0.8 + estree-walker: 2.0.2 + picomatch: 4.0.3 + dev: true + /@rollup/rollup-android-arm-eabi@4.53.3: resolution: {integrity: sha512-mRSi+4cBjrRLoaal2PnqH82Wqyb+d3HsPUN/W+WslCXsZsyHa9ZeQQX/pQsZaVIWDkPcpV6jJ+3KLbTbgnwv8w==} cpu: [arm] @@ -805,8 +862,8 @@ packages: resolution: {integrity: sha512-FOvQ0YPD5NOfPgMzJihoT+Za5pdkDJWcbpuj1DjaKZIr/gxodQjY/uWEFlTNqW2ugXHUiL8lRQgw63dzKHZdeQ==} dev: false - /@types/node@22.19.1: - resolution: {integrity: sha512-LCCV0HdSZZZb34qifBsyWlUmok6W7ouER+oQIGBScS8EsZsQbrtFTUrDX4hOl+CS6p7cnNC4td+qrSVGSCTUfQ==} + /@types/node@20.19.27: + resolution: {integrity: sha512-N2clP5pJhB2YnZJ3PIHFk5RkygRX5WO/5f0WC08tp0wd+sv0rsJk3MqWn3CbNmT2J505a5336jaQj4ph1AdMug==} dependencies: undici-types: 6.21.0 dev: true @@ -830,7 +887,7 @@ packages: '@babel/plugin-transform-typescript': 7.28.5(@babel/core@7.28.5) '@rolldown/pluginutils': 1.0.0-beta.53 '@vue/babel-plugin-jsx': 1.5.0(@babel/core@7.28.5) - vite: 6.4.1(@types/node@22.19.1) + vite: 6.4.1(@types/node@20.19.27) vue: 3.5.25(typescript@5.9.3) transitivePeerDependencies: - supports-color @@ -843,7 +900,7 @@ packages: vite: ^5.0.0 || ^6.0.0 vue: ^3.2.25 dependencies: - vite: 6.4.1(@types/node@22.19.1) + vite: 6.4.1(@types/node@20.19.27) vue: 3.5.25(typescript@5.9.3) dev: true @@ -1146,6 +1203,10 @@ packages: ms: 2.1.3 dev: true + /defu@6.1.4: + resolution: {integrity: sha512-mEQCMmwJu317oSz8CwdIOdwf3xMif1ttiM8LTufzc3g6kR+9Pe236twL8j3IYT1F7GfRgGcW6MWxzZjLIkuHIg==} + dev: true + /delayed-stream@1.0.0: resolution: {integrity: sha512-ZySD7Nf91aLB0RxL4KGrKHBXl7Eds1DAmEdcoVawXnLD7SDhpNgtuII2aAkg7a7QS41jxPSZ17p4VdGnMHk3MQ==} engines: {node: '>=0.4.0'} @@ -1406,6 +1467,14 @@ packages: yallist: 3.1.1 dev: true + /lucide-vue-next@0.561.0(vue@3.5.25): + resolution: {integrity: sha512-c5HUckO0qHklVSOf/0vaSR3pEb8fYImRDCRDLde56uqS9js0D/e3RAvq0/YFWjkmyOBKCb0/IdskdoHZQEkT5g==} + peerDependencies: + vue: '>=3.0.1' + dependencies: + vue: 3.5.25(typescript@5.9.3) + dev: false + /magic-string@0.30.21: resolution: {integrity: sha512-vd2F4YUyEXKGcLHoq+TEyCjxueSeHnFxyyjNp80yg0XV4vUhnDer/lvvlqM/arB5bXQN5K2/3oinyCRyx8T2CQ==} dependencies: @@ -1464,6 +1533,10 @@ packages: resolution: {integrity: sha512-b7uo2UCUOYZcnF/3ID0lulOJi/bafxa1xPe7ZPsammBSpjSWQkjNxlt635YGS2MiR9GjvuXCtz2emr3jbsz98g==} dev: true + /pathe@1.1.2: + resolution: {integrity: sha512-whLdWMYL2TwI08hn8/ZqAbrVemu0LNaNNJZX73O6qaIdCTfXutsLhMkjdENX0qhsQ9uIimo4/aQOmXkoon2nDQ==} + dev: true + /picocolors@1.1.1: resolution: {integrity: sha512-xceH2snhtb5M9liqDsmEw56le376mTZkEX/jEb/RxNFyegNul7eNslCXP9FDj/Lcu0X8KEyMceP2ntpaHrDEVA==} @@ -1570,7 +1643,7 @@ packages: picocolors: 1.1.1 dev: true - /vite@6.4.1(@types/node@22.19.1): + /vite@6.4.1(@types/node@20.19.27): resolution: {integrity: sha512-+Oxm7q9hDoLMyJOYfUYBuHQo+dkAloi33apOPP56pzj+vsdJDzr+j1NISE5pyaAuKL4A3UD34qd0lx5+kfKp2g==} engines: {node: ^18.0.0 || ^20.0.0 || >=22.0.0} hasBin: true @@ -1610,7 +1683,7 @@ packages: yaml: optional: true dependencies: - '@types/node': 22.19.1 + '@types/node': 20.19.27 esbuild: 0.25.12 fdir: 6.5.0(picomatch@4.0.3) picomatch: 4.0.3 diff --git a/urbanLifelineWeb/packages/bidding/public/logo.jpg b/urbanLifelineWeb/packages/bidding/public/logo.jpg new file mode 100644 index 00000000..18b5da66 Binary files /dev/null and b/urbanLifelineWeb/packages/bidding/public/logo.jpg differ diff --git a/urbanLifelineWeb/packages/bidding/src/App.vue b/urbanLifelineWeb/packages/bidding/src/App.vue new file mode 100644 index 00000000..7c3ac93e --- /dev/null +++ b/urbanLifelineWeb/packages/bidding/src/App.vue @@ -0,0 +1,21 @@ + + + + + diff --git a/urbanLifelineWeb/packages/bidding/src/layouts/SidebarLayout/SidebarLayout.scss b/urbanLifelineWeb/packages/bidding/src/layouts/SidebarLayout/SidebarLayout.scss new file mode 100644 index 00000000..c089e29c --- /dev/null +++ b/urbanLifelineWeb/packages/bidding/src/layouts/SidebarLayout/SidebarLayout.scss @@ -0,0 +1,191 @@ +// ==================== 品牌色变量 ==================== +$brand-color: #0055AA; +$brand-color-light: #EBF5FF; +$brand-color-hover: #004488; + +.sidebar-layout { + display: flex; + width: 100%; + height: 100vh; + overflow: hidden; + background: #fff; + font-family: 'Inter', 'Noto Sans SC', sans-serif; +} + +// ==================== 侧边栏 ==================== +.sidebar { + width: 256px; + height: 100%; + background: #fff; + display: flex; + flex-direction: column; + color: #333; + flex-shrink: 0; + transition: width 0.3s ease; + border-right: 1px solid #f1f5f9; + z-index: 50; + + &.collapsed { + width: 80px; + overflow: visible; + + .sidebar-header { + padding: 16px 0; + justify-content: center; + } + + .nav-item { + justify-content: center; + padding: 12px; + border-radius: 8px; + margin: 0 12px; + + span { + display: none; + } + } + + .user-section { + justify-content: center; + padding: 16px; + + .user-name { + display: none; + } + } + } +} + +.sidebar-header { + height: 64px; + padding: 0 16px; + margin-bottom: 8px; + display: flex; + align-items: center; + justify-content: space-between; + user-select: none; +} + +.collapse-btn { + width: 32px; + height: 32px; + display: flex; + align-items: center; + justify-content: center; + border-radius: 8px; + cursor: pointer; + color: #94a3b8; + background: transparent; + border: none; + transition: all 0.2s; + flex-shrink: 0; + + &:hover { + background: #f1f5f9; + color: #64748b; + } +} + +.logo { + display: flex; + align-items: center; + gap: 8px; + + .logo-img { + height: 32px; + width: auto; + border-radius: 8px; + object-fit: contain; + } + + .logo-text { + font-size: 16px; + font-weight: 600; + color: #1e293b; + letter-spacing: -0.02em; + } +} + +// 导航菜单 +.nav-menu { + flex: 1; + padding: 8px 12px; +} + +.nav-section { + padding: 0; +} + +.nav-item { + position: relative; + display: flex; + align-items: center; + gap: 12px; + padding: 12px 16px; + margin-bottom: 2px; + border-radius: 8px; + cursor: pointer; + transition: all 0.2s ease; + color: #64748b; + font-size: 14px; + font-weight: 500; + + &:hover { + background: $brand-color-light; + color: $brand-color; + } + + &.active { + background: $brand-color; + color: #fff; + box-shadow: 0 4px 12px rgba($brand-color, 0.25); + } + + span { + white-space: nowrap; + overflow: hidden; + text-overflow: ellipsis; + } +} + +// 用户信息 +.user-section { + padding: 16px; + border-top: 1px solid #f1f5f9; + background: #f8fafc; + cursor: pointer; + transition: background 0.2s; + + &:hover { + background: #f1f5f9; + } + + .user-info-wrapper { + display: flex; + align-items: center; + gap: 12px; + } + + .user-avatar { + position: relative; + flex-shrink: 0; + } + + .user-name { + font-size: 14px; + font-weight: 500; + color: #374151; + white-space: nowrap; + overflow: hidden; + text-overflow: ellipsis; + } +} + +// ==================== 主内容区 ==================== +.main-content { + flex: 1; + height: 100%; + overflow: hidden; + background: #f8fafc; + position: relative; +} diff --git a/urbanLifelineWeb/packages/bidding/src/layouts/SidebarLayout/index.ts b/urbanLifelineWeb/packages/bidding/src/layouts/SidebarLayout/index.ts deleted file mode 100644 index 972caa46..00000000 --- a/urbanLifelineWeb/packages/bidding/src/layouts/SidebarLayout/index.ts +++ /dev/null @@ -1 +0,0 @@ -export { default as SidebarLayout } from './SidebarLayout.vue' diff --git a/urbanLifelineWeb/packages/bidding/src/layouts/index.ts b/urbanLifelineWeb/packages/bidding/src/layouts/index.ts index cbbe43a3..8f619aeb 100644 --- a/urbanLifelineWeb/packages/bidding/src/layouts/index.ts +++ b/urbanLifelineWeb/packages/bidding/src/layouts/index.ts @@ -1,3 +1,2 @@ export { default as SidebarLayout } from './SidebarLayout/SidebarLayout.vue' -// BlankLayout、SubSidebarLayout 从 shared 导入 -export { BlankLayout, SubSidebarLayout } from 'shared/layouts' +export { BlankLayout, SubSidebarLayout } from 'shared/layouts'; \ No newline at end of file diff --git a/urbanLifelineWeb/packages/bidding/src/main.ts b/urbanLifelineWeb/packages/bidding/src/main.ts new file mode 100644 index 00000000..8377e148 --- /dev/null +++ b/urbanLifelineWeb/packages/bidding/src/main.ts @@ -0,0 +1,79 @@ +import { createApp } from 'vue' +import { createPinia } from 'pinia' +import ElementPlus from 'element-plus' +import 'element-plus/dist/index.css' + +import App from './App.vue' +import router from './router/' +import { AES_SECRET_KEY } from './config' + +// 导入需要的 Lucide 图标 +import { + LayoutGrid, + FileText, + Users, + User, + Settings, + Home, + ChevronDown, + ChevronRight, + ChevronLeft, + PanelLeftClose, + PanelLeftOpen, + RefreshCw, + LogOut, + Plus, + Trash2, + Search, + Menu +} from 'lucide-vue-next' + +// Lucide 图标映射 +const lucideIcons = { + LayoutGrid, + FileText, + Users, + User, + Settings, + Home, + ChevronDown, + ChevronRight, + ChevronLeft, + PanelLeftClose, + PanelLeftOpen, + RefreshCw, + LogOut, + Plus, + Trash2, + Search, + Menu +} + +// 异步初始化应用 +async function initApp() { + // 创建 Vue 应用 + const app = createApp(App) + + // 注册 Pinia + const pinia = createPinia() + app.use(pinia) + + // 注册 Element Plus + app.use(ElementPlus) + + // 注册 Lucide 图标 + for (const [name, component] of Object.entries(lucideIcons)) { + app.component(name, component) + } + + // 注册路由 + app.use(router) + + // 挂载应用 + app.mount('#app') + + console.log('✅ Bidding 应用启动成功') +} + +// 启动应用 +initApp() diff --git a/urbanLifelineWeb/packages/bidding/vite.config.ts b/urbanLifelineWeb/packages/bidding/vite.config.ts index 0f8e97b3..5f8c2dbb 100644 --- a/urbanLifelineWeb/packages/bidding/vite.config.ts +++ b/urbanLifelineWeb/packages/bidding/vite.config.ts @@ -88,6 +88,7 @@ export default defineConfig(({ mode }) => { }, build: { + target: 'esnext', outDir: 'dist', sourcemap: true, rollupOptions: { diff --git a/urbanLifelineWeb/packages/platform/src/views/public/Chat/components/ChatHistory/ChatHistory.vue b/urbanLifelineWeb/packages/platform/src/views/public/Chat/components/ChatHistory/ChatHistory.vue index e69de29b..2b0f0a77 100644 --- a/urbanLifelineWeb/packages/platform/src/views/public/Chat/components/ChatHistory/ChatHistory.vue +++ b/urbanLifelineWeb/packages/platform/src/views/public/Chat/components/ChatHistory/ChatHistory.vue @@ -0,0 +1,10 @@ + + + \ No newline at end of file diff --git a/urbanLifelineWeb/packages/platform/vite.config.ts b/urbanLifelineWeb/packages/platform/vite.config.ts index 6f8a00bc..82b62c2a 100644 --- a/urbanLifelineWeb/packages/platform/vite.config.ts +++ b/urbanLifelineWeb/packages/platform/vite.config.ts @@ -88,6 +88,7 @@ export default defineConfig(({ mode }) => { }, build: { + target: 'esnext', outDir: 'dist', sourcemap: true, rollupOptions: { diff --git a/urbanLifelineWeb/packages/shared/pnpm-lock.yaml b/urbanLifelineWeb/packages/shared/pnpm-lock.yaml index 20c4b1cd..0b4a5cbc 100644 --- a/urbanLifelineWeb/packages/shared/pnpm-lock.yaml +++ b/urbanLifelineWeb/packages/shared/pnpm-lock.yaml @@ -11,6 +11,9 @@ dependencies: '@stomp/stompjs': specifier: ^7.2.1 version: 7.2.1 + axios: + specifier: ^1.7.0 + version: 1.13.2 cors: specifier: ^2.8.5 version: 2.8.5 @@ -1253,6 +1256,10 @@ packages: resolution: {integrity: sha512-7HhHjtERjqlNbZtqNqy2rckN/SpOOlmDliet+lP7k+eKZEjPk3DgyeU9lIXLdeLz0uBbbVp+9Qdow9wJWgwwfg==} dev: false + /asynckit@0.4.0: + resolution: {integrity: sha512-Oei9OH4tRh0YqU3GxhX79dM/mwVgvbZJaSNaRk+bshkj0S5cfHcgYakreBjrHwatXKbz+IoIdYLxrKim2MjW0Q==} + dev: false + /available-typed-arrays@1.0.7: resolution: {integrity: sha512-wvUjBtSGN7+7SjNpq/9M2Tg350UZD3q62IFZLbRAR1bSMlCo1ZaeW+BJ+D090e4hIIZLBcTDWe4Mh4jvUDajzQ==} engines: {node: '>= 0.4'} @@ -1260,6 +1267,16 @@ packages: possible-typed-array-names: 1.1.0 dev: true + /axios@1.13.2: + resolution: {integrity: sha512-VPk9ebNqPcy5lRGuSlKx752IlDatOjT9paPlm8A7yOuW2Fbvp4X3JznJtT4f0GzGLLiWE9W8onz51SqLYwzGaA==} + dependencies: + follow-redirects: 1.15.11 + form-data: 4.0.5 + proxy-from-env: 1.1.0 + transitivePeerDependencies: + - debug + dev: false + /balanced-match@1.0.2: resolution: {integrity: sha512-3oSeUO0TMV67hN1AmbXsK4yaqU7tjiHlbxRDZOpH0KW9+CeX4bRAaX0Anxt0tx2MrpRpWwQaPwIlISEJhYU5Pw==} dev: true @@ -1384,6 +1401,13 @@ packages: resolution: {integrity: sha512-twmVoizEW7ylZSN32OgKdXRmo1qg+wT5/6C3xu5b9QsWzSFAhHLn2xd8ro0diCsKfCj1RdaTP/nrcW+vAoQPIw==} dev: true + /combined-stream@1.0.8: + resolution: {integrity: sha512-FQN4MRfuJeHf7cBbBMJFXhKSDq+2kAArBlmRBvcvFE5BB1HZKXtSFASDhdlz9zOYwxh8lDdnvmMOe/+5cdoEdg==} + engines: {node: '>= 0.8'} + dependencies: + delayed-stream: 1.0.0 + dev: false + /concat-map@0.0.1: resolution: {integrity: sha512-/Srv4dswyQNBfohGpz9o6Yb3Gz3SrUDqBH5rTuhGR7ahtlbYKnVxw2bCFMRljaA7EXHaXZ8wsHdodFvbkhKmqg==} dev: true @@ -1522,6 +1546,11 @@ packages: resolution: {integrity: sha512-mEQCMmwJu317oSz8CwdIOdwf3xMif1ttiM8LTufzc3g6kR+9Pe236twL8j3IYT1F7GfRgGcW6MWxzZjLIkuHIg==} dev: true + /delayed-stream@1.0.0: + resolution: {integrity: sha512-ZySD7Nf91aLB0RxL4KGrKHBXl7Eds1DAmEdcoVawXnLD7SDhpNgtuII2aAkg7a7QS41jxPSZ17p4VdGnMHk3MQ==} + engines: {node: '>=0.4.0'} + dev: false + /depd@2.0.0: resolution: {integrity: sha512-g7nH6P6dyDioJogAAGprGpCtVImJhpPk/roCzdb3fIh61/s/nPsfR6onyMwkCAR/OlC3yBC0lESvUoQEAssIrw==} engines: {node: '>= 0.8'} @@ -1686,7 +1715,6 @@ packages: get-intrinsic: 1.3.0 has-tostringtag: 1.0.2 hasown: 2.0.2 - dev: true /es-to-primitive@1.3.0: resolution: {integrity: sha512-w+5mJ3GuFL+NjVtJlvydShqE1eN3h3PbI7/5LAsYJP/2qtuMXjfL2LpHSRqo4b4eSF5K/DH1JXKUAHSB2UW50g==} @@ -1840,6 +1868,16 @@ packages: - supports-color dev: false + /follow-redirects@1.15.11: + resolution: {integrity: sha512-deG2P0JfjrTxl50XGCDyfI97ZGVCxIpfKYmfyrQ54n5FO/0gfIES8C/Psl6kWVDolizcaaxZJnTS0QSMxvnsBQ==} + engines: {node: '>=4.0'} + peerDependencies: + debug: '*' + peerDependenciesMeta: + debug: + optional: true + dev: false + /for-each@0.3.5: resolution: {integrity: sha512-dKx12eRCVIzqCxFGplyFKJMPvLEWgmNtUrpTiJIR5u97zEhRG8ySrtboPHZXx7daLxQVrl643cTzbab2tkQjxg==} engines: {node: '>= 0.4'} @@ -1847,6 +1885,17 @@ packages: is-callable: 1.2.7 dev: true + /form-data@4.0.5: + resolution: {integrity: sha512-8RipRLol37bNs2bhoV67fiTEvdTrbMUYcFTiy3+wuuOnUog2QBHCZWXDRijWQfAkhBj2Uf5UnVaiWwA5vdd82w==} + engines: {node: '>= 6'} + dependencies: + asynckit: 0.4.0 + combined-stream: 1.0.8 + es-set-tostringtag: 2.1.0 + hasown: 2.0.2 + mime-types: 2.1.35 + dev: false + /forwarded@0.2.0: resolution: {integrity: sha512-buRG0fpBtRHSTCOASe6hD258tEubFoRLb4ZNA6NxMVHNw2gOcwHo9wyablzMzOA5z9xA9L1KNjk/Nt6MT9aYow==} engines: {node: '>= 0.6'} @@ -1978,7 +2027,6 @@ packages: engines: {node: '>= 0.4'} dependencies: has-symbols: 1.1.0 - dev: true /hasown@2.0.2: resolution: {integrity: sha512-0hJU9SCPvmMzIBdZFqNPXWa6dqh7WdH0cII9y+CyS8rG3nL48Bclra9HmKhVVUHyPWNH5Y7xDwAB7bfgSjkUMQ==} @@ -2574,6 +2622,10 @@ packages: ipaddr.js: 1.9.1 dev: false + /proxy-from-env@1.1.0: + resolution: {integrity: sha512-D+zkORCbA9f1tdWRK0RaCR3GPv50cMxcrz4X8k5LTSUD1Dkw47mKJEZQNunItRTkWwgtaUSo1RVFRIG9ZXiFYg==} + dev: false + /qs@6.14.0: resolution: {integrity: sha512-YWWTjgABSKcvs/nWBi9PycY/JiPJqOD4JA6o9Sej2AtvSGarXxKC3OQSk4pAarbdQlKAh5D4FCQkJNkW+GAn3w==} engines: {node: '>=0.6'} diff --git a/urbanLifelineWeb/packages/workcase/.__mf__temp/workcase/localSharedImportMap.js b/urbanLifelineWeb/packages/workcase/.__mf__temp/workcase/localSharedImportMap.js index adb405c6..595be568 100644 --- a/urbanLifelineWeb/packages/workcase/.__mf__temp/workcase/localSharedImportMap.js +++ b/urbanLifelineWeb/packages/workcase/.__mf__temp/workcase/localSharedImportMap.js @@ -118,7 +118,7 @@ entryGlobalName: "shared", name: "shared", type: "module", - entry: "https://org.xyzh.yslg/shared/remoteEntry.js", + entry: "/shared/mf-manifest.json", shareScope: "default", } diff --git a/urbanLifelineWeb/packages/workcase/src/views/admin/overview/OverviewView.vue b/urbanLifelineWeb/packages/workcase/src/views/admin/overview/OverviewView.vue index b2841ab3..fe4aaced 100644 --- a/urbanLifelineWeb/packages/workcase/src/views/admin/overview/OverviewView.vue +++ b/urbanLifelineWeb/packages/workcase/src/views/admin/overview/OverviewView.vue @@ -209,13 +209,13 @@ const loadDashboardData = async () => { const timeRanges = getYesterdayRange() const yesterdayResult = await workcaseChatAPI.countChatRooms({ - startTime: timeRanges.yesterday.start, - endTime: timeRanges.yesterday.end + startTime: timeRanges.yesterday.start.toISOString(), + endTime: timeRanges.yesterday.end.toISOString() } as TbChatRoomDTO) const dayBeforeResult = await workcaseChatAPI.countChatRooms({ - startTime: timeRanges.dayBeforeYesterday.start, - endTime: timeRanges.dayBeforeYesterday.end + startTime: timeRanges.dayBeforeYesterday.start.toISOString(), + endTime: timeRanges.dayBeforeYesterday.end.toISOString() } as TbChatRoomDTO) if (yesterdayResult.success && dayBeforeResult.success) { @@ -261,18 +261,18 @@ const loadQuestionStats = async () => { const { startTime, endTime } = getTimeRange(questionStatPeriod.value) const result = await workcaseAPI.countWorkcasesByType({ - startTime, - endTime + startTime: startTime.toISOString(), + endTime: endTime.toISOString() } as TbWorkcaseDTO) if (result.success && result.data) { const data = Array.isArray(result.data) ? result.data : [result.data] // 计算总数 - const total = data.reduce((sum, item) => sum + (item.count || 0), 0) + const total = data.reduce((sum: number, item: any) => sum + (item.count || 0), 0) // 转换数据格式并计算百分比 - questionCategories.value = data.map((item, index) => ({ + questionCategories.value = data.map((item: any, index: number) => ({ name: item.type || '未分类', count: Number(item.count || 0), percent: total > 0 ? Math.round((Number(item.count || 0) / total) * 100) : 0, @@ -296,10 +296,10 @@ const loadWordCloud = async () => { const data = Array.isArray(result.data) ? result.data : [result.data] // 找出最大词频用于归一化 - const maxFreq = Math.max(...data.map(item => Number(item.frequency || 0))) + const maxFreq = Math.max(...data.map((item: any) => Number(item.frequency || 0))) // 转换数据格式 - productCloudData.value = data.map((item, index) => { + productCloudData.value = data.map((item: any, index: number) => { const freq = Number(item.frequency || 0) const weight = maxFreq > 0 ? freq / maxFreq : 0 diff --git a/urbanLifelineWeb/packages/workcase/vite.config.ts b/urbanLifelineWeb/packages/workcase/vite.config.ts index d246badb..71d8cbe4 100644 --- a/urbanLifelineWeb/packages/workcase/vite.config.ts +++ b/urbanLifelineWeb/packages/workcase/vite.config.ts @@ -90,6 +90,7 @@ export default defineConfig(({ mode }) => { }, build: { + target: 'esnext', outDir: 'dist', sourcemap: true, rollupOptions: {