# Task: Replace ranking progress tracks with horizontal bar chart ## Identity - Task ID: 20260902-dashboard-bar-chart-f184c2 - Mode: Feature - Branch: main - Worktree: /Users/inmanx/Documents/lwltAPI - Base commit: de9f33dc45b137d1e48f3853904e45d1589b4b2d - Owner: codex - Status: Ready for integration ## Scope - Replace the two-layer progress-track treatment in both leadership rankings with a conventional vertical list of horizontal bars. - Make each task-type or employee row itself the filled bar, with bar length representing operation count. - Explicitly sort both ranking datasets by operation count descending so longer bars appear above shorter bars. - Preserve exact operation/success counts, fixed panel sizing, scrolling, and click-through filters. - Update static cache versions and dashboard regression assertions. ## Intent And Constraints - Follow the clarified visual model: no separate track and no inner success-progress line; the whole row background is the chart bar. - Use operation count as the only encoded bar length. Keep success count as readable text rather than a second visual series or percentage. - Work within the existing vanilla HTML/CSS/JavaScript stack and current dashboard response; do not add a charting dependency or change the API. - Preserve leadership-only read access, business-safe language, employee/task-type drill-through, detail viewing, and all task/ERP authorization boundaries. - Do not restart, deploy, mutate runtime data, access ERP, or introduce an organization concept. ## Outcome - Simplified the reusable ranking-bar renderer to one full-height background shape whose width is normalized to the largest operation count in that ranking. - Removed the separate pale track and dark success-progress overlay. Each ranking row is now the bar itself, with name, rank, operation count, and success count rendered directly above the filled background. - Returned ranking rows to a compact three-column layout because the chart no longer needs a dedicated track column or mobile second row. - Added explicit descending client-side sorting for task types and employees by operation count, independent of response ordering. - Kept success counts highlighted in green text and retained all accessible button labels; completion-rate text and percentages remain absent. - Preserved fixed 304px panels, vertical scrolling, task-type/employee click-through, filters, task detail, and business-safe dashboard copy. - Updated asset cache versions and regression assertions for the bar-chart presentation and descending sort. - The running 8786 service serves these static changes directly. No restart, deployment, database/task mutation, ERP access, or external send was performed. ## Verification - `node --check LianSyn-platform/app.js`: passed with the bundled Node runtime. - Focused account/dashboard regression: 8/8 passed. - `node --run check:repo`: 10/10 passed. - `node --run check`: passed. - `node --run test:control-plane`: 153/153 passed. - `node --run test:legacy`: 256/256 passed. - `node --run build`: passed. - `git diff --check`: passed. - Authenticated browser verification on `http://127.0.0.1:8786/operations-dashboard?bar-chart=1` loaded 359 operations, 251 successes, 23 task types, and 1 participating employee. - Visual verification confirmed that every row background is a single full-height horizontal bar, with 43 operations at full width followed by visibly shorter 27, 26, 24, and 24 operation bars. - DOM order verification confirmed the first five task types were “删除订单 / 恢复订单 / 安排导游 / 酒店安排 / 取消订单” with operation counts `43 / 27 / 26 / 24 / 24`. - Interaction verification confirmed that clicking the 43-operation bar selected “删除订单” and narrowed the detail table to 43 matching operations while completion-rate language remained absent. ## Follow-ups - The current standard data contains one employee, so the employee chart currently contains one full-width bar; descending multi-employee comparison will appear automatically as additional accounts gain task activity. ## Promotion Candidates - None. This corrects the visual encoding of the already accepted count-based rankings without changing product, authorization, API, or data semantics.