From a6b7b343a9f06b8e9988329957a40f45116edc1b Mon Sep 17 00:00:00 2001 From: wxy <714453439@qq.com> Date: Mon, 21 Jul 2025 10:50:02 +0800 Subject: [PATCH] =?UTF-8?q?=E4=BE=A7=E8=BE=B9=E6=A0=8F=E7=BB=93=E6=9E=84?= =?UTF-8?q?=E4=BF=AE=E6=94=B9?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- src/apis/health-record/index.ts | 26 +- src/apis/index.ts | 3 - src/apis/system/user-new.ts | 2 +- src/router/route.ts | 730 ++++++++++-------- .../application-data/index.vue | 236 +++--- .../function-usage/index.vue | 230 +++--- .../member-data/index.vue | 264 +++---- .../enterprise-dashboard/overview/index.vue | 244 +++--- 8 files changed, 911 insertions(+), 824 deletions(-) diff --git a/src/apis/health-record/index.ts b/src/apis/health-record/index.ts index 2326336..23284c2 100644 --- a/src/apis/health-record/index.ts +++ b/src/apis/health-record/index.ts @@ -40,7 +40,7 @@ export function createHealthRecord(data: HealthRecord) { return request({ url: '/health-record', method: 'post', - data, + data }) } @@ -49,7 +49,7 @@ export function getHealthRecordList(params: HealthRecordListParams) { return request({ url: '/health-record/list', method: 'get', - params, + params }) } @@ -57,7 +57,7 @@ export function getHealthRecordList(params: HealthRecordListParams) { export function getHealthRecordDetail(id: string) { return request({ url: `/health-record/detail/${id}`, - method: 'get', + method: 'get' }) } @@ -66,7 +66,7 @@ export function updateHealthRecord(id: string, data: HealthRecord) { return request({ url: `/health-record/${id}`, method: 'put', - data, + data }) } @@ -74,7 +74,7 @@ export function updateHealthRecord(id: string, data: HealthRecord) { export function deleteHealthRecord(id: string) { return request({ url: `/health-record/${id}`, - method: 'delete', + method: 'delete' }) } @@ -83,14 +83,14 @@ export function uploadHealthReport(file: File, recordId: string) { const formData = new FormData() formData.append('file', file) formData.append('recordId', recordId) - + return request({ url: '/health-record/upload-report', method: 'post', data: formData, headers: { - 'Content-Type': 'multipart/form-data', - }, + 'Content-Type': 'multipart/form-data' + } }) } @@ -99,7 +99,7 @@ export function downloadHealthReport(fileId: string) { return request({ url: `/health-record/download-report/${fileId}`, method: 'get', - responseType: 'blob', + responseType: 'blob' }) } @@ -107,7 +107,7 @@ export function downloadHealthReport(fileId: string) { export function getEmployeeHealthHistory(employeeId: string) { return request({ url: `/health-record/employee/${employeeId}`, - method: 'get', + method: 'get' }) } @@ -117,7 +117,7 @@ export function exportHealthRecords(params: HealthRecordListParams) { url: '/health-record/export', method: 'get', params, - responseType: 'blob', + responseType: 'blob' }) } @@ -131,6 +131,6 @@ export function scheduleHealthCheck(data: { return request({ url: '/health-record/schedule', method: 'post', - data, + data }) -} +} \ No newline at end of file diff --git a/src/apis/index.ts b/src/apis/index.ts index dad12f7..182c8cd 100644 --- a/src/apis/index.ts +++ b/src/apis/index.ts @@ -9,7 +9,6 @@ export * from './project' export * from './project/task' export * from './attach-info' export * from './model-config' -export * from './performance' // 保险相关模块 export * as InsuranceAPI from './insurance' export * as InsuranceCompanyAPI from './insurance-company' @@ -28,5 +27,3 @@ export * from './schedule/type' export * from './project/type' export * from './attach-info/type' export * from './model-config/type' -export * from './performance/type' -export * from './salary' diff --git a/src/apis/system/user-new.ts b/src/apis/system/user-new.ts index 1b4d4b5..f331dde 100644 --- a/src/apis/system/user-new.ts +++ b/src/apis/system/user-new.ts @@ -36,4 +36,4 @@ export function updateUserNew(userId: string, data: T.UserNewUpdateReq) { /** @desc 删除用户信息 */ export function deleteUserNew(userId: string) { return http.del(`${BASE_URL}/${userId}`) -} +} \ No newline at end of file diff --git a/src/router/route.ts b/src/router/route.ts index b35f0f8..8aed44a 100644 --- a/src/router/route.ts +++ b/src/router/route.ts @@ -67,7 +67,7 @@ export const systemRoutes: RouteRecordRaw[] = [ { path: '/organization/hr/performance', name: 'HRPerformance', - component: () => import('@/views/performance/index.vue'), + component: () => import('@/views/hr/performance/index.vue'), meta: { title: '绩效', icon: 'performance', hidden: false }, }, { @@ -83,7 +83,7 @@ export const systemRoutes: RouteRecordRaw[] = [ component: () => import('@/views/hr/salary/index.vue'), meta: { title: '工资概览', icon: 'salary', hidden: false }, }, - ], + ] }, // { // path: '/organization/hr/salary/insurance', @@ -166,8 +166,8 @@ export const systemRoutes: RouteRecordRaw[] = [ name: 'HRSystemTypeManagement', component: () => import('@/views/hr/salary/system-insurance/type-management/index.vue'), meta: { title: '保险类型管理', icon: 'category', hidden: false }, - }, - ], + } + ] }, { path: '/organization/hr/salary/certification', @@ -180,54 +180,15 @@ export const systemRoutes: RouteRecordRaw[] = [ name: 'HRContribution', component: () => import('@/views/hr/contribution/index.vue'), meta: { title: '责献积分制度', icon: 'contribution', hidden: false }, - }, - ], + } + ] }, { path: '/organization/role', name: 'OrganizationRole', component: () => import('@/views/system/role/index.vue'), meta: { title: '角色管理', icon: 'role', hidden: false }, - }, - ], - }, - { - path: '/performance', - name: 'Performance', - component: Layout, - redirect: '/performance/dimension', - meta: { title: '绩效管理', icon: 'chart', hidden: false, sort: 3 }, - children: [ - { - path: '/performance/dimension', - name: 'PerformanceDimension', - component: () => import('@/views/performance/dimension.vue'), - meta: { title: '绩效维度管理', icon: 'dashboard', hidden: false }, - }, - { - path: '/performance/rule', - name: 'PerformanceRule', - component: () => import('@/views/performance/rule.vue'), - meta: { title: '细则管理', icon: 'setting', hidden: false }, - }, - { - path: '/performance/evaluate', - name: 'PerformanceEvaluate', - component: () => import('@/views/performance/evaluate.vue'), - meta: { title: '员工评估', icon: 'user', hidden: false }, - }, - { - path: '/performance/my', - name: 'PerformanceMy', - component: () => import('@/views/performance/my.vue'), - meta: { title: '我的绩效', icon: 'user', hidden: false }, - }, - { - path: '/salary-management', - name: 'SalaryManagement', - component: () => import('@/views/salary-management/index.vue'), - meta: { title: '工资管理', hidden: false }, - }, + } ], }, { @@ -237,12 +198,64 @@ export const systemRoutes: RouteRecordRaw[] = [ redirect: '/asset-management/device/inventory', meta: { title: '资产管理', icon: 'property-safety', hidden: false, sort: 3 }, children: [ + { + path: '/asset-management/intellectual-property1', + name: 'IntellectualProperty1', + component: () => import('@/views/system-resource/information-system/software-management/index.vue'), + meta: { title: '设备管理', icon: 'copyright', hidden: false }, + children:[ + { + path: '/asset-management/intellectual-property1', + name: 'IntellectualProperty11', + component: () => import('@/views/system-resource/information-system/software-management/index.vue'), + meta: { title: '库存管理', hidden: false }, + }, + { + path: '/asset-management/intellectual-property1', + name: 'IntellectualProperty12', + component: () => import('@/views/system-resource/information-system/software-management/index.vue'), + meta: { title: '设备采购', hidden: false }, + }, + { + path: '/asset-management/intellectual-property1', + name: 'IntellectualProperty13', + component: () => import('@/views/system-resource/information-system/software-management/index.vue'), + meta: { title: '在线管理', hidden: false }, + children:[ + { + path: '/asset-management/intellectual-property11', + name: 'IntellectualProperty14', + component: () => import('@/views/system-resource/information-system/software-management/index.vue'), + meta: { title: '无人机', hidden: false }, + }, + { + path: '/asset-management/intellectual-property12', + name: 'IntellectualProperty15', + component: () => import('@/views/system-resource/information-system/software-management/index.vue'), + meta: { title: '机巢', hidden: false }, + }, + { + path: '/asset-management/intellectual-property13', + name: 'IntellectualProperty16', + component: () => import('@/views/system-resource/information-system/software-management/index.vue'), + meta: { title: '其他智能终端', hidden: false }, + }, + { + path: '/asset-management/intellectual-property14', + name: 'IntellectualProperty17', + component: () => import('@/views/system-resource/information-system/software-management/index.vue'), + meta: { title: '车辆管理', hidden: false }, + } + ] + } + ] + }, { path: '/asset-management/intellectual-property', name: 'IntellectualProperty', component: () => import('@/views/system-resource/information-system/software-management/index.vue'), meta: { title: '其他资产', icon: 'copyright', hidden: false }, - }, + } ], }, { @@ -289,8 +302,8 @@ export const systemRoutes: RouteRecordRaw[] = [ name: 'BladeRobot', component: () => import('@/views/service/lightning-detection/index.vue'), meta: { title: '叶片维修机器人', icon: 'robot', hidden: false }, - }, - ], + } + ] }, { path: '/products-services/products/software', @@ -316,10 +329,10 @@ export const systemRoutes: RouteRecordRaw[] = [ name: 'GroundStation', component: () => import('@/views/service/lightning-detection/index.vue'), meta: { title: '无人机地面站软件', icon: 'station', hidden: false }, - }, - ], - }, - ], + } + ] + } + ] }, { path: '/products-services/services', @@ -381,9 +394,9 @@ export const systemRoutes: RouteRecordRaw[] = [ name: 'BladeMaintenance', component: () => import('@/views/service/lightning-detection/index.vue'), meta: { title: '叶片维修', icon: 'maintenance', hidden: false }, - }, - ], - }, + } + ] + } ], }, { @@ -393,6 +406,100 @@ export const systemRoutes: RouteRecordRaw[] = [ redirect: '/project-management/project-template/tender-documents', meta: { title: '项目管理', icon: 'apps', hidden: false, sort: 4 }, children: [ + { + path: '/project-management/contract', + name: 'ProjectContract', + component: () => import('@/components/ParentView/index.vue'), + redirect: '/project-management/contract/revenue-contract', + meta: { + title: '市场商务管理', + icon: 'file-text', + hidden: false + }, + children: [ + { + path: '/project-management/contract/revenue-contract', + name: 'RevenueContract', + component: () => import('@/views/project-management/contract/revenue-contract/index.vue'), + meta: { + title: '项目来源', + icon: 'dollar', + hidden: false + }, + children:[ + { + path: '/project-management/contract/revenue-contract1', + name: 'RevenueContract1', + meta: { + title: '招采业务', + icon: 'dollar', + hidden: false + } + }, + { + path: '/project-management/contract/revenue-contract2', + name: 'RevenueContract2', + meta: { + title: '市场营销', + icon: 'dollar', + hidden: false + } + }, + { + path: '/project-management/contract/revenue-contract3', + name: 'RevenueContract3', + meta: { + title: '自建项目', + icon: 'dollar', + hidden: false + } + }, + ] + }, + { + path: '/project-management/contract/revenue-contract', + name: 'RevenueContract', + component: () => import('@/views/project-management/contract/revenue-contract/index.vue'), + meta: { + title: '项目合同管理', + icon: 'dollar', + hidden: false + }, + children:[ + { + path: '/project-management/contract/revenue-contract', + name: 'RevenueContract', + component: () => import('@/views/project-management/contract/revenue-contract/index.vue'), + meta: { + title: '收入合同', + icon: 'dollar', + hidden: false + } + }, + { + path: '/project-management/contract/expense-contract', + name: 'ExpenseContract', + component: () => import('@/views/project-management/contract/expense-contract/index.vue'), + meta: { + title: '支出合同', + icon: 'credit-card', + hidden: false + } + }, + { + path: '/project-management/contract/cost-management', + name: 'CostManagement', + component: () => import('@/views/project-management/contract/cost-management/index.vue'), + meta: { + title: '成本费用', + icon: 'bar-chart', + hidden: false + } + } + ] + } + ] + }, { path: '/project-management/project-template', name: 'ProjectTemplate', @@ -401,7 +508,7 @@ export const systemRoutes: RouteRecordRaw[] = [ meta: { title: '施工立项', icon: 'file-protect', - hidden: false, + hidden: false }, children: [ { @@ -411,8 +518,8 @@ export const systemRoutes: RouteRecordRaw[] = [ meta: { title: '招标文件', icon: 'file-text', - hidden: false, - }, + hidden: false + } }, { path: '/project-management/project-template/bid-documents', @@ -421,8 +528,8 @@ export const systemRoutes: RouteRecordRaw[] = [ meta: { title: '投标文件', icon: 'file-text', - hidden: false, - }, + hidden: false + } }, { path: '/project-management/project-template/award-notice', @@ -431,8 +538,8 @@ export const systemRoutes: RouteRecordRaw[] = [ meta: { title: '中标通知书', icon: 'trophy', - hidden: false, - }, + hidden: false + } }, { path: '/project-management/projects/initiation', @@ -441,53 +548,10 @@ export const systemRoutes: RouteRecordRaw[] = [ meta: { title: '立项管理', icon: 'plus-circle', - hidden: false, - }, + hidden: false + } }, - ], - }, - { - path: '/project-management/contract', - name: 'ProjectContract', - component: () => import('@/components/ParentView/index.vue'), - redirect: '/project-management/contract/revenue-contract', - meta: { - title: '市场商务管理', - icon: 'file-text', - hidden: false, - }, - children: [ - { - path: '/project-management/contract/revenue-contract', - name: 'RevenueContract', - component: () => import('@/views/project-management/contract/revenue-contract/index.vue'), - meta: { - title: '收入合同', - icon: 'dollar', - hidden: false, - }, - }, - { - path: '/project-management/contract/expense-contract', - name: 'ExpenseContract', - component: () => import('@/views/project-management/contract/expense-contract/index.vue'), - meta: { - title: '支出合同', - icon: 'credit-card', - hidden: false, - }, - }, - { - path: '/project-management/contract/cost-management', - name: 'CostManagement', - component: () => import('@/views/project-management/contract/cost-management/index.vue'), - meta: { - title: '成本费用', - icon: 'bar-chart', - hidden: false, - }, - }, - ], + ] }, { path: '/project-management/projects', @@ -497,7 +561,7 @@ export const systemRoutes: RouteRecordRaw[] = [ meta: { title: '组织实施管理', icon: 'briefcase', - hidden: false, + hidden: false }, children: [ @@ -508,8 +572,8 @@ export const systemRoutes: RouteRecordRaw[] = [ meta: { title: '进度管理', icon: 'schedule', - hidden: false, - }, + hidden: false + } }, { path: '/project-management/projects/budget', @@ -518,8 +582,8 @@ export const systemRoutes: RouteRecordRaw[] = [ meta: { title: '预算管理', icon: 'fund', - hidden: false, - }, + hidden: false + } }, { path: '/project-management/projects/personnel-distribution', @@ -528,8 +592,8 @@ export const systemRoutes: RouteRecordRaw[] = [ meta: { title: '人员分布图', icon: 'team', - hidden: false, - }, + hidden: false + } }, { path: '/project-management/projects/device', @@ -538,8 +602,8 @@ export const systemRoutes: RouteRecordRaw[] = [ meta: { title: '设备管理', icon: 'plus-circle', - hidden: false, - }, + hidden: false + } }, { path: '/project-management/projects/safety', @@ -548,8 +612,8 @@ export const systemRoutes: RouteRecordRaw[] = [ meta: { title: '安全管理', icon: 'safety', - hidden: false, - }, + hidden: false + } }, { path: '/project-management/projects/quality', @@ -558,11 +622,11 @@ export const systemRoutes: RouteRecordRaw[] = [ meta: { title: '质量管理', icon: 'audit', - hidden: false, - }, - }, - ], - }, + hidden: false + } + } + ] + } ], }, { @@ -572,19 +636,19 @@ export const systemRoutes: RouteRecordRaw[] = [ redirect: '/construction-operation-platform/implementation-workflow/field-construction', meta: { title: '施工操作台', icon: 'tool', hidden: false, sort: 5 }, children: [ - { - path: '/construction-operation-platform/implementation-workflow', - name: 'ImplementationWorkflow', - component: () => import('@/components/ParentView/index.vue'), - redirect: '/construction-operation-platform/implementation-workflow/field-construction', - meta: { title: '项目实施工作流程', icon: 'fork', hidden: false }, - children: [ + // { + // path: '/construction-operation-platform/implementation-workflow', + // name: 'ImplementationWorkflow', + // component: () => import('@/components/ParentView/index.vue'), + // redirect: '/construction-operation-platform/implementation-workflow/field-construction', + // meta: { title: '项目实施工作流程', icon: 'fork', hidden: false }, + // children: [ { path: '/construction-operation-platform/implementation-workflow/field-construction', name: 'FieldConstruction', component: () => import('@/components/ParentView/index.vue'), redirect: '/construction-operation-platform/implementation-workflow/field-construction/project-list', - meta: { title: '外业施工', icon: 'construction', hidden: false }, + meta: { title: '我的项目', icon: 'construction', hidden: false }, children: [ { path: '/project-management/projects/list', @@ -593,36 +657,49 @@ export const systemRoutes: RouteRecordRaw[] = [ meta: { title: '项目列表', icon: 'unordered-list', - hidden: false, - }, + hidden: false + } }, { path: '/construction-operation-platform/implementation-workflow/field-construction/technology', name: 'FieldConstructionTechnology', component: () => import('@/views/project-operation-platform/implementation-workflow/field-construction/project-list/index.vue'), - meta: { title: '现场工艺', icon: 'tool', hidden: false }, + meta: { title: '我的施工', icon: 'tool', hidden: false }, }, - ], - }, - { - path: '/construction-operation-platform/implementation-workflow/data-processing', - name: 'DataProcessing', - component: () => import('@/components/ParentView/index.vue'), - redirect: '/construction-operation-platform/implementation-workflow/data-processing/data-storage', - meta: { title: '数据处理', icon: 'filter', hidden: false }, - children: [ { - path: '/construction-operation-platform/implementation-workflow/data-processing/data-storage', - name: 'DataStorage', + path: '/construction-operation-platform/implementation-workflow/data-processing', + name: 'DataProcessing', component: () => import('@/components/ParentView/index.vue'), - redirect: '/construction-operation-platform/implementation-workflow/data-processing/data-storage/raw-data', - meta: { title: '数据入库', icon: 'database', hidden: false }, + redirect: '/construction-operation-platform/implementation-workflow/data-processing/data-storage', + meta: { title: '我的业务数据', icon: 'filter', hidden: false }, children: [ { - path: '/construction-operation-platform/implementation-workflow/data-processing/data-storage/raw-data', - name: 'RawData', - component: () => import('@/views/operation-platform/data-processing/data-storage/index.vue'), - meta: { title: '原数据管理', icon: 'file', hidden: false }, + path: '/construction-operation-platform/implementation-workflow/data-processing/data-storage', + name: 'DataStorage', + component: () => import('@/components/ParentView/index.vue'), + redirect: '/construction-operation-platform/implementation-workflow/data-processing/data-storage/raw-data', + meta: { title: '原数据管理', icon: 'database', hidden: false }, + children: [ + { + path: '/construction-operation-platform/implementation-workflow/data-processing/data-storage/raw-data', + name: 'RawData', + component: () => import('@/views/operation-platform/data-processing/data-storage/index.vue'), + meta: { title: '原数据管理', icon: 'file', hidden: false }, + }, + { + path: '/construction-operation-platform/implementation-workflow/data-processing/data-storage/attachment', + name: 'AttachmentManagement', + component: () => import('@/views/operation-platform/data-processing/data-storage/index.vue'), + meta: { title: '附件管理', icon: 'attachment', hidden: false }, + }, + { + path: '/construction-operation-platform/implementation-workflow/data-processing/data-storage/model-config', + name: 'ModelConfig', + component: () => import('@/views/construction-operation-platform/implementation-workflow/data-processing/model-config/index.vue'), + meta: { title: '模型配置', icon: 'robot', hidden: false }, + }, + + ] }, { path: '/construction-operation-platform/implementation-workflow/data-processing/data-storage/preprocessed-data', @@ -631,72 +708,98 @@ export const systemRoutes: RouteRecordRaw[] = [ meta: { title: '数据预处理', icon: 'filter', hidden: false }, }, { - path: '/construction-operation-platform/implementation-workflow/data-processing/data-storage/attachment', - name: 'AttachmentManagement', - component: () => import('@/views/operation-platform/data-processing/data-storage/index.vue'), - meta: { title: '附件管理', icon: 'attachment', hidden: false }, - }, - { - path: '/construction-operation-platform/implementation-workflow/data-processing/data-storage/model-config', - name: 'ModelConfig', - component: () => import('@/views/construction-operation-platform/implementation-workflow/data-processing/model-config/index.vue'), - meta: { title: '模型配置', icon: 'robot', hidden: false }, - }, - - ], + path: '/construction-operation-platform/implementation-workflow/data-processing/intelligent-inspection', + name: 'IntelligentInspection', + component: () => import('@/components/ParentView/index.vue'), + redirect: '/construction-operation-platform/implementation-workflow/data-processing/intelligent-inspection/defect-algorithm', + meta: { title: '数据分析与图像检测', icon: 'scan', hidden: false }, + children: [ + { + path: '/construction-operation-platform/implementation-workflow/data-processing/intelligent-inspection/tree-visualization', + name: 'TreeVisualization', + component: () => import('@/views/project-operation-platform/data-processing/key-info-extraction/index.vue'), + meta: { title: '可视化管理', icon: 'cluster', hidden: false }, + }, + { + path: '/construction-operation-platform/implementation-workflow/data-processing/intelligent-inspection/defect-algorithm', + name: 'DefectAlgorithm', + component: () => import('@/views/construction-operation-platform/implementation-workflow/data-processing/intelligent-inspection/defect-algorithm/index.vue'), + meta: { title: '缺陷检测', icon: 'code', hidden: false }, + }, + { + path: '/construction-operation-platform/implementation-workflow/data-processing/intelligent-inspection/report-generation', + name: 'ReportGeneration', + component: () => import('@/views/project-operation-platform/data-processing/report-generation/index.vue'), + meta: { title: '报告生成', icon: 'file-add', hidden: false }, + }, + { + path: '/construction-operation-platform/implementation-workflow/data-processing/intelligent-inspection/standard-info', + name: 'StandardInfo', + component: () => import('@/views/project-operation-platform/data-processing/standard-info/index.vue'), + meta: { title: '标准信息库', icon: 'book', hidden: false }, + }, + { + path: '/construction-operation-platform/implementation-workflow/data-processing/intelligent-inspection/report-review', + name: 'ReportReview', + component: () => import('@/views/project-operation-platform/data-processing/report-review/index.vue'), + meta: { title: '报告修改审核', icon: 'audit', hidden: false }, + }, + { + path: '/construction-operation-platform/implementation-workflow/data-processing/intelligent-inspection/lifecycle-management', + name: 'LifecycleManagement', + component: () => import('@/views/project-operation-platform/lifecycle-management/index.vue'), + meta: { title: '全生命周期管理', icon: 'reload', hidden: false }, + }, + { + path: '/construction-operation-platform/implementation-workflow/data-processing/intelligent-inspection/drone-services', + name: 'DroneServices', + component: () => import('@/views/project-operation-platform/route-planning/index.vue'), + meta: { title: '无人机云服务', icon: 'cloud-server', hidden: false }, + }, + { + path: '/construction-operation-platform/implementation-workflow/airport-management', + name: 'AirportManagement', + component: () => import('@/views/construction-operation-platform/airport-management/index.vue'), + meta: { title: '机场管理', icon: 'rocket', hidden: false }, + }, + ] + } + ] }, { - path: '/construction-operation-platform/implementation-workflow/data-processing/intelligent-inspection', - name: 'IntelligentInspection', + path: '/construction-operation-platform/implementation-workflow/project-delivery', + name: 'ProjectDelivery', component: () => import('@/components/ParentView/index.vue'), - redirect: '/construction-operation-platform/implementation-workflow/data-processing/intelligent-inspection/defect-algorithm', - meta: { title: '智能巡检平台', icon: 'scan', hidden: false }, + redirect: '/construction-operation-platform/implementation-workflow/project-delivery/delivery-overview', + meta: { title: '项目交付', icon: 'check-circle', hidden: false }, children: [ + // { + // path: '/construction-operation-platform/implementation-workflow/project-delivery/delivery-overview', + // name: 'DeliveryOverview', + // component: () => import('@/views/project-operation-platform/quality-management/process-verification/index.vue'), + // meta: { title: '交付概览', icon: 'dashboard', hidden: false }, + // }, { - path: '/construction-operation-platform/implementation-workflow/data-processing/intelligent-inspection/defect-algorithm', - name: 'DefectAlgorithm', - component: () => import('@/views/construction-operation-platform/implementation-workflow/data-processing/intelligent-inspection/defect-algorithm/index.vue'), - meta: { title: '缺陷检测算法', icon: 'code', hidden: false }, + path: '/construction-operation-platform/implementation-workflow/project-delivery/reliability-assessment', + name: 'ReliabilityAssessment', + component: () => import('@/views/project-operation-platform/quality-management/process-verification/index.vue'), + meta: { title: '可靠性评估', icon: 'safety-certificate', hidden: false }, }, { - path: '/construction-operation-platform/implementation-workflow/data-processing/intelligent-inspection/tree-visualization', - name: 'TreeVisualization', - component: () => import('@/views/project-operation-platform/data-processing/key-info-extraction/index.vue'), - meta: { title: '树状可视化管理', icon: 'cluster', hidden: false }, + path: '/construction-operation-platform/implementation-workflow/project-delivery/data-quality-assessment', + name: 'DataQualityAssessment', + component: () => import('@/views/project-operation-platform/data-processing/data-quality-assessment/index.vue'), + meta: { title: '数据质量评估', icon: 'audit', hidden: false }, }, { - path: '/construction-operation-platform/implementation-workflow/data-processing/intelligent-inspection/standard-info', - name: 'StandardInfo', - component: () => import('@/views/project-operation-platform/data-processing/standard-info/index.vue'), - meta: { title: '标准信息库', icon: 'book', hidden: false }, - }, - { - path: '/construction-operation-platform/implementation-workflow/data-processing/intelligent-inspection/report-generation', - name: 'ReportGeneration', - component: () => import('@/views/project-operation-platform/data-processing/report-generation/index.vue'), - meta: { title: '报告生成', icon: 'file-add', hidden: false }, - }, - { - path: '/construction-operation-platform/implementation-workflow/data-processing/intelligent-inspection/lifecycle-management', - name: 'LifecycleManagement', - component: () => import('@/views/project-operation-platform/lifecycle-management/index.vue'), - meta: { title: '全生命周期管理', icon: 'reload', hidden: false }, - }, - { - path: '/construction-operation-platform/implementation-workflow/data-processing/intelligent-inspection/drone-services', - name: 'DroneServices', - component: () => import('@/views/project-operation-platform/route-planning/index.vue'), - meta: { title: '无人机云服务', icon: 'cloud-server', hidden: false }, - }, - { - path: '/construction-operation-platform/implementation-workflow/data-processing/intelligent-inspection/report-review', - name: 'ReportReview', - component: () => import('@/views/project-operation-platform/data-processing/report-review/index.vue'), - meta: { title: '报告修改审核', icon: 'audit', hidden: false }, - }, - ], + path: '/construction-operation-platform/implementation-workflow/project-delivery/defect-storage', + name: 'DefectStorage', + component: () => import('@/views/project-operation-platform/quality-management/defect-storage/index.vue'), + meta: { title: '质量入库', icon: 'folder-add', hidden: false }, + } + ] }, - ], + ] }, { path: '/construction-operation-platform/implementation-workflow/tower-monitoring-video', @@ -722,33 +825,18 @@ export const systemRoutes: RouteRecordRaw[] = [ name: 'ImageDetection', component: () => import('@/views/project-operation-platform/data-processing/wide-angle-video/index.vue'), meta: { title: '图像检测', icon: 'picture', hidden: false }, - }, - ], - }, - { - path: '/construction-operation-platform/implementation-workflow/project-delivery', - name: 'ProjectDelivery', - component: () => import('@/views/project-operation-platform/quality-management/process-verification/index.vue'), - meta: { title: '项目交付', icon: 'check-circle', hidden: false }, - }, - { - path: '/construction-operation-platform/implementation-workflow/reliability-assessment', - name: 'ReliabilityAssessment', - component: () => import('@/views/project-operation-platform/quality-management/process-verification/index.vue'), - meta: { title: '可靠性评估', icon: 'safety-certificate', hidden: false }, - }, - { - path: '/construction-operation-platform/implementation-workflow/data-quality-assessment', - name: 'DataQualityAssessment', - component: () => import('@/views/project-operation-platform/data-processing/data-quality-assessment/index.vue'), - meta: { title: '数据质量评估', icon: 'audit', hidden: false }, - }, - { - path: '/construction-operation-platform/implementation-workflow/defect-storage', - name: 'DefectStorage', - component: () => import('@/views/project-operation-platform/quality-management/defect-storage/index.vue'), - meta: { title: '缺陷入库', icon: 'folder-add', hidden: false }, + } + ] }, + + // { + // path: '/construction-operation-platform/implementation-workflow/project-delivery', + // name: 'ProjectDelivery', + // component: () => import('@/components/ParentView/index.vue'), + // redirect: '/construction-operation-platform/implementation-workflow/project-delivery/delivery-overview', + // meta: { title: '机场管理', icon: 'check-circle', hidden: false }, + // }, + { path: '/construction-operation-platform/implementation-workflow/other', name: 'Other', @@ -773,13 +861,13 @@ export const systemRoutes: RouteRecordRaw[] = [ name: 'ReportTemplateOther', component: () => import('@/views/project-operation-platform/data-processing/report-template/index.vue'), meta: { title: '报告模版库', icon: 'book', hidden: false }, - }, - ], - }, - ], + } + ] + } + ] }, - ], - }, + // ], + // }, { path: '/chat-platform', name: 'ChatPlatform', @@ -797,7 +885,7 @@ export const systemRoutes: RouteRecordRaw[] = [ // hidden: false // } // } - ], + ] }, { path: '/enterprise-settings', @@ -812,9 +900,9 @@ export const systemRoutes: RouteRecordRaw[] = [ component: () => import('@/views/enterprise-settings/company-info/index.vue'), meta: { title: '企业信息', - icon: 'info-circle', - hidden: false, - }, + icon: 'info-circle', + hidden: false + } }, { path: '/enterprise-settings/admin-permissions', @@ -823,8 +911,8 @@ export const systemRoutes: RouteRecordRaw[] = [ meta: { title: '管理员权限', icon: 'lock', - hidden: false, - }, + hidden: false + } }, { path: '/enterprise-settings/data-migration', @@ -833,8 +921,8 @@ export const systemRoutes: RouteRecordRaw[] = [ meta: { title: '数据迁移', icon: 'database', - hidden: false, - }, + hidden: false + } }, { path: '/enterprise-settings/version-upgrade', @@ -843,10 +931,10 @@ export const systemRoutes: RouteRecordRaw[] = [ meta: { title: '版本升级提醒', icon: 'upgrade', - hidden: false, - }, - }, - ], + hidden: false + } + } + ] }, { path: '/enterprise-dashboard', @@ -862,8 +950,8 @@ export const systemRoutes: RouteRecordRaw[] = [ meta: { title: '数据概览', icon: 'bar-chart', - hidden: false, - }, + hidden: false + } }, { path: '/enterprise-dashboard/member-data', @@ -872,8 +960,8 @@ export const systemRoutes: RouteRecordRaw[] = [ meta: { title: '成员活跃数据', icon: 'team', - hidden: false, - }, + hidden: false + } }, { path: '/enterprise-dashboard/function-usage', @@ -882,8 +970,8 @@ export const systemRoutes: RouteRecordRaw[] = [ meta: { title: '功能使用情况', icon: 'appstore', - hidden: false, - }, + hidden: false + } }, { path: '/enterprise-dashboard/application-data', @@ -892,10 +980,10 @@ export const systemRoutes: RouteRecordRaw[] = [ meta: { title: '应用使用数据', icon: 'pie-chart', - hidden: false, - }, - }, - ], + hidden: false + } + } + ] }, { path: '/system-resource', @@ -904,59 +992,60 @@ export const systemRoutes: RouteRecordRaw[] = [ redirect: '/system-resource/device-management/warehouse', meta: { title: '关于平台', icon: 'server', hidden: false, sort: 9 }, children: [ - { - path: '/system-resource/device-management/warehouse', - name: 'DeviceWarehouse', - component: () => import('@/views/system-resource/device-management/index.vue'), - meta: { - title: '库存管理', - icon: 'warehouse', - hidden: false, - }, - }, - { - path: '/system-resource/device-management/online', - name: 'DeviceOnline', - component: () => import('@/components/ParentView/index.vue'), - redirect: '/system-resource/device-management/online/drone', - meta: { - title: '在线管理', - icon: 'cloud', - hidden: false, - }, - children: [ { - path: '/system-resource/device-management/online/drone', - name: 'DeviceDrone', + path: '/system-resource/device-management/warehouse', + name: 'DeviceWarehouse', component: () => import('@/views/system-resource/device-management/index.vue'), meta: { - title: '无人机', - icon: 'drone', - hidden: false, - }, + title: '库存管理', + icon: 'warehouse', + hidden: false + } }, { - path: '/system-resource/device-management/online/nest', - name: 'DeviceNest', - component: () => import('@/views/system-resource/device-management/index.vue'), + path: '/system-resource/device-management/online', + name: 'DeviceOnline', + component: () => import('@/components/ParentView/index.vue'), + redirect: '/system-resource/device-management/online/drone', meta: { - title: '机巢', - icon: 'nest', - hidden: false, + title: '在线管理', + icon: 'cloud', + hidden: false }, - }, - { - path: '/system-resource/device-management/online/smart-terminal', - name: 'DeviceSmartTerminal', - component: () => import('@/views/system-resource/device-management/index.vue'), - meta: { - title: '其他智能终端', - icon: 'terminal', - hidden: false, - }, - }, - ], - }, + children: [ + { + path: '/system-resource/device-management/online/drone', + name: 'DeviceDrone', + component: () => import('@/views/system-resource/device-management/index.vue'), + meta: { + title: '无人机', + icon: 'drone', + hidden: false + } + }, + { + path: '/system-resource/device-management/online/nest', + name: 'DeviceNest', + component: () => import('@/views/system-resource/device-management/index.vue'), + meta: { + title: '机巢', + icon: 'nest', + hidden: false + } + }, + { + path: '/system-resource/device-management/online/smart-terminal', + name: 'DeviceSmartTerminal', + component: () => import('@/views/system-resource/device-management/index.vue'), + meta: { + title: '其他智能终端', + icon: 'terminal', + hidden: false + } + } + ] + } + , { path: '/system-resource/information-system', name: 'InformationSystem', @@ -965,7 +1054,7 @@ export const systemRoutes: RouteRecordRaw[] = [ meta: { title: '信息化系统管理', icon: 'code', - hidden: false, + hidden: false }, children: [ { @@ -975,8 +1064,8 @@ export const systemRoutes: RouteRecordRaw[] = [ meta: { title: '软件管理', icon: 'appstore', - hidden: false, - }, + hidden: false + } }, { path: '/system-resource/information-system/system-backup', @@ -985,10 +1074,10 @@ export const systemRoutes: RouteRecordRaw[] = [ meta: { title: '系统备份管理', icon: 'save', - hidden: false, - }, - }, - ], + hidden: false + } + } + ] }, { path: '/system-resource/about', @@ -997,10 +1086,10 @@ export const systemRoutes: RouteRecordRaw[] = [ meta: { title: '关于我们', icon: 'info-circle', - hidden: false, - }, - }, - ], + hidden: false + } + } + ] }, { @@ -1039,3 +1128,4 @@ export const constantRoutes: RouteRecordRaw[] = [ meta: { hidden: true }, }, ] + diff --git a/src/views/enterprise-dashboard/application-data/index.vue b/src/views/enterprise-dashboard/application-data/index.vue index 65165ee..d451903 100644 --- a/src/views/enterprise-dashboard/application-data/index.vue +++ b/src/views/enterprise-dashboard/application-data/index.vue @@ -323,138 +323,138 @@ onMounted(() => { // 使用 nextTick 确保 DOM 已完全渲染 nextTick(() => { - // 初始化应用访问量趋势图表 + // 初始化应用访问量趋势图表 if (appVisitChart.value) { - const visitChart = echarts.init(appVisitChart.value) - visitChart.setOption({ - tooltip: { - trigger: 'axis' - }, - legend: { - data: ['Web端', '移动端', '小程序'] - }, - grid: { - left: '3%', - right: '4%', - bottom: '3%', - containLabel: true - }, - xAxis: { - type: 'category', - boundaryGap: false, - data: ['周一', '周二', '周三', '周四', '周五', '周六', '周日'] - }, - yAxis: { - type: 'value' - }, - series: [ - { - name: 'Web端', - type: 'line', - data: [2500, 2800, 3200, 3100, 2950, 1800, 1200] - }, - { - name: '移动端', - type: 'line', - data: [3200, 3500, 3800, 3600, 3400, 2800, 2500] - }, - { - name: '小程序', - type: 'line', - data: [4500, 4800, 5200, 4900, 4700, 3900, 3500] - } - ] - }) + const visitChart = echarts.init(appVisitChart.value) + visitChart.setOption({ + tooltip: { + trigger: 'axis' + }, + legend: { + data: ['Web端', '移动端', '小程序'] + }, + grid: { + left: '3%', + right: '4%', + bottom: '3%', + containLabel: true + }, + xAxis: { + type: 'category', + boundaryGap: false, + data: ['周一', '周二', '周三', '周四', '周五', '周六', '周日'] + }, + yAxis: { + type: 'value' + }, + series: [ + { + name: 'Web端', + type: 'line', + data: [2500, 2800, 3200, 3100, 2950, 1800, 1200] + }, + { + name: '移动端', + type: 'line', + data: [3200, 3500, 3800, 3600, 3400, 2800, 2500] + }, + { + name: '小程序', + type: 'line', + data: [4500, 4800, 5200, 4900, 4700, 3900, 3500] + } + ] + }) } - // 初始化应用使用时长分布图表 + // 初始化应用使用时长分布图表 if (appTimeChart.value) { - const timeChart = echarts.init(appTimeChart.value) - timeChart.setOption({ - tooltip: { - trigger: 'item' - }, - legend: { - orient: 'vertical', - left: 'left' - }, - series: [ - { - name: '使用时长分布', - type: 'pie', - radius: '70%', - data: [ - { value: 35, name: 'Web端' }, - { value: 45, name: '移动端' }, - { value: 20, name: '小程序' } - ], - emphasis: { - itemStyle: { - shadowBlur: 10, - shadowOffsetX: 0, - shadowColor: 'rgba(0, 0, 0, 0.5)' - } - } + const timeChart = echarts.init(appTimeChart.value) + timeChart.setOption({ + tooltip: { + trigger: 'item' + }, + legend: { + orient: 'vertical', + left: 'left' + }, + series: [ + { + name: '使用时长分布', + type: 'pie', + radius: '70%', + data: [ + { value: 35, name: 'Web端' }, + { value: 45, name: '移动端' }, + { value: 20, name: '小程序' } + ], + emphasis: { + itemStyle: { + shadowBlur: 10, + shadowOffsetX: 0, + shadowColor: 'rgba(0, 0, 0, 0.5)' } - ] - }) + } + } + ] + }) } - // 初始化终端设备分布图表 + // 初始化终端设备分布图表 if (deviceDistributionChart.value) { - const deviceChart = echarts.init(deviceDistributionChart.value) - deviceChart.setOption({ - tooltip: { - trigger: 'axis', - axisPointer: { - type: 'shadow' - } + const deviceChart = echarts.init(deviceDistributionChart.value) + deviceChart.setOption({ + tooltip: { + trigger: 'axis', + axisPointer: { + type: 'shadow' + } + }, + legend: {}, + grid: { + left: '3%', + right: '4%', + bottom: '3%', + containLabel: true + }, + xAxis: { + type: 'value' + }, + yAxis: { + type: 'category', + data: ['Windows PC', 'Mac', 'iOS', 'Android', '微信'] + }, + series: [ + { + name: '访问量', + type: 'bar', + stack: 'total', + label: { + show: true }, - legend: {}, - grid: { - left: '3%', - right: '4%', - bottom: '3%', - containLabel: true + emphasis: { + focus: 'series' }, - xAxis: { - type: 'value' + data: [5200, 3800, 6500, 8200, 9500] + }, + { + name: '用户数', + type: 'bar', + stack: 'total', + label: { + show: true }, - yAxis: { - type: 'category', - data: ['Windows PC', 'Mac', 'iOS', 'Android', '微信'] + emphasis: { + focus: 'series' }, - series: [ - { - name: '访问量', - type: 'bar', - stack: 'total', - label: { - show: true - }, - emphasis: { - focus: 'series' - }, - data: [5200, 3800, 6500, 8200, 9500] - }, - { - name: '用户数', - type: 'bar', - stack: 'total', - label: { - show: true - }, - emphasis: { - focus: 'series' - }, - data: [280, 220, 320, 380, 420] - } - ] - }) + data: [280, 220, 320, 380, 420] + } + ] + }) } - // 监听窗口大小变化,调整图表大小 - window.addEventListener('resize', () => { + // 监听窗口大小变化,调整图表大小 + window.addEventListener('resize', () => { if (appVisitChart.value) { const visitChart = echarts.getInstanceByDom(appVisitChart.value) visitChart?.resize() diff --git a/src/views/enterprise-dashboard/function-usage/index.vue b/src/views/enterprise-dashboard/function-usage/index.vue index 88e39f6..3a03b42 100644 --- a/src/views/enterprise-dashboard/function-usage/index.vue +++ b/src/views/enterprise-dashboard/function-usage/index.vue @@ -222,135 +222,135 @@ onMounted(() => { // 使用 nextTick 确保 DOM 已完全渲染 nextTick(() => { - // 初始化功能模块使用频率图表 + // 初始化功能模块使用频率图表 if (moduleUsageChart.value) { - const moduleChart = echarts.init(moduleUsageChart.value) - moduleChart.setOption({ - tooltip: { - trigger: 'axis', - axisPointer: { - type: 'shadow' - } - }, - legend: { - data: ['使用次数', '使用人数'] - }, - grid: { - left: '3%', - right: '4%', - bottom: '3%', - containLabel: true - }, - xAxis: { - type: 'value' - }, - yAxis: { - type: 'category', - data: ['组织架构', '资产管理', '产品与服务', '项目管理', '施工操作台', '聊天平台', '企业设置', '系统资源管理'] - }, - series: [ - { - name: '使用次数', - type: 'bar', - data: [2110, 1988, 2106, 2470, 2460, 1420, 720, 650] - }, - { - name: '使用人数', - type: 'bar', - data: [320, 302, 315, 335, 340, 356, 120, 85] - } - ] - }) + const moduleChart = echarts.init(moduleUsageChart.value) + moduleChart.setOption({ + tooltip: { + trigger: 'axis', + axisPointer: { + type: 'shadow' + } + }, + legend: { + data: ['使用次数', '使用人数'] + }, + grid: { + left: '3%', + right: '4%', + bottom: '3%', + containLabel: true + }, + xAxis: { + type: 'value' + }, + yAxis: { + type: 'category', + data: ['组织架构', '资产管理', '产品与服务', '项目管理', '施工操作台', '聊天平台', '企业设置', '系统资源管理'] + }, + series: [ + { + name: '使用次数', + type: 'bar', + data: [2110, 1988, 2106, 2470, 2460, 1420, 720, 650] + }, + { + name: '使用人数', + type: 'bar', + data: [320, 302, 315, 335, 340, 356, 120, 85] + } + ] + }) } - // 初始化各部门功能使用分布图表 + // 初始化各部门功能使用分布图表 if (departmentUsageChart.value) { - const departmentChart = echarts.init(departmentUsageChart.value) - departmentChart.setOption({ - tooltip: { - trigger: 'item' - }, - legend: { - orient: 'vertical', - left: 'left' - }, - series: [ - { - name: '部门使用分布', - type: 'pie', - radius: '70%', - data: [ - { value: 35, name: '技术部' }, - { value: 25, name: '市场部' }, - { value: 20, name: '销售部' }, - { value: 10, name: '人事部' }, - { value: 10, name: '财务部' } - ], - emphasis: { - itemStyle: { - shadowBlur: 10, - shadowOffsetX: 0, - shadowColor: 'rgba(0, 0, 0, 0.5)' - } - } + const departmentChart = echarts.init(departmentUsageChart.value) + departmentChart.setOption({ + tooltip: { + trigger: 'item' + }, + legend: { + orient: 'vertical', + left: 'left' + }, + series: [ + { + name: '部门使用分布', + type: 'pie', + radius: '70%', + data: [ + { value: 35, name: '技术部' }, + { value: 25, name: '市场部' }, + { value: 20, name: '销售部' }, + { value: 10, name: '人事部' }, + { value: 10, name: '财务部' } + ], + emphasis: { + itemStyle: { + shadowBlur: 10, + shadowOffsetX: 0, + shadowColor: 'rgba(0, 0, 0, 0.5)' } - ] - }) + } + } + ] + }) } - // 初始化功能使用时长占比图表 + // 初始化功能使用时长占比图表 if (usageTimeChart.value) { - const timeChart = echarts.init(usageTimeChart.value) - timeChart.setOption({ - tooltip: { - trigger: 'item' + const timeChart = echarts.init(usageTimeChart.value) + timeChart.setOption({ + tooltip: { + trigger: 'item' + }, + legend: { + orient: 'vertical', + left: 'left' + }, + series: [ + { + name: '使用时长占比', + type: 'pie', + radius: ['40%', '70%'], + avoidLabelOverlap: false, + itemStyle: { + borderRadius: 10, + borderColor: '#fff', + borderWidth: 2 }, - legend: { - orient: 'vertical', - left: 'left' + label: { + show: false, + position: 'center' }, - series: [ - { - name: '使用时长占比', - type: 'pie', - radius: ['40%', '70%'], - avoidLabelOverlap: false, - itemStyle: { - borderRadius: 10, - borderColor: '#fff', - borderWidth: 2 - }, - label: { - show: false, - position: 'center' - }, - emphasis: { - label: { - show: true, - fontSize: '16', - fontWeight: 'bold' - } - }, - labelLine: { - show: false - }, - data: [ - { value: 20, name: '组织架构' }, - { value: 15, name: '资产管理' }, - { value: 15, name: '产品与服务' }, - { value: 20, name: '项目管理' }, - { value: 20, name: '施工操作台' }, - { value: 5, name: '聊天平台' }, - { value: 3, name: '企业设置' }, - { value: 2, name: '系统资源管理' } - ] + emphasis: { + label: { + show: true, + fontSize: '16', + fontWeight: 'bold' } + }, + labelLine: { + show: false + }, + data: [ + { value: 20, name: '组织架构' }, + { value: 15, name: '资产管理' }, + { value: 15, name: '产品与服务' }, + { value: 20, name: '项目管理' }, + { value: 20, name: '施工操作台' }, + { value: 5, name: '聊天平台' }, + { value: 3, name: '企业设置' }, + { value: 2, name: '系统资源管理' } ] - }) + } + ] + }) } - // 监听窗口大小变化,调整图表大小 - window.addEventListener('resize', () => { + // 监听窗口大小变化,调整图表大小 + window.addEventListener('resize', () => { if (moduleUsageChart.value) { const moduleChart = echarts.getInstanceByDom(moduleUsageChart.value) moduleChart?.resize() diff --git a/src/views/enterprise-dashboard/member-data/index.vue b/src/views/enterprise-dashboard/member-data/index.vue index 0d2ff82..00ad5a5 100644 --- a/src/views/enterprise-dashboard/member-data/index.vue +++ b/src/views/enterprise-dashboard/member-data/index.vue @@ -322,150 +322,150 @@ onMounted(() => { // 使用 nextTick 确保 DOM 已完全渲染 nextTick(() => { - // 初始化部门活跃度对比图表 + // 初始化部门活跃度对比图表 if (departmentActivityChart.value) { - const departmentChart = echarts.init(departmentActivityChart.value) - departmentChart.setOption({ - tooltip: { - trigger: 'axis', - axisPointer: { - type: 'shadow' - } - }, - legend: {}, - grid: { - left: '3%', - right: '4%', - bottom: '3%', - containLabel: true - }, - xAxis: { - type: 'category', - data: ['技术部', '市场部', '销售部', '人事部', '财务部'] - }, - yAxis: { - type: 'value' - }, - series: [ - { - name: '活跃度', - type: 'bar', - data: [92, 85, 88, 79, 82] - }, - { - name: '登录次数', - type: 'bar', - data: [320, 280, 310, 240, 260] - }, - { - name: '操作次数', - type: 'bar', - data: [2800, 2100, 2400, 1800, 2000] - } - ] - }) + const departmentChart = echarts.init(departmentActivityChart.value) + departmentChart.setOption({ + tooltip: { + trigger: 'axis', + axisPointer: { + type: 'shadow' + } + }, + legend: {}, + grid: { + left: '3%', + right: '4%', + bottom: '3%', + containLabel: true + }, + xAxis: { + type: 'category', + data: ['技术部', '市场部', '销售部', '人事部', '财务部'] + }, + yAxis: { + type: 'value' + }, + series: [ + { + name: '活跃度', + type: 'bar', + data: [92, 85, 88, 79, 82] + }, + { + name: '登录次数', + type: 'bar', + data: [320, 280, 310, 240, 260] + }, + { + name: '操作次数', + type: 'bar', + data: [2800, 2100, 2400, 1800, 2000] + } + ] + }) } - // 初始化每日活跃用户数图表 + // 初始化每日活跃用户数图表 if (dailyActiveUsersChart.value) { - const dailyActiveChart = echarts.init(dailyActiveUsersChart.value) - dailyActiveChart.setOption({ - tooltip: { - trigger: 'axis' - }, - xAxis: { - type: 'category', - data: ['周一', '周二', '周三', '周四', '周五', '周六', '周日'] - }, - yAxis: { - type: 'value' - }, - series: [ - { - data: [120, 132, 145, 135, 128, 68, 42], - type: 'line', - areaStyle: {} - } - ] - }) + const dailyActiveChart = echarts.init(dailyActiveUsersChart.value) + dailyActiveChart.setOption({ + tooltip: { + trigger: 'axis' + }, + xAxis: { + type: 'category', + data: ['周一', '周二', '周三', '周四', '周五', '周六', '周日'] + }, + yAxis: { + type: 'value' + }, + series: [ + { + data: [120, 132, 145, 135, 128, 68, 42], + type: 'line', + areaStyle: {} + } + ] + }) } - // 初始化平均在线时长图表 + // 初始化平均在线时长图表 if (onlineTimeChart.value) { - const onlineChart = echarts.init(onlineTimeChart.value) - onlineChart.setOption({ - tooltip: { - trigger: 'axis' - }, - xAxis: { - type: 'category', - data: ['技术部', '市场部', '销售部', '人事部', '财务部'] - }, - yAxis: { - type: 'value', - axisLabel: { - formatter: '{value} 小时' - } - }, - series: [ - { - name: '平均在线时长', - type: 'bar', - data: [7.5, 6.8, 7.2, 6.5, 6.9] - } - ] - }) + const onlineChart = echarts.init(onlineTimeChart.value) + onlineChart.setOption({ + tooltip: { + trigger: 'axis' + }, + xAxis: { + type: 'category', + data: ['技术部', '市场部', '销售部', '人事部', '财务部'] + }, + yAxis: { + type: 'value', + axisLabel: { + formatter: '{value} 小时' + } + }, + series: [ + { + name: '平均在线时长', + type: 'bar', + data: [7.5, 6.8, 7.2, 6.5, 6.9] + } + ] + }) } - // 初始化考勤趋势图表 + // 初始化考勤趋势图表 if (attendanceTrendChart.value) { - const attendanceChart = echarts.init(attendanceTrendChart.value) - attendanceChart.setOption({ - tooltip: { - trigger: 'axis' - }, - legend: { - data: ['出勤率', '迟到率', '早退率'] - }, - grid: { - left: '3%', - right: '4%', - bottom: '3%', - containLabel: true - }, - xAxis: { - type: 'category', - boundaryGap: false, - data: ['1月', '2月', '3月', '4月', '5月', '6月'] - }, - yAxis: { - type: 'value', - axisLabel: { - formatter: '{value}%' - } - }, - series: [ - { - name: '出勤率', - type: 'line', - data: [96.2, 97.1, 96.8, 97.5, 98.2, 97.8] - }, - { - name: '迟到率', - type: 'line', - data: [2.8, 2.2, 2.5, 1.8, 1.2, 1.5] - }, - { - name: '早退率', - type: 'line', - data: [1.0, 0.7, 0.7, 0.7, 0.6, 0.7] - } - ] - }) + const attendanceChart = echarts.init(attendanceTrendChart.value) + attendanceChart.setOption({ + tooltip: { + trigger: 'axis' + }, + legend: { + data: ['出勤率', '迟到率', '早退率'] + }, + grid: { + left: '3%', + right: '4%', + bottom: '3%', + containLabel: true + }, + xAxis: { + type: 'category', + boundaryGap: false, + data: ['1月', '2月', '3月', '4月', '5月', '6月'] + }, + yAxis: { + type: 'value', + axisLabel: { + formatter: '{value}%' + } + }, + series: [ + { + name: '出勤率', + type: 'line', + data: [96.2, 97.1, 96.8, 97.5, 98.2, 97.8] + }, + { + name: '迟到率', + type: 'line', + data: [2.8, 2.2, 2.5, 1.8, 1.2, 1.5] + }, + { + name: '早退率', + type: 'line', + data: [1.0, 0.7, 0.7, 0.7, 0.6, 0.7] + } + ] + }) } - // 监听窗口大小变化,调整图表大小 - window.addEventListener('resize', () => { + // 监听窗口大小变化,调整图表大小 + window.addEventListener('resize', () => { if (departmentActivityChart.value) { const departmentChart = echarts.getInstanceByDom(departmentActivityChart.value) departmentChart?.resize() diff --git a/src/views/enterprise-dashboard/overview/index.vue b/src/views/enterprise-dashboard/overview/index.vue index 7587973..4ccbb5b 100644 --- a/src/views/enterprise-dashboard/overview/index.vue +++ b/src/views/enterprise-dashboard/overview/index.vue @@ -105,139 +105,139 @@ onMounted(() => { // 使用 nextTick 确保 DOM 已完全渲染 nextTick(() => { - // 初始化项目进度统计图表 + // 初始化项目进度统计图表 if (projectProgressChart.value) { - const projectChart = echarts.init(projectProgressChart.value) - projectChart.setOption({ - tooltip: { - trigger: 'item' - }, - legend: { - orient: 'vertical', - left: 'left' - }, - series: [ - { - name: '项目状态', - type: 'pie', - radius: '70%', - data: [ - { value: 48, name: '进行中' }, - { value: 65, name: '已完成' }, - { value: 12, name: '已暂停' }, - { value: 3, name: '已取消' } - ], - emphasis: { - itemStyle: { - shadowBlur: 10, - shadowOffsetX: 0, - shadowColor: 'rgba(0, 0, 0, 0.5)' - } - } + const projectChart = echarts.init(projectProgressChart.value) + projectChart.setOption({ + tooltip: { + trigger: 'item' + }, + legend: { + orient: 'vertical', + left: 'left' + }, + series: [ + { + name: '项目状态', + type: 'pie', + radius: '70%', + data: [ + { value: 48, name: '进行中' }, + { value: 65, name: '已完成' }, + { value: 12, name: '已暂停' }, + { value: 3, name: '已取消' } + ], + emphasis: { + itemStyle: { + shadowBlur: 10, + shadowOffsetX: 0, + shadowColor: 'rgba(0, 0, 0, 0.5)' } - ] - }) + } + } + ] + }) } - - // 初始化资源使用情况图表 + + // 初始化资源使用情况图表 if (resourceUsageChart.value) { - const resourceChart = echarts.init(resourceUsageChart.value) - resourceChart.setOption({ - tooltip: { - trigger: 'axis', - axisPointer: { - type: 'shadow' - } + const resourceChart = echarts.init(resourceUsageChart.value) + resourceChart.setOption({ + tooltip: { + trigger: 'axis', + axisPointer: { + type: 'shadow' + } + }, + legend: {}, + grid: { + left: '3%', + right: '4%', + bottom: '3%', + containLabel: true + }, + xAxis: { + type: 'value' + }, + yAxis: { + type: 'category', + data: ['服务器', '存储空间', '带宽', '设备使用率', '人力资源'] + }, + series: [ + { + name: '已使用', + type: 'bar', + stack: 'total', + label: { + show: true }, - legend: {}, - grid: { - left: '3%', - right: '4%', - bottom: '3%', - containLabel: true + emphasis: { + focus: 'series' }, - xAxis: { - type: 'value' + data: [65, 72, 58, 80, 75] + }, + { + name: '剩余', + type: 'bar', + stack: 'total', + label: { + show: true }, - yAxis: { - type: 'category', - data: ['服务器', '存储空间', '带宽', '设备使用率', '人力资源'] + emphasis: { + focus: 'series' }, - series: [ - { - name: '已使用', - type: 'bar', - stack: 'total', - label: { - show: true - }, - emphasis: { - focus: 'series' - }, - data: [65, 72, 58, 80, 75] - }, - { - name: '剩余', - type: 'bar', - stack: 'total', - label: { - show: true - }, - emphasis: { - focus: 'series' - }, - data: [35, 28, 42, 20, 25] - } - ] - }) + data: [35, 28, 42, 20, 25] + } + ] + }) } - - // 初始化业务趋势图表 + + // 初始化业务趋势图表 if (businessTrendChart.value) { - const businessChart = echarts.init(businessTrendChart.value) - businessChart.setOption({ - tooltip: { - trigger: 'axis' - }, - legend: { - data: ['项目数量', '营业收入', '新增客户'] - }, - grid: { - left: '3%', - right: '4%', - bottom: '3%', - containLabel: true - }, - xAxis: { - type: 'category', - boundaryGap: false, - data: ['1月', '2月', '3月', '4月', '5月', '6月'] - }, - yAxis: { - type: 'value' - }, - series: [ - { - name: '项目数量', - type: 'line', - data: [10, 12, 15, 18, 22, 24] - }, - { - name: '营业收入', - type: 'line', - data: [120, 132, 145, 160, 178, 190] - }, - { - name: '新增客户', - type: 'line', - data: [5, 7, 8, 10, 12, 15] - } - ] - }) + const businessChart = echarts.init(businessTrendChart.value) + businessChart.setOption({ + tooltip: { + trigger: 'axis' + }, + legend: { + data: ['项目数量', '营业收入', '新增客户'] + }, + grid: { + left: '3%', + right: '4%', + bottom: '3%', + containLabel: true + }, + xAxis: { + type: 'category', + boundaryGap: false, + data: ['1月', '2月', '3月', '4月', '5月', '6月'] + }, + yAxis: { + type: 'value' + }, + series: [ + { + name: '项目数量', + type: 'line', + data: [10, 12, 15, 18, 22, 24] + }, + { + name: '营业收入', + type: 'line', + data: [120, 132, 145, 160, 178, 190] + }, + { + name: '新增客户', + type: 'line', + data: [5, 7, 8, 10, 12, 15] + } + ] + }) } - - // 监听窗口大小变化,调整图表大小 - window.addEventListener('resize', () => { + + // 监听窗口大小变化,调整图表大小 + window.addEventListener('resize', () => { if (projectProgressChart.value) { const projectChart = echarts.getInstanceByDom(projectProgressChart.value) projectChart?.resize()