1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
| {
| "biz": "生产设备BI大屏(dashboard_id=3)新增设备/维保维度统计",
| "target": "36.213.150.237:10000/mom-hm",
| "executedAt": "2026-10-15",
| "sql": "add-chart-dims.sql",
| "before": {
| "dashboard3Charts": 8,
| "chartIds": [16, 17, 18, 19, 20, 21, 22, 52],
| "note": "远端为旧版:21=工单类型分布(pie)、22=最近工单列表;多出 52=工单进度(table);缺 10-15 新增的设备图表"
| },
| "after": {
| "dashboard3Charts": 13,
| "chartIds": [16, 17, 18, 19, 20, 21, 22, 52, 53, 54, 55, 56, 57]
| },
| "inserted": [
| { "id": 53, "name": "设备按车间分布", "chartType": "pie", "sort": 9, "sql": "mes_dv_machinery JOIN mes_md_workshop GROUP BY workshop", "sample": "9 个车间 4~31 台" },
| { "id": 54, "name": "点检·保养月度趋势", "chartType": "line", "sort": 10, "sql": "check_record/mainten_record 按 yyyy-MM,双序列(点检/保养)", "sample": "2026-09 点检4041 保养2746;2026-10 点检1615 保养1068" },
| { "id": 55, "name": "点检完成率", "chartType": "gauge", "sort": 11, "sql": "ROUND(SUM(status=20)*100/COUNT(*),1) mes_dv_check_record", "sample": "81.0%" },
| { "id": 56, "name": "保养完成率", "chartType": "gauge", "sort": 12, "sql": "ROUND(SUM(status=4)*100/COUNT(*),1) mes_dv_mainten_record", "sample": "81.5%" },
| { "id": 57, "name": "点检计划类型分布", "chartType": "pie", "sort": 13, "sql": "mes_dv_check_plan GROUP BY type", "sample": "点检计划102 / 保养计划284" }
| ],
| "enums": {
| "MesDvCheckRecordStatusEnum": "10=草稿, 20=已完成 (完成率取 20)",
| "MesDvMaintenRecordStatusEnum": "0=草稿, 4=已提交 (完成率取 4)",
| "MesDvCheckPlanTypeEnum": "1=点检, 2=保养"
| },
| "recheck": {
| "五条SQL在远端实跑": "均返回预期列(name/value 或 name/点检/保养)与非空数据",
| "存储转义": "回读 id=54/57 的 query_sql,单引号已正确落库(无残留反斜杠)",
| "读取路径": "DashboardServiceImpl 直接查库、无缓存;selectListByDashboardId 过滤 status=1 并按 sort 排序,插入即生效,无需重启"
| },
| "notVerified": "未在浏览器实际渲染页面(远端未提供可达的前端/接口),仅校验到配置与数据层",
| "configExport": {
| "file": "docs/sql/config_export_all_20261015.sql",
| "action": "按既有增量段格式补录:① 头部登记 5 图增量;② bi_chart_config 主 INSERT 之后追加 id 53~57 的 INSERT(39 → 44 行)。已在源库 ruoyi-vue-pro 做事务回滚验证:插入 5 行、回滚归零、转义正确。"
| },
| "obs": "远端 mom-hm 未获得 10-15 那批大屏改动(21/22/19 仍是旧口径,且有独有的 52「工单进度」),与源库/本地(37/38/39 版)存在分叉;本次仅按用户选择向远端新增 5 图,未改动远端既有图表。",
| "rollback": "DELETE FROM bi_chart_config WHERE dashboard_id = 3 AND id IN (53, 54, 55, 56, 57);"
| }
|
|