feat(platform): align vehicle detail with statistics query

This commit is contained in:
lingniu
2026-07-05 14:50:54 +08:00
parent 597395852c
commit 5c73cea263
2 changed files with 25 additions and 25 deletions

View File

@@ -11340,7 +11340,7 @@ test('shows unified service overview on vehicle detail', async () => {
expect(screen.getByText('看实时位置')).toBeInTheDocument();
expect(screen.getByText('回放轨迹证据')).toBeInTheDocument();
expect(screen.getAllByText('查询历史数据').length).toBeGreaterThanOrEqual(1);
expect(screen.getByText('复核里程统计')).toBeInTheDocument();
expect(screen.getByText('复核统计查询')).toBeInTheDocument();
expect(screen.getByText('闭环告警事件')).toBeInTheDocument();
expect(screen.getByText('单车运营工作台')).toBeInTheDocument();
expect(screen.getByText('单车服务处理清单')).toBeInTheDocument();
@@ -11354,7 +11354,7 @@ test('shows unified service overview on vehicle detail', async () => {
expect(screen.getAllByText('轨迹回放').length).toBeGreaterThanOrEqual(1);
expect(screen.getAllByText('历史数据').length).toBeGreaterThan(0);
expect(screen.getByText('告警处置')).toBeInTheDocument();
expect(screen.getByText('里程复核')).toBeInTheDocument();
expect(screen.getAllByText('统计复核').length).toBeGreaterThan(0);
expect(screen.getByText('确认实时状态')).toBeInTheDocument();
expect(screen.getByText('回放轨迹断点')).toBeInTheDocument();
expect(screen.getAllByText('查询历史数据').length).toBeGreaterThanOrEqual(1);
@@ -11371,7 +11371,7 @@ test('shows unified service overview on vehicle detail', async () => {
expect(screen.getByRole('button', { name: '单车任务 看实时位置 实时监控' })).toBeInTheDocument();
expect(screen.getByRole('button', { name: '单车任务 回放轨迹证据 轨迹回放' })).toBeInTheDocument();
expect(screen.getByRole('button', { name: '单车任务 查询历史数据 历史数据' })).toBeInTheDocument();
expect(screen.getByRole('button', { name: '单车任务 复核里程统计 里程统计' })).toBeInTheDocument();
expect(screen.getByRole('button', { name: '单车任务 复核统计查询 统计查询' })).toBeInTheDocument();
expect(screen.getByRole('button', { name: '单车任务 闭环告警事件 告警事件' })).toBeInTheDocument();
fireEvent.click(screen.getByRole('button', { name: '单车运营工作台 历史数据 查看历史数据' }));
expect(window.location.hash).toBe('#/history-query?keyword=VIN001&tab=raw');
@@ -11864,7 +11864,7 @@ test('copies vehicle service diagnostic summary', async () => {
expect(screen.getByText('业务可用性')).toBeInTheDocument();
expect(await screen.findByText('车辆服务结论')).toBeInTheDocument();
expect(screen.getByText('单车 Live View')).toBeInTheDocument();
expect(screen.getByText('客户打开一辆车时先看当前位置、最后上报、速度、SOC、总里程和告警再进入轨迹回放、里程统计、数据导出和告警闭环。')).toBeInTheDocument();
expect(screen.getByText('客户打开一辆车时先看当前位置、最后上报、速度、SOC、总里程和告警再进入轨迹回放、统计查询、数据导出和告警闭环。')).toBeInTheDocument();
expect(screen.getByText('当前位置')).toBeInTheDocument();
expect(screen.getByRole('button', { name: '单车实时视图 实时位置 查看实时' })).toBeInTheDocument();
expect(screen.getByRole('button', { name: '单车实时视图 数据导出 历史导出' })).toBeInTheDocument();
@@ -11939,7 +11939,7 @@ test('copies vehicle service diagnostic summary', async () => {
expect(copied).toContain('实时http://localhost:3000/#/realtime?keyword=VIN-SUMMARY-001&protocol=JT808');
expect(copied).toContain('轨迹http://localhost:3000/#/history?keyword=VIN-SUMMARY-001&protocol=JT808');
expect(copied).toContain('历史数据http://localhost:3000/#/history-query?keyword=VIN-SUMMARY-001&protocol=JT808&tab=raw&includeFields=true');
expect(copied).toContain('里程http://localhost:3000/#/mileage?keyword=VIN-SUMMARY-001&protocol=JT808');
expect(copied).toContain('统计查询http://localhost:3000/#/mileage?keyword=VIN-SUMMARY-001&protocol=JT808');
fireEvent.click(screen.getByRole('button', { name: /复制运营摘要/ }));
await waitFor(() => {
@@ -11961,7 +11961,7 @@ test('copies vehicle service diagnostic summary', async () => {
expect(operationsCopied).toContain('实时监控http://localhost:3000/#/realtime?keyword=VIN-SUMMARY-001&protocol=JT808');
expect(operationsCopied).toContain('轨迹回放http://localhost:3000/#/history?keyword=VIN-SUMMARY-001&protocol=JT808');
expect(operationsCopied).toContain('历史数据http://localhost:3000/#/history-query?keyword=VIN-SUMMARY-001&protocol=JT808&tab=raw&includeFields=true');
expect(operationsCopied).toContain('里程统计http://localhost:3000/#/mileage?keyword=VIN-SUMMARY-001&protocol=JT808');
expect(operationsCopied).toContain('统计查询http://localhost:3000/#/mileage?keyword=VIN-SUMMARY-001&protocol=JT808');
fireEvent.click(screen.getByRole('button', { name: '复制处理清单' }));
await waitFor(() => {
@@ -11978,7 +11978,7 @@ test('copies vehicle service diagnostic summary', async () => {
expect(runbookCopied).toContain('5. 复核统计口径');
expect(runbookCopied).toContain('验收:车辆在线状态、最新时间、有效坐标均可解释。');
expect(runbookCopied).toContain('告警事件http://localhost:3000/#/alert-events?keyword=VIN-SUMMARY-001&protocol=JT808');
expect(runbookCopied).toContain('里程统计http://localhost:3000/#/mileage?keyword=VIN-SUMMARY-001&protocol=JT808');
expect(runbookCopied).toContain('统计查询http://localhost:3000/#/mileage?keyword=VIN-SUMMARY-001&protocol=JT808');
});
test('exports vehicle detail service dossier as csv', async () => {