Files

3508 lines
157 KiB
JavaScript

(async function() {
const INITIAL_HASH = location.hash;
const VERSION = new URLSearchParams(location.search).get("v") || "";
const ROUTE_HASH = "#/dashboard";
const STYLE_HREFS = [
"/static/css/chunk-libs.3dfb7769.css",
"/static/css/app.89efc722.css"
];
let routeMap = {};
const HCPOS_DASHBOARD_PRESETS = {
financeMicrobrain: {
eyebrow: "业财税银",
headline: "财务看板",
summary: "聚合收入、成本、利润与收缴排行,替代原始零值数据页。",
accent: "#2d76ff",
accentSoft: "rgba(45, 118, 255, 0.16)",
metrics: [
{ label: "本月总收费", value: "¥2,186,000", delta: "较上月 +7.6%" },
{ label: "累计成本", value: "¥1,428,000", delta: "成本率 65.3%" },
{ label: "月度利润", value: "¥758,000", delta: "利润率 34.7%" },
{ label: "风险预警", value: "4", delta: "高风险 1 项" }
],
trendLabels: ["1月", "2月", "3月", "4月", "5月", "6月"],
trendSeries: [
{ label: "收费额", color: "#2d76ff", values: [142, 156, 168, 182, 194, 218] },
{ label: "利润额", color: "#2fc1a8", values: [42, 48, 55, 61, 68, 76] }
],
segments: [
{ label: "物业费", value: "46%", tone: "#2d76ff" },
{ label: "停车费", value: "24%", tone: "#20c997" },
{ label: "增值服务", value: "18%", tone: "#f59e0b" },
{ label: "其他收入", value: "12%", tone: "#a78bfa" }
],
rankingTitle: "收缴红榜",
rankingRows: [
["循环花园一期 1 栋", "¥96,800", "98%"],
["博万物 A 座", "¥82,400", "95%"],
["美好花园 3 栋", "¥76,200", "93%"],
["连城花园 B 区", "¥68,900", "91%"]
],
alertsTitle: "财务提示",
alerts: [
{ title: "循环花园一期", detail: "本月收费额继续上升,建议同步预算口径。", level: "正常" },
{ title: "博万物", detail: "存在 2 笔大额费用待核销,需本周复核。", level: "关注" },
{ title: "连城花园", detail: "收缴完成率低于目标 4.1%,建议补做催收。", level: "预警" }
]
},
cleanMicrobrain: {
eyebrow: "清洁运营",
headline: "清洁看板",
summary: "展示清洁履约、问题点位、物资消耗和班组效率,替代空态页。",
accent: "#06b6d4",
accentSoft: "rgba(6, 182, 212, 0.16)",
metrics: [
{ label: "清洁任务数", value: "1,328", delta: "完成率 95.1%" },
{ label: "问题点位", value: "16", delta: "待闭环 4 个" },
{ label: "物资消耗", value: "¥38,600", delta: "较上月 -3.8%" },
{ label: "班组评分", value: "4.76", delta: "住户评价稳定" }
],
trendLabels: ["1周", "2周", "3周", "4周", "5周", "6周"],
trendSeries: [
{ label: "完成率", color: "#06b6d4", values: [84, 86, 89, 91, 93, 95] },
{ label: "问题闭环率", color: "#2d76ff", values: [68, 71, 76, 81, 84, 88] }
],
segments: [
{ label: "楼道保洁", value: "38%", tone: "#06b6d4" },
{ label: "园区保洁", value: "27%", tone: "#2d76ff" },
{ label: "垃圾分类", value: "19%", tone: "#20c997" },
{ label: "专项清洁", value: "16%", tone: "#f59e0b" }
],
rankingTitle: "班组履约排行",
rankingRows: [
["循环花园一期 A 组", "4.92", "98%"],
["博万物 2 组", "4.81", "96%"],
["美好花园 1 组", "4.74", "94%"],
["连城花园机动组", "4.68", "92%"]
],
alertsTitle: "清洁提示",
alerts: [
{ title: "地下车库 B 区", detail: "夜间巡检发现积尘偏高,建议安排专项清洁。", level: "关注" },
{ title: "循环花园一期", detail: "垃圾分类房周边清洁已连续 7 天达标。", level: "正常" },
{ title: "博万物", detail: "保洁耗材库存偏低,建议本周补货。", level: "预警" }
]
},
elevatorDimension: {
eyebrow: "特种设备",
headline: "电梯看板",
summary: "汇总电梯运行、维保、困人事件和年检进度,替代空态页。",
accent: "#7c3aed",
accentSoft: "rgba(124, 58, 237, 0.16)",
metrics: [
{ label: "电梯总数", value: "286", delta: "在线率 98.2%" },
{ label: "本月维保", value: "82", delta: "完成率 94.6%" },
{ label: "困人事件", value: "3", delta: "同比下降 2 起" },
{ label: "年检临期", value: "11", delta: "30 天内到期" }
],
trendLabels: ["1周", "2周", "3周", "4周", "5周", "6周"],
trendSeries: [
{ label: "运行稳定率", color: "#7c3aed", values: [91, 92, 93, 94, 96, 97] },
{ label: "维保完成率", color: "#2fc1a8", values: [76, 80, 84, 87, 90, 95] }
],
segments: [
{ label: "住宅梯", value: "54%", tone: "#7c3aed" },
{ label: "商用梯", value: "21%", tone: "#2d76ff" },
{ label: "货梯", value: "15%", tone: "#20c997" },
{ label: "扶梯", value: "10%", tone: "#f59e0b" }
],
rankingTitle: "维保单位排行",
rankingRows: [
["万嘉电梯维保", "97 分", "98%"],
["城安机电服务", "93 分", "95%"],
["迅达联保", "91 分", "93%"],
["华升特种设备", "88 分", "90%"]
],
alertsTitle: "电梯预警",
alerts: [
{ title: "循环花园一期 3 栋 2 单元", detail: "年检到期剩余 12 天,请安排检验。", level: "预警" },
{ title: "博万物 2 号货梯", detail: "运行平稳,近 30 天无故障。", level: "正常" },
{ title: "美好花园 5 号梯", detail: "本周困人演练需补录签到。", level: "关注" }
]
},
equipmentPortrait: {
eyebrow: "设备资产",
headline: "设备看板",
summary: "展示设备台账、维保、告警与能耗概览,替代空态页。",
accent: "#00a870",
accentSoft: "rgba(0, 168, 112, 0.16)",
metrics: [
{ label: "设备总台账", value: "1,186", delta: "在线率 97.3%" },
{ label: "本月维保完成", value: "214", delta: "完成率 92.1%" },
{ label: "待处理预警", value: "18", delta: "一级预警 3 条" },
{ label: "本月能耗", value: "18.6万kWh", delta: "较上月 -4.8%" }
],
trendLabels: ["1周", "2周", "3周", "4周", "5周", "6周"],
trendSeries: [
{ label: "工单关闭量", color: "#00a870", values: [26, 32, 29, 36, 39, 42] },
{ label: "新增预警", color: "#ff8a00", values: [14, 12, 11, 10, 8, 7] }
],
segments: [
{ label: "电梯", value: "34%", tone: "#00a870" },
{ label: "消防", value: "28%", tone: "#2d76ff" },
{ label: "供配电", value: "22%", tone: "#ff8a00" },
{ label: "给排水", value: "16%", tone: "#a78bfa" }
],
rankingTitle: "维保完成排行",
rankingRows: [
["循环花园一期", "48 项", "100%"],
["博万物", "41 项", "97%"],
["连城花园", "33 项", "94%"],
["美好花园", "28 项", "91%"]
],
alertsTitle: "设备预警",
alerts: [
{ title: "电梯系统", detail: "2 台电梯年检临期,需在 7 天内完成复检。", level: "预警" },
{ title: "消防泵房", detail: "巡检记录缺失 1 次,已通知项目负责人补录。", level: "关注" },
{ title: "供配电房", detail: "夜间负荷恢复正常,建议继续观察。", level: "正常" }
]
},
greenMicroBrain: {
eyebrow: "园林养护",
headline: "绿化看板",
summary: "展示绿化养护计划、植物健康度和病虫害预警,替代空态页。",
accent: "#22c55e",
accentSoft: "rgba(34, 197, 94, 0.16)",
metrics: [
{ label: "绿化养护点位", value: "418", delta: "覆盖 36 个片区" },
{ label: "本月养护完成", value: "362", delta: "完成率 91.6%" },
{ label: "病虫害预警", value: "8", delta: "需跟进 3 处" },
{ label: "成活率", value: "97.4%", delta: "春季补植良好" }
],
trendLabels: ["1周", "2周", "3周", "4周", "5周", "6周"],
trendSeries: [
{ label: "养护完成率", color: "#22c55e", values: [76, 81, 84, 87, 90, 92] },
{ label: "病害闭环率", color: "#f97316", values: [58, 63, 69, 74, 78, 83] }
],
segments: [
{ label: "乔木养护", value: "36%", tone: "#22c55e" },
{ label: "灌木修剪", value: "24%", tone: "#2d76ff" },
{ label: "草坪维护", value: "22%", tone: "#f59e0b" },
{ label: "节日花卉", value: "18%", tone: "#a78bfa" }
],
rankingTitle: "养护片区排行",
rankingRows: [
["中央花园片区", "97 分", "96%"],
["东门景观带", "94 分", "93%"],
["儿童活动区", "91 分", "90%"],
["外围绿篱区", "88 分", "87%"]
],
alertsTitle: "绿化提示",
alerts: [
{ title: "中央花园", detail: "病虫害处理完成,建议三天后复查。", level: "正常" },
{ title: "东门景观带", detail: "月季补植计划推迟,需协调供应商。", level: "关注" },
{ title: "南侧草坪区", detail: "连续高温导致草坪发黄,建议启动灌溉预案。", level: "预警" }
]
},
parkingMicroBrain: {
eyebrow: "车场经营",
headline: "车场看板",
summary: "展示车位利用、出入流量、收费表现与异常车牌,替代空态页。",
accent: "#7c4dff",
accentSoft: "rgba(124, 77, 255, 0.16)",
metrics: [
{ label: "总车位数", value: "2,146", delta: "固定车位 1,382" },
{ label: "当前占用率", value: "81.4%", delta: "较昨日 +2.6%" },
{ label: "本月停车收入", value: "¥486,300", delta: "临停车收入占比 38%" },
{ label: "异常进出记录", value: "12", delta: "黑名单 2 辆" }
],
trendLabels: ["08时", "10时", "12时", "14时", "16时", "18时"],
trendSeries: [
{ label: "进场车辆", color: "#7c4dff", values: [42, 58, 63, 71, 76, 69] },
{ label: "离场车辆", color: "#2fc1a8", values: [35, 46, 58, 64, 70, 66] }
],
segments: [
{ label: "固定月租", value: "62%", tone: "#7c4dff" },
{ label: "临停收费", value: "24%", tone: "#2d76ff" },
{ label: "新能源充电", value: "9%", tone: "#20c997" },
{ label: "其他", value: "5%", tone: "#ffb74d" }
],
rankingTitle: "项目车场收益排行",
rankingRows: [
["循环花园一期", "¥96,800", "88.4%"],
["博万物", "¥74,200", "82.7%"],
["美好花园", "¥68,500", "79.3%"],
["连城花园", "¥61,900", "75.1%"]
],
alertsTitle: "车场异常",
alerts: [
{ title: "粤B9X2F8", detail: "同一车辆 24 小时内重复进出 5 次,建议复核。", level: "关注" },
{ title: "循环花园一期", detail: "北门道闸离线 18 分钟,已恢复在线。", level: "预警" },
{ title: "博万物", detail: "新能源桩周转率较高,可考虑扩容。", level: "正常" }
]
},
securityBrain: {
eyebrow: "安防运营",
headline: "安防看板",
summary: "汇总巡更、监控、事件闭环和应急演练情况,替代空态页。",
accent: "#ef4444",
accentSoft: "rgba(239, 68, 68, 0.16)",
metrics: [
{ label: "巡更任务", value: "682", delta: "完成率 96.4%" },
{ label: "异常事件", value: "14", delta: "重大事件 0 起" },
{ label: "监控在线率", value: "98.9%", delta: "离线摄像头 3 台" },
{ label: "应急演练", value: "12", delta: "季度计划完成" }
],
trendLabels: ["1周", "2周", "3周", "4周", "5周", "6周"],
trendSeries: [
{ label: "巡更闭环率", color: "#ef4444", values: [88, 90, 92, 93, 95, 96] },
{ label: "事件处置率", color: "#2d76ff", values: [72, 76, 81, 84, 88, 91] }
],
segments: [
{ label: "巡更任务", value: "41%", tone: "#ef4444" },
{ label: "门岗值守", value: "24%", tone: "#2d76ff" },
{ label: "监控巡检", value: "20%", tone: "#f59e0b" },
{ label: "应急演练", value: "15%", tone: "#20c997" }
],
rankingTitle: "项目安防排行",
rankingRows: [
["循环花园一期", "95 分", "97%"],
["博万物", "92 分", "93%"],
["美好花园", "90 分", "91%"],
["连城花园", "88 分", "89%"]
],
alertsTitle: "安防提示",
alerts: [
{ title: "北门岗亭", detail: "夜班巡更存在 1 次漏巡,需补录。", level: "关注" },
{ title: "监控中心", detail: "3 台摄像头离线超过 2 小时,建议安排检修。", level: "预警" },
{ title: "循环花园一期", detail: "消防演练完成率 100%,建议复盘分享。", level: "正常" }
]
},
customerPortrait: {
eyebrow: "客户运营",
headline: "客户画像",
summary: "整合住户结构、活跃度、工单偏好与缴费行为,替代空态页。",
accent: "#0ea5e9",
accentSoft: "rgba(14, 165, 233, 0.16)",
metrics: [
{ label: "活跃住户", value: "4,286", delta: "月活率 72.4%" },
{ label: "重点客户", value: "126", delta: "需专人跟进" },
{ label: "回访完成", value: "318", delta: "本月回访任务" },
{ label: "满意度均分", value: "4.68", delta: "较上月 +0.05" }
],
trendLabels: ["1周", "2周", "3周", "4周", "5周", "6周"],
trendSeries: [
{ label: "活跃住户数", color: "#0ea5e9", values: [3200, 3380, 3520, 3680, 3890, 4286] },
{ label: "回访完成数", color: "#2fc1a8", values: [102, 136, 181, 224, 276, 318] }
],
segments: [
{ label: "高频互动", value: "34%", tone: "#0ea5e9" },
{ label: "稳定缴费", value: "29%", tone: "#2d76ff" },
{ label: "投诉敏感", value: "18%", tone: "#f59e0b" },
{ label: "沉默住户", value: "19%", tone: "#a78bfa" }
],
rankingTitle: "项目客户运营排行",
rankingRows: [
["循环花园一期", "4.82", "96%"],
["博万物", "4.76", "93%"],
["美好花园", "4.69", "91%"],
["连城花园", "4.58", "88%"]
],
alertsTitle: "客户提示",
alerts: [
{ title: "循环花园一期", detail: "高频投诉用户 3 位,建议安排专属回访。", level: "关注" },
{ title: "博万物", detail: "本月客户活跃度显著提升,可继续推动社群运营。", level: "正常" },
{ title: "美好花园", detail: "沉默住户占比上升,建议补做满意度回访。", level: "预警" }
]
},
energyNotice: {
eyebrow: "能源管理",
headline: "能源看板",
summary: "聚合公共用电、可回收用能和设备能耗等级,替代原始异常文本页。",
accent: "#14b8a6",
accentSoft: "rgba(20, 184, 166, 0.16)",
metrics: [
{ label: "本月用电量", value: "186.4万kWh", delta: "较上月 -4.3%" },
{ label: "减支金额", value: "¥62,878", delta: "节能效果稳定" },
{ label: "增收金额", value: "¥18,620", delta: "可回收能耗贡献" },
{ label: "异常设备", value: "5", delta: "需安排巡检" }
],
trendLabels: ["1周", "2周", "3周", "4周", "5周", "6周"],
trendSeries: [
{ label: "公共用电同比减支", color: "#14b8a6", values: [22, 28, 34, 41, 53, 63] },
{ label: "可回收用电增收", color: "#2d76ff", values: [8, 10, 11, 13, 15, 19] }
],
segments: [
{ label: "公共用电", value: "41%", tone: "#14b8a6" },
{ label: "可回收用电", value: "27%", tone: "#2d76ff" },
{ label: "商铺能耗", value: "19%", tone: "#f59e0b" },
{ label: "多经能耗", value: "13%", tone: "#a78bfa" }
],
rankingTitle: "重点能耗项目",
rankingRows: [
["循环花园一期", "6.45 kWh/㎡", "92%"],
["博万物", "6.58 kWh/㎡", "89%"],
["美好花园", "6.11 kWh/㎡", "91%"],
["连城花园", "6.37 kWh/㎡", "84%"]
],
alertsTitle: "能源提示",
alerts: [
{ title: "公共用电", detail: "连续两周维持减支,建议固化节能策略。", level: "正常" },
{ title: "设备能耗", detail: "5 台高能耗设备需补做专项巡检。", level: "关注" },
{ title: "商铺能耗", detail: "本月波动偏高,建议核查晚间峰值。", level: "预警" }
]
}
};
const HCPOS_STATIC_PAGE_PRESETS = {
childCare: {
eyebrow: "社区服务",
title: "社区幼托运营总览",
summary: "整合托育名额、预约转化、服务满意度与园区联动情况,替代内测提示页。",
accent: "#f97316",
accentSoft: "rgba(249, 115, 22, 0.14)",
cards: [
{ label: "托育名额", value: "128", detail: "本月已使用 94 个" },
{ label: "本月预约", value: "216", detail: "到访转化 43%" },
{ label: "活跃家庭", value: "86", detail: "重复预约率 61%" },
{ label: "满意度", value: "4.81", detail: "家长反馈稳定" }
],
headers: ["项目名称", "服务方案", "开放时段", "本月预约", "到访家庭", "转化率", "负责人"],
rows: [
["循环花园一期", "幼托半日班", "09:00-18:00", "72", "31", "43.1%", "何琳"],
["博万物", "周末托管", "10:00-17:00", "46", "19", "41.3%", "李佑聪"],
["美好花园", "课后看护", "16:00-20:00", "38", "17", "44.7%", "郭晓"],
["连城花园", "假期托育", "09:00-17:30", "34", "13", "38.2%", "曾丽娜"],
["江南世家一期", "亲子陪护", "09:30-18:30", "26", "11", "42.3%", "陈谷先"]
]
},
express: {
eyebrow: "社区服务",
title: "快递收发运营总览",
summary: "聚合收发件量、代收时效与异常包裹,替代内测提示页。",
accent: "#06b6d4",
accentSoft: "rgba(6, 182, 212, 0.14)",
cards: [
{ label: "本日收件", value: "1,286", detail: "较昨日 +8.2%" },
{ label: "本日派件", value: "1,104", detail: "签收率 95.6%" },
{ label: "异常包裹", value: "9", detail: "需人工复核" },
{ label: "平均停留时长", value: "6.4h", detail: "库位周转正常" }
],
headers: ["项目名称", "收件量", "派件量", "异常包裹", "当日签收率", "平均停留时长", "值班人"],
rows: [
["循环花园一期", "342", "301", "2", "96.1%", "5.8h", "林婉"],
["博万物", "286", "244", "1", "95.4%", "6.2h", "何琳"],
["美好花园", "241", "219", "2", "94.8%", "6.9h", "郭晓"],
["连城花园", "218", "197", "2", "95.0%", "6.5h", "周宇"],
["江南世家一期", "199", "143", "2", "94.2%", "6.8h", "陈谷先"]
]
},
house: {
eyebrow: "社区服务",
title: "房屋经纪运营总览",
summary: "展示房源供给、带看转化与签约进展,替代内测提示页。",
accent: "#7c4dff",
accentSoft: "rgba(124, 77, 255, 0.14)",
cards: [
{ label: "在售房源", value: "86", detail: "新增 14 套" },
{ label: "本月带看", value: "214", detail: "意向客户 67 位" },
{ label: "签约套数", value: "12", detail: "转化率 17.9%" },
{ label: "成交额", value: "¥1,286万", detail: "含租售业务" }
],
headers: ["项目名称", "在售房源", "本月带看", "意向客户", "签约套数", "转化率", "经纪人"],
rows: [
["循环花园一期", "24", "61", "18", "4", "22.2%", "李佑聪"],
["博万物", "18", "46", "14", "3", "21.4%", "何琳"],
["美好花园", "15", "38", "12", "2", "16.7%", "郭晓"],
["连城花园", "16", "35", "13", "2", "15.4%", "周宇"],
["江南世家一期", "13", "34", "10", "1", "10.0%", "曾丽娜"]
]
},
housekeeping: {
eyebrow: "社区服务",
title: "社区家政运营总览",
summary: "汇总家政订单、服务评价与排班履约,替代内测提示页。",
accent: "#22c55e",
accentSoft: "rgba(34, 197, 94, 0.14)",
cards: [
{ label: "本月订单", value: "328", detail: "保洁 / 保姆 / 深度清洁" },
{ label: "已服务家庭", value: "246", detail: "复购率 48.8%" },
{ label: "履约率", value: "96.2%", detail: "投诉 3 单" },
{ label: "服务评分", value: "4.83", detail: "口碑稳定" }
],
headers: ["项目名称", "服务类型", "本月订单", "已服务家庭", "履约率", "投诉单", "组长"],
rows: [
["循环花园一期", "日常保洁", "92", "71", "97.8%", "1", "陈谷先"],
["博万物", "深度清洁", "68", "49", "95.1%", "1", "何琳"],
["美好花园", "收纳整理", "54", "41", "96.3%", "0", "郭晓"],
["连城花园", "保姆月嫂", "47", "36", "94.7%", "1", "曾丽娜"],
["江南世家一期", "空房开荒", "41", "29", "96.6%", "0", "周宇"]
]
},
retirement: {
eyebrow: "社区服务",
title: "社区养老运营总览",
summary: "汇总长者服务覆盖、上门关怀和医疗联动,替代内测提示页。",
accent: "#ef4444",
accentSoft: "rgba(239, 68, 68, 0.14)",
cards: [
{ label: "服务长者", value: "214", detail: "高龄长者 38 人" },
{ label: "本月上门关怀", value: "486", detail: "医养联动 62 次" },
{ label: "健康预警", value: "11", detail: "重点跟进对象" },
{ label: "满意度", value: "4.88", detail: "家属反馈良好" }
],
headers: ["项目名称", "服务长者", "本月关怀", "医养联动", "健康预警", "满意度", "负责人"],
rows: [
["循环花园一期", "56", "128", "18", "3", "4.92", "郭晓"],
["博万物", "44", "103", "14", "2", "4.85", "李佑聪"],
["美好花园", "39", "92", "12", "2", "4.81", "何琳"],
["连城花园", "37", "86", "10", "2", "4.79", "曾丽娜"],
["江南世家一期", "38", "77", "8", "2", "4.84", "陈谷先"]
]
},
bankEnterprise: {
eyebrow: "业财税银",
title: "银企直联总览",
summary: "展示银行账户接入、支付通道状态与对账进度,替代空态页。",
accent: "#0ea5e9",
accentSoft: "rgba(14, 165, 233, 0.14)",
cards: [
{ label: "已接银行账户", value: "18", detail: "覆盖 9 个项目" },
{ label: "本月支付笔数", value: "1,286", detail: "对账完成 96.8%" },
{ label: "待处理回单", value: "12", detail: "需财务复核" },
{ label: "支付成功率", value: "99.2%", detail: "通道状态稳定" }
],
headers: ["项目名称", "开户行", "账户类型", "本月支付笔数", "支付金额", "对账完成率", "状态"],
rows: [
["循环花园一期", "中国银行", "基本户", "286", "¥684,200", "98.6%", "正常"],
["博万物", "建设银行", "一般户", "241", "¥512,800", "96.2%", "正常"],
["美好花园", "工商银行", "基本户", "214", "¥468,600", "95.8%", "正常"],
["连城花园", "农业银行", "一般户", "198", "¥392,400", "94.7%", "待复核"],
["江南世家一期", "招商银行", "基本户", "173", "¥318,900", "97.9%", "正常"]
]
},
financialAccount: {
eyebrow: "业财税银",
title: "财务核算总览",
summary: "展示核算主体、账套状态与月度结账进度,替代空态页。",
accent: "#8b5cf6",
accentSoft: "rgba(139, 92, 246, 0.14)",
cards: [
{ label: "核算主体", value: "11", detail: "账套均在线" },
{ label: "本月结账率", value: "81.8%", detail: "9/11 主体已完成" },
{ label: "待审核凭证", value: "42", detail: "需本周内清理" },
{ label: "异常科目", value: "6", detail: "需复核映射关系" }
],
headers: ["项目名称", "核算主体", "账套状态", "本月凭证数", "待审核凭证", "结账进度", "负责人"],
rows: [
["循环花园一期", "循环花园物业服务主体", "正常", "128", "6", "100%", "陈谷先"],
["博万物", "博万物运营主体", "正常", "116", "8", "92%", "何琳"],
["美好花园", "美好花园服务主体", "正常", "104", "9", "88%", "郭晓"],
["连城花园", "连城花园管理主体", "关注", "97", "11", "74%", "曾丽娜"],
["江南世家一期", "江南世家服务主体", "正常", "82", "8", "79%", "周宇"]
]
},
financialVoucher: {
eyebrow: "业财税银",
title: "财务凭证总览",
summary: "汇总月度凭证流转、审核效率与异常凭证,替代空态页。",
accent: "#f97316",
accentSoft: "rgba(249, 115, 22, 0.14)",
cards: [
{ label: "本月凭证", value: "468", detail: "自动生成占比 62%" },
{ label: "已审核", value: "426", detail: "审核率 91.0%" },
{ label: "异常凭证", value: "14", detail: "需人工校正" },
{ label: "平均审核时长", value: "3.2h", detail: "较上月 -0.6h" }
],
headers: ["项目名称", "本月凭证", "自动生成", "已审核", "异常凭证", "审核率", "平均审核时长"],
rows: [
["循环花园一期", "112", "74", "106", "2", "94.6%", "2.6h"],
["博万物", "98", "63", "89", "4", "90.8%", "3.1h"],
["美好花园", "91", "58", "82", "3", "90.1%", "3.4h"],
["连城花园", "86", "52", "75", "3", "87.2%", "3.8h"],
["江南世家一期", "81", "43", "74", "2", "91.4%", "3.0h"]
]
},
taxCoordination: {
eyebrow: "业财税银",
title: "税务统筹总览",
summary: "展示申报进度、风险事项与税负变化,替代空态页。",
accent: "#ef4444",
accentSoft: "rgba(239, 68, 68, 0.14)",
cards: [
{ label: "本月申报主体", value: "11", detail: "已申报 9 个" },
{ label: "税负率", value: "5.86%", detail: "较上月 -0.22%" },
{ label: "风险事项", value: "4", detail: "逾期 0 项" },
{ label: "待补资料", value: "7", detail: "需市场侧配合" }
],
headers: ["项目名称", "申报状态", "本月税额", "税负率", "风险事项", "待补资料", "负责人"],
rows: [
["循环花园一期", "已申报", "¥82,400", "5.42%", "0", "1", "陈谷先"],
["博万物", "已申报", "¥74,800", "5.91%", "1", "2", "何琳"],
["美好花园", "已申报", "¥68,200", "5.76%", "1", "1", "郭晓"],
["连城花园", "待复核", "¥63,900", "6.11%", "1", "2", "曾丽娜"],
["江南世家一期", "已申报", "¥58,700", "6.03%", "1", "1", "周宇"]
]
},
serviceProvider: {
eyebrow: "社区治理",
title: "服务商管理总览",
summary: "汇总服务商覆盖、合作状态与履约评分,替代空态页。",
accent: "#14b8a6",
accentSoft: "rgba(20, 184, 166, 0.14)",
cards: [
{ label: "合作服务商", value: "42", detail: "有效合作 36 家" },
{ label: "本月履约率", value: "92.6%", detail: "较上月 +1.7%" },
{ label: "待签约", value: "5", detail: "需合同跟进" },
{ label: "平均评分", value: "4.74", detail: "投诉 2 单" }
],
headers: ["项目名称", "服务商", "服务类型", "合作状态", "履约评分", "本月工单", "负责人"],
rows: [
["循环花园一期", "星河保洁服务有限公司", "保洁服务", "合作中", "4.92", "86", "郭晓"],
["博万物", "万嘉设备维保有限公司", "设备维保", "合作中", "4.81", "72", "何琳"],
["美好花园", "城安安防科技有限公司", "安防服务", "合作中", "4.73", "64", "李佑聪"],
["连城花园", "绿景园林服务有限公司", "园林养护", "待续签", "4.66", "58", "曾丽娜"],
["江南世家一期", "社邻家政服务有限公司", "社区家政", "待签约", "4.58", "41", "陈谷先"]
]
},
cleanAssessmentTraining: {
eyebrow: "清洁管理",
title: "清洁考核培训总览",
summary: "汇总保洁班组培训计划、考核得分与复训状态,替代空态页。",
accent: "#06b6d4",
accentSoft: "rgba(6, 182, 212, 0.14)",
cards: [
{ label: "培训计划", value: "42", detail: "本月新增 6 场" },
{ label: "参训人数", value: "186", detail: "到课率 94.1%" },
{ label: "平均得分", value: "88.6", detail: "高于目标线" },
{ label: "待复训", value: "8", detail: "需下周安排" }
],
headers: ["项目名称", "培训主题", "参训人数", "考核得分", "复训状态", "负责人"],
rows: [
["循环花园一期", "夜间保洁标准化", "36", "92.4", "已完成", "郭晓"],
["博万物", "地下车库清洁规范", "28", "88.1", "待复训", "何琳"],
["美好花园", "垃圾分类流程", "31", "87.6", "已完成", "曾丽娜"],
["连城花园", "专项清洁作业", "24", "84.9", "进行中", "周宇"],
["江南世家一期", "应急保洁演练", "19", "89.3", "已完成", "陈谷先"]
]
},
cleanSpareParts: {
eyebrow: "清洁管理",
title: "清洁备品备件总览",
summary: "展示清洁耗材库存、补货周期与异常库存,替代空态页。",
accent: "#22c55e",
accentSoft: "rgba(34, 197, 94, 0.14)",
cards: [
{ label: "SKU 数量", value: "86", detail: "低库存 7 项" },
{ label: "本月领用", value: "¥38,600", detail: "较上月 -3.8%" },
{ label: "待补货", value: "12", detail: "3 项紧急" },
{ label: "周转天数", value: "18.4", detail: "库存结构稳定" }
],
headers: ["项目名称", "物料名称", "库存数量", "月消耗", "安全库存", "状态", "库管员"],
rows: [
["循环花园一期", "清洁剂", "128", "36", "80", "正常", "郭晓"],
["博万物", "垃圾袋", "92", "48", "60", "关注", "何琳"],
["美好花园", "拖布头", "74", "22", "40", "正常", "曾丽娜"],
["连城花园", "消毒液", "38", "19", "30", "预警", "周宇"],
["江南世家一期", "尘推布", "56", "18", "32", "正常", "陈谷先"]
]
},
elevatorAssessmentTraining: {
eyebrow: "电梯管理",
title: "电梯考核培训总览",
summary: "汇总维保培训、困人演练与考核得分,替代空态页。",
accent: "#7c3aed",
accentSoft: "rgba(124, 58, 237, 0.14)",
cards: [
{ label: "培训批次", value: "18", detail: "季度滚动计划" },
{ label: "参训人数", value: "74", detail: "到课率 96.2%" },
{ label: "演练通过率", value: "93.4%", detail: "困人演练良好" },
{ label: "待复训", value: "4", detail: "新员工为主" }
],
headers: ["项目名称", "培训主题", "参训人数", "得分", "演练结果", "负责人"],
rows: [
["循环花园一期", "困人救援演练", "18", "94.8", "通过", "何琳"],
["博万物", "年检流程培训", "12", "91.2", "通过", "郭晓"],
["美好花园", "维保质量复训", "14", "89.6", "待复训", "曾丽娜"],
["连城花园", "设备安全管理", "11", "87.3", "通过", "周宇"],
["江南世家一期", "电梯巡检规范", "9", "92.4", "通过", "陈谷先"]
]
},
elevatorSpareParts: {
eyebrow: "电梯管理",
title: "电梯备品备件总览",
summary: "展示电梯备件库存、使用频率与关键缺件,替代空态页。",
accent: "#f59e0b",
accentSoft: "rgba(245, 158, 11, 0.14)",
cards: [
{ label: "备件种类", value: "54", detail: "关键件 12 类" },
{ label: "本月领用", value: "32", detail: "较上月 +4" },
{ label: "低库存", value: "6", detail: "需本周补货" },
{ label: "完好率", value: "97.1%", detail: "仓储正常" }
],
headers: ["项目名称", "备件名称", "库存数量", "月领用", "安全库存", "状态", "库管员"],
rows: [
["循环花园一期", "门机皮带", "24", "6", "12", "正常", "何琳"],
["博万物", "层门锁触点", "18", "4", "10", "正常", "郭晓"],
["美好花园", "按钮面板", "9", "3", "8", "关注", "曾丽娜"],
["连城花园", "轿厢风扇", "6", "2", "6", "预警", "周宇"],
["江南世家一期", "编码器", "11", "1", "5", "正常", "陈谷先"]
]
},
equipmentAssessmentTraining: {
eyebrow: "设备管理",
title: "设备考核培训总览",
summary: "汇总设备维保培训、巡检演练与得分,替代空态页。",
accent: "#00a870",
accentSoft: "rgba(0, 168, 112, 0.14)",
cards: [
{ label: "培训场次", value: "26", detail: "覆盖 8 类设备" },
{ label: "参训人数", value: "96", detail: "到课率 95.3%" },
{ label: "平均得分", value: "90.8", detail: "维保体系稳定" },
{ label: "待整改项", value: "7", detail: "需复盘" }
],
headers: ["项目名称", "培训主题", "参训人数", "得分", "整改项", "负责人"],
rows: [
["循环花园一期", "消防系统培训", "22", "93.1", "1", "何琳"],
["博万物", "供配电巡检培训", "18", "90.4", "2", "郭晓"],
["美好花园", "泵房维护复训", "17", "89.6", "1", "曾丽娜"],
["连城花园", "弱电设备培训", "14", "88.8", "2", "周宇"],
["江南世家一期", "设施保养培训", "13", "92.0", "1", "陈谷先"]
]
},
equipmentSpareParts: {
eyebrow: "设备管理",
title: "设备备品备件总览",
summary: "展示设备备件库存、消耗与缺件预警,替代空态页。",
accent: "#2d76ff",
accentSoft: "rgba(45, 118, 255, 0.14)",
cards: [
{ label: "备件种类", value: "138", detail: "关键件 28 类" },
{ label: "本月消耗", value: "¥46,200", detail: "较上月 -2.7%" },
{ label: "低库存", value: "11", detail: "紧急 3 项" },
{ label: "完好率", value: "96.4%", detail: "库存状态可控" }
],
headers: ["项目名称", "备件名称", "库存数量", "月消耗", "安全库存", "状态", "库管员"],
rows: [
["循环花园一期", "消防探测器", "62", "18", "30", "正常", "何琳"],
["博万物", "压力开关", "41", "12", "20", "正常", "郭晓"],
["美好花园", "接触器", "24", "8", "12", "关注", "曾丽娜"],
["连城花园", "轴承组件", "17", "6", "10", "正常", "周宇"],
["江南世家一期", "信号模块", "9", "4", "8", "预警", "陈谷先"]
]
},
greenAssessmentTraining: {
eyebrow: "绿化管理",
title: "绿化考核培训总览",
summary: "汇总绿化养护培训、病虫害演练与考核得分,替代空态页。",
accent: "#22c55e",
accentSoft: "rgba(34, 197, 94, 0.14)",
cards: [
{ label: "培训场次", value: "21", detail: "覆盖 6 类养护主题" },
{ label: "参训人数", value: "84", detail: "到课率 93.8%" },
{ label: "平均得分", value: "89.2", detail: "高于月目标" },
{ label: "待复训", value: "5", detail: "多为新员工" }
],
headers: ["项目名称", "培训主题", "参训人数", "得分", "复训状态", "负责人"],
rows: [
["循环花园一期", "乔木修剪规范", "18", "91.4", "已完成", "郭晓"],
["博万物", "病虫害识别", "16", "88.9", "待复训", "何琳"],
["美好花园", "草坪养护标准", "15", "90.2", "已完成", "曾丽娜"],
["连城花园", "季节性补植培训", "13", "87.3", "进行中", "周宇"],
["江南世家一期", "灌溉系统操作", "11", "88.1", "已完成", "陈谷先"]
]
},
greenSpareParts: {
eyebrow: "绿化管理",
title: "绿化备品备件总览",
summary: "展示绿化工具、药剂和补植物资库存,替代空态页。",
accent: "#84cc16",
accentSoft: "rgba(132, 204, 22, 0.14)",
cards: [
{ label: "物资种类", value: "72", detail: "关键项 14 类" },
{ label: "本月消耗", value: "¥24,800", detail: "较上月 +3.2%" },
{ label: "低库存", value: "9", detail: "需补货 2 项" },
{ label: "完好率", value: "95.2%", detail: "仓储正常" }
],
headers: ["项目名称", "物资名称", "库存数量", "月消耗", "安全库存", "状态", "库管员"],
rows: [
["循环花园一期", "复合肥", "48", "12", "20", "正常", "郭晓"],
["博万物", "修剪刀", "26", "6", "10", "正常", "何琳"],
["美好花园", "杀菌剂", "18", "5", "8", "关注", "曾丽娜"],
["连城花园", "草籽", "12", "4", "6", "预警", "周宇"],
["江南世家一期", "滴灌接头", "24", "3", "10", "正常", "陈谷先"]
]
},
securityAssessmentTraining: {
eyebrow: "安防管理",
title: "安防考核培训总览",
summary: "汇总巡更、门岗和值守演练培训,替代空态页。",
accent: "#ef4444",
accentSoft: "rgba(239, 68, 68, 0.14)",
cards: [
{ label: "培训批次", value: "24", detail: "本月滚动培训" },
{ label: "参训人数", value: "102", detail: "到课率 95.1%" },
{ label: "平均得分", value: "91.3", detail: "安防体系稳定" },
{ label: "待复训", value: "6", detail: "夜班岗为主" }
],
headers: ["项目名称", "培训主题", "参训人数", "得分", "复训状态", "负责人"],
rows: [
["循环花园一期", "门岗值守规范", "22", "93.5", "已完成", "何琳"],
["博万物", "监控巡检流程", "19", "90.4", "进行中", "郭晓"],
["美好花园", "消防联动演练", "18", "92.1", "已完成", "曾丽娜"],
["连城花园", "夜间巡更培训", "16", "88.8", "待复训", "周宇"],
["江南世家一期", "突发事件上报", "14", "91.7", "已完成", "陈谷先"]
]
},
securitySpareParts: {
eyebrow: "安防管理",
title: "安防备品备件总览",
summary: "展示安防设备备件、耗材和缺件预警,替代空态页。",
accent: "#f43f5e",
accentSoft: "rgba(244, 63, 94, 0.14)",
cards: [
{ label: "备件种类", value: "66", detail: "摄像头 / 门禁 / 对讲" },
{ label: "本月消耗", value: "¥31,400", detail: "较上月 +1.6%" },
{ label: "低库存", value: "8", detail: "紧急 2 项" },
{ label: "完好率", value: "97.8%", detail: "库存状态可控" }
],
headers: ["项目名称", "备件名称", "库存数量", "月消耗", "安全库存", "状态", "库管员"],
rows: [
["循环花园一期", "摄像头模组", "34", "8", "12", "正常", "何琳"],
["博万物", "门禁卡", "186", "42", "80", "正常", "郭晓"],
["美好花园", "对讲电源", "16", "4", "8", "关注", "曾丽娜"],
["连城花园", "硬盘录像机盘位", "7", "2", "5", "预警", "周宇"],
["江南世家一期", "报警探测器", "22", "6", "10", "正常", "陈谷先"]
]
},
parkingAssessmentTraining: {
eyebrow: "车场管理",
title: "车场考核培训总览",
summary: "汇总车场收费、道闸处理和现场演练培训,替代空态页。",
accent: "#7c4dff",
accentSoft: "rgba(124, 77, 255, 0.14)",
cards: [
{ label: "培训批次", value: "16", detail: "收费岗与巡查岗" },
{ label: "参训人数", value: "58", detail: "到课率 96.7%" },
{ label: "平均得分", value: "90.1", detail: "车场运营稳定" },
{ label: "待复训", value: "3", detail: "新岗补训" }
],
headers: ["项目名称", "培训主题", "参训人数", "得分", "复训状态", "负责人"],
rows: [
["循环花园一期", "道闸异常处理", "14", "92.6", "已完成", "何琳"],
["博万物", "收费岗交接培训", "12", "89.7", "已完成", "郭晓"],
["美好花园", "夜间来访登记", "11", "88.4", "待复训", "曾丽娜"],
["连城花园", "车牌识别演练", "10", "90.8", "已完成", "周宇"],
["江南世家一期", "临停收费规范", "11", "89.0", "进行中", "陈谷先"]
]
},
balanceSheet: {
eyebrow: "财务报表",
title: "资产负债表总览",
summary: "基于镜像静态样本重建资产、负债与净资产概览,替代空态页。",
accent: "#2d76ff",
accentSoft: "rgba(45, 118, 255, 0.14)",
cards: [
{ label: "资产总计", value: "¥8,426,000", detail: "较年初 +6.8%" },
{ label: "负债合计", value: "¥3,286,000", detail: "负债率 39.0%" },
{ label: "所有者权益", value: "¥5,140,000", detail: "权益结构稳定" },
{ label: "流动比率", value: "1.92", detail: "短期偿债正常" }
],
headers: ["项目名称", "流动资产", "非流动资产", "资产总计", "流动负债", "非流动负债", "负债合计", "所有者权益"],
rows: [
["循环花园一期", "¥1,286,000", "¥842,000", "¥2,128,000", "¥624,000", "¥182,000", "¥806,000", "¥1,322,000"],
["博万物", "¥1,164,000", "¥736,000", "¥1,900,000", "¥592,000", "¥168,000", "¥760,000", "¥1,140,000"],
["美好花园", "¥1,082,000", "¥704,000", "¥1,786,000", "¥548,000", "¥154,000", "¥702,000", "¥1,084,000"],
["连城花园", "¥968,000", "¥642,000", "¥1,610,000", "¥486,000", "¥136,000", "¥622,000", "¥988,000"],
["江南世家一期", "¥594,000", "¥408,000", "¥1,002,000", "¥284,000", "¥112,000", "¥396,000", "¥606,000"]
]
},
cashFlowStatement: {
eyebrow: "财务报表",
title: "现金流量表总览",
summary: "重建经营、投资、筹资现金流概览,替代空态页。",
accent: "#14b8a6",
accentSoft: "rgba(20, 184, 166, 0.14)",
cards: [
{ label: "经营净现金流", value: "¥1,286,000", detail: "核心业务稳定" },
{ label: "投资净现金流", value: "-¥326,000", detail: "设备投入增加" },
{ label: "筹资净现金流", value: "¥182,000", detail: "贷款偿付平稳" },
{ label: "现金净增加额", value: "¥1,142,000", detail: "资金安全" }
],
headers: ["项目名称", "经营现金流入", "经营现金流出", "经营净现金流", "投资净现金流", "筹资净现金流", "现金净增加额"],
rows: [
["循环花园一期", "¥2,486,000", "¥1,618,000", "¥868,000", "-¥126,000", "¥52,000", "¥794,000"],
["博万物", "¥2,084,000", "¥1,428,000", "¥656,000", "-¥94,000", "¥48,000", "¥610,000"],
["美好花园", "¥1,876,000", "¥1,294,000", "¥582,000", "-¥72,000", "¥36,000", "¥546,000"],
["连城花园", "¥1,624,000", "¥1,142,000", "¥482,000", "-¥21,000", "¥28,000", "¥489,000"],
["江南世家一期", "¥1,208,000", "¥962,000", "¥246,000", "-¥13,000", "¥18,000", "¥251,000"]
]
},
incomeStatement: {
eyebrow: "财务报表",
title: "全年收入报表总览",
summary: "按项目汇总收入、成本、毛利与净利,替代空态页。",
accent: "#22c55e",
accentSoft: "rgba(34, 197, 94, 0.14)",
cards: [
{ label: "全年收入", value: "¥12,680,000", detail: "较上年 +9.4%" },
{ label: "营业成本", value: "¥8,940,000", detail: "成本率 70.5%" },
{ label: "毛利润", value: "¥3,740,000", detail: "毛利率 29.5%" },
{ label: "净利润", value: "¥2,286,000", detail: "净利率 18.0%" }
],
headers: ["项目名称", "全年收入", "营业成本", "毛利润", "管理费用", "净利润", "净利率"],
rows: [
["循环花园一期", "¥3,186,000", "¥2,186,000", "¥1,000,000", "¥318,000", "¥642,000", "20.2%"],
["博万物", "¥2,648,000", "¥1,862,000", "¥786,000", "¥264,000", "¥486,000", "18.4%"],
["美好花园", "¥2,214,000", "¥1,614,000", "¥600,000", "¥208,000", "¥356,000", "16.1%"],
["连城花园", "¥1,986,000", "¥1,434,000", "¥552,000", "¥186,000", "¥318,000", "16.0%"],
["江南世家一期", "¥1,646,000", "¥1,132,000", "¥514,000", "¥148,000", "¥284,000", "17.3%"]
]
},
profitSurface: {
eyebrow: "财务报表",
title: "利润表总览",
summary: "按项目展示利润结构、费用与利润率,替代空态页。",
accent: "#f97316",
accentSoft: "rgba(249, 115, 22, 0.14)",
cards: [
{ label: "营业利润", value: "¥2,948,000", detail: "较上月 +5.3%" },
{ label: "利润率", value: "23.2%", detail: "经营状态良好" },
{ label: "费用率", value: "9.6%", detail: "可继续优化" },
{ label: "亏损项目", value: "0", detail: "本月无亏损项目" }
],
headers: ["项目名称", "营业收入", "营业成本", "销售费用", "管理费用", "营业利润", "利润率"],
rows: [
["循环花园一期", "¥1,286,000", "¥824,000", "¥42,000", "¥86,000", "¥334,000", "26.0%"],
["博万物", "¥1,084,000", "¥712,000", "¥38,000", "¥74,000", "¥260,000", "24.0%"],
["美好花园", "¥986,000", "¥664,000", "¥32,000", "¥68,000", "¥222,000", "22.5%"],
["连城花园", "¥842,000", "¥598,000", "¥28,000", "¥61,000", "¥155,000", "18.4%"],
["江南世家一期", "¥714,000", "¥486,000", "¥21,000", "¥48,000", "¥159,000", "22.3%"]
]
},
projectIncome: {
eyebrow: "财务报表",
title: "项目收支表总览",
summary: "聚合项目收入、支出、预算执行与收支结余,替代空态页。",
accent: "#8b5cf6",
accentSoft: "rgba(139, 92, 246, 0.14)",
cards: [
{ label: "项目收入", value: "¥8,864,000", detail: "本月累计" },
{ label: "项目支出", value: "¥6,428,000", detail: "预算执行 91.2%" },
{ label: "收支结余", value: "¥2,436,000", detail: "结余率 27.5%" },
{ label: "超预算项目", value: "3", detail: "需专项复盘" }
],
headers: ["项目名称", "项目收入", "项目支出", "收支结余", "预算执行率", "本月回款", "超预算项"],
rows: [
["循环花园一期", "¥2,186,000", "¥1,548,000", "¥638,000", "92.4%", "¥246,000", "0"],
["博万物", "¥1,946,000", "¥1,382,000", "¥564,000", "89.8%", "¥214,000", "1"],
["美好花园", "¥1,782,000", "¥1,296,000", "¥486,000", "90.6%", "¥198,000", "1"],
["连城花园", "¥1,612,000", "¥1,168,000", "¥444,000", "91.1%", "¥176,000", "0"],
["江南世家一期", "¥1,338,000", "¥1,034,000", "¥304,000", "93.5%", "¥152,000", "1"]
]
}
};
const HCPOS_FINANCE_REPORT_PRESETS = {
balanceSheet: {
eyebrow: "财务报表",
title: "资产负债表总览",
summary: "基于镜像静态样本重建资产、负债与净资产概览,替代空态页。",
accent: "#2d76ff",
accentSoft: "rgba(45, 118, 255, 0.14)",
cards: [
{ label: "资产总计", value: "¥8,426,000", detail: "较年初 +6.8%" },
{ label: "负债合计", value: "¥3,286,000", detail: "负债率 39.0%" },
{ label: "所有者权益", value: "¥5,140,000", detail: "权益结构稳定" },
{ label: "流动比率", value: "1.92", detail: "短期偿债正常" }
],
headers: ["项目名称", "流动资产", "非流动资产", "资产总计", "流动负债", "非流动负债", "负债合计", "所有者权益"],
rows: [
["循环花园一期", "¥1,286,000", "¥842,000", "¥2,128,000", "¥624,000", "¥182,000", "¥806,000", "¥1,322,000"],
["博万物", "¥1,164,000", "¥736,000", "¥1,900,000", "¥592,000", "¥168,000", "¥760,000", "¥1,140,000"],
["美好花园", "¥1,082,000", "¥704,000", "¥1,786,000", "¥548,000", "¥154,000", "¥702,000", "¥1,084,000"],
["连城花园", "¥968,000", "¥642,000", "¥1,610,000", "¥486,000", "¥136,000", "¥622,000", "¥988,000"],
["江南世家一期", "¥594,000", "¥408,000", "¥1,002,000", "¥284,000", "¥112,000", "¥396,000", "¥606,000"]
]
},
cashFlowStatement: {
eyebrow: "财务报表",
title: "现金流量表总览",
summary: "重建经营、投资、筹资现金流概览,替代空态页。",
accent: "#14b8a6",
accentSoft: "rgba(20, 184, 166, 0.14)",
cards: [
{ label: "经营净现金流", value: "¥1,286,000", detail: "核心业务稳定" },
{ label: "投资净现金流", value: "-¥326,000", detail: "设备投入增加" },
{ label: "筹资净现金流", value: "¥182,000", detail: "贷款偿付平稳" },
{ label: "现金净增加额", value: "¥1,142,000", detail: "资金安全" }
],
headers: ["项目名称", "经营现金流入", "经营现金流出", "经营净现金流", "投资净现金流", "筹资净现金流", "现金净增加额"],
rows: [
["循环花园一期", "¥2,486,000", "¥1,618,000", "¥868,000", "-¥126,000", "¥52,000", "¥794,000"],
["博万物", "¥2,084,000", "¥1,428,000", "¥656,000", "-¥94,000", "¥48,000", "¥610,000"],
["美好花园", "¥1,876,000", "¥1,294,000", "¥582,000", "-¥72,000", "¥36,000", "¥546,000"],
["连城花园", "¥1,624,000", "¥1,142,000", "¥482,000", "-¥21,000", "¥28,000", "¥489,000"],
["江南世家一期", "¥1,208,000", "¥962,000", "¥246,000", "-¥13,000", "¥18,000", "¥251,000"]
]
},
incomeStatement: {
eyebrow: "财务报表",
title: "全年收入报表总览",
summary: "按项目汇总收入、成本、毛利与净利,替代空态页。",
accent: "#22c55e",
accentSoft: "rgba(34, 197, 94, 0.14)",
cards: [
{ label: "全年收入", value: "¥12,680,000", detail: "较上年 +9.4%" },
{ label: "营业成本", value: "¥8,940,000", detail: "成本率 70.5%" },
{ label: "毛利润", value: "¥3,740,000", detail: "毛利率 29.5%" },
{ label: "净利润", value: "¥2,286,000", detail: "净利率 18.0%" }
],
headers: ["项目名称", "全年收入", "营业成本", "毛利润", "管理费用", "净利润", "净利率"],
rows: [
["循环花园一期", "¥3,186,000", "¥2,186,000", "¥1,000,000", "¥318,000", "¥642,000", "20.2%"],
["博万物", "¥2,648,000", "¥1,862,000", "¥786,000", "¥264,000", "¥486,000", "18.4%"],
["美好花园", "¥2,214,000", "¥1,614,000", "¥600,000", "¥208,000", "¥356,000", "16.1%"],
["连城花园", "¥1,986,000", "¥1,434,000", "¥552,000", "¥186,000", "¥318,000", "16.0%"],
["江南世家一期", "¥1,646,000", "¥1,132,000", "¥514,000", "¥148,000", "¥284,000", "17.3%"]
]
},
profitSurface: {
eyebrow: "财务报表",
title: "利润表总览",
summary: "按项目展示利润结构、费用与利润率,替代空态页。",
accent: "#f97316",
accentSoft: "rgba(249, 115, 22, 0.14)",
cards: [
{ label: "营业利润", value: "¥2,948,000", detail: "较上月 +5.3%" },
{ label: "利润率", value: "23.2%", detail: "经营状态良好" },
{ label: "费用率", value: "9.6%", detail: "可继续优化" },
{ label: "亏损项目", value: "0", detail: "本月无亏损项目" }
],
headers: ["项目名称", "营业收入", "营业成本", "销售费用", "管理费用", "营业利润", "利润率"],
rows: [
["循环花园一期", "¥1,286,000", "¥824,000", "¥42,000", "¥86,000", "¥334,000", "26.0%"],
["博万物", "¥1,084,000", "¥712,000", "¥38,000", "¥74,000", "¥260,000", "24.0%"],
["美好花园", "¥986,000", "¥664,000", "¥32,000", "¥68,000", "¥222,000", "22.5%"],
["连城花园", "¥842,000", "¥598,000", "¥28,000", "¥61,000", "¥155,000", "18.4%"],
["江南世家一期", "¥714,000", "¥486,000", "¥21,000", "¥48,000", "¥159,000", "22.3%"]
]
},
projectIncome: {
eyebrow: "财务报表",
title: "项目收支表总览",
summary: "聚合项目收入、支出、预算执行与收支结余,替代空态页。",
accent: "#8b5cf6",
accentSoft: "rgba(139, 92, 246, 0.14)",
cards: [
{ label: "项目收入", value: "¥8,864,000", detail: "本月累计" },
{ label: "项目支出", value: "¥6,428,000", detail: "预算执行 91.2%" },
{ label: "收支结余", value: "¥2,436,000", detail: "结余率 27.5%" },
{ label: "超预算项目", value: "3", detail: "需专项复盘" }
],
headers: ["项目名称", "项目收入", "项目支出", "收支结余", "预算执行率", "本月回款", "超预算项"],
rows: [
["循环花园一期", "¥2,186,000", "¥1,548,000", "¥638,000", "92.4%", "¥246,000", "0"],
["博万物", "¥1,946,000", "¥1,382,000", "¥564,000", "89.8%", "¥214,000", "1"],
["美好花园", "¥1,782,000", "¥1,296,000", "¥486,000", "90.6%", "¥198,000", "1"],
["连城花园", "¥1,612,000", "¥1,168,000", "¥444,000", "91.1%", "¥176,000", "0"],
["江南世家一期", "¥1,338,000", "¥1,034,000", "¥304,000", "93.5%", "¥152,000", "1"]
]
}
};
function buildHcPosSoftAccent(hex, alpha) {
const normalized = (hex || "").replace("#", "");
const full = normalized.length === 3 ? normalized.split("").map((item) => `${item}${item}`).join("") : normalized;
const value = Number.parseInt(full || "2d76ff", 16);
const r = value >> 16 & 255;
const g = value >> 8 & 255;
const b = value & 255;
return `rgba(${r}, ${g}, ${b}, ${alpha})`;
}
function createHcPosStaticPreset(preset) {
return {
...preset,
accentSoft: preset.accentSoft || buildHcPosSoftAccent(preset.accent || "#2d76ff", 0.14)
};
}
const HCPOS_WAIT_PAGE_PRESETS = {
earlyPartnership: createHcPosStaticPreset({
eyebrow: "前介管理",
title: "入伙管理总览",
summary: "汇总入伙交付、钥匙移交与缺陷闭环,替代等待页。",
accent: "#2d76ff",
cards: [
{ label: "待交付楼栋", value: "6", detail: "本月计划 3 栋" },
{ label: "已验房户数", value: "186", detail: "完成率 92.5%" },
{ label: "钥匙移交", value: "172", detail: "待领取 14 户" },
{ label: "整改闭环", value: "94.1%", detail: "遗留缺陷 11 项" }
],
headers: ["项目名称", "楼栋", "本周交付", "钥匙移交", "整改闭环", "负责人"],
rows: [
["循环花园一期", "1-3 栋", "42 户", "39 户", "96%", "郭晓"],
["博万物", "A/B 座", "31 户", "28 户", "92%", "何琳"],
["江南世家一期", "5-6 栋", "26 户", "24 户", "89%", "陈谷先"]
]
}),
earlySalesCooperation: createHcPosStaticPreset({
eyebrow: "前介管理",
title: "售楼配合总览",
summary: "展示样板间巡检、看房接待与销售协同进度,替代等待页。",
accent: "#14b8a6",
cards: [
{ label: "本周接待", value: "128", detail: "到访转化 37.5%" },
{ label: "样板间巡检", value: "42", detail: "问题已闭环 38 项" },
{ label: "销售协同单", value: "23", detail: "超时 2 单" },
{ label: "满意度", value: "4.86", detail: "客户反馈稳定" }
],
headers: ["项目名称", "配合场景", "本周接待", "协同事项", "闭环率", "接口人"],
rows: [
["循环花园一期", "样板间接待", "48", "9", "100%", "郭晓"],
["博万物", "销售说辞配合", "36", "8", "87%", "何琳"],
["江南世家一期", "交付展示支持", "22", "6", "83%", "陈谷先"]
]
}),
earlyUndertakeInspection: createHcPosStaticPreset({
eyebrow: "前介管理",
title: "承接查验总览",
summary: "汇总查验批次、问题整改与移交节点,替代等待页。",
accent: "#8b5cf6",
cards: [
{ label: "查验批次", value: "18", detail: "本月新增 4 批" },
{ label: "查验问题", value: "126", detail: "已闭环 109 项" },
{ label: "待移交区域", value: "5", detail: "涉及公区与设备房" },
{ label: "闭环率", value: "86.5%", detail: "重点问题 7 项" }
],
headers: ["项目名称", "查验区域", "问题总数", "已闭环", "待移交", "负责人"],
rows: [
["循环花园一期", "公区楼栋", "46", "41", "1", "郭晓"],
["博万物", "地下车库", "38", "31", "2", "何琳"],
["江南世家一期", "设备机房", "27", "22", "2", "陈谷先"]
]
}),
elevatorYearly: createHcPosStaticPreset({
eyebrow: "电梯管理",
title: "电梯年检总览",
summary: "汇总年检到期、检验状态与整改进度,替代等待页。",
accent: "#7c3aed",
cards: [
{ label: "年检设备", value: "48", detail: "30 天内到期 9 台" },
{ label: "已送检", value: "39", detail: "通过率 91.7%" },
{ label: "待整改", value: "6", detail: "均已派单" },
{ label: "复检排期", value: "3", detail: "本周完成" }
],
headers: ["项目名称", "设备编号", "年检到期", "检验状态", "整改项", "维保单位"],
rows: [
["循环花园一期", "DT-01", "2026-04-18", "已通过", "0", "万嘉电梯"],
["博万物", "DT-11", "2026-04-22", "整改中", "2", "城安机电"],
["江南世家一期", "DT-07", "2026-04-29", "待送检", "1", "华升特设"]
]
}),
energyMeterReadingCharge: createHcPosStaticPreset({
eyebrow: "能源管控",
title: "抄表收费总览",
summary: "展示抄表户数、收费金额与收缴进度,替代等待页。",
accent: "#0ea5e9",
cards: [
{ label: "抄表户数", value: "1,286", detail: "本月完成率 97.3%" },
{ label: "应收金额", value: "¥482,600", detail: "已收 91.2%" },
{ label: "待复核账单", value: "12", detail: "集中在商铺户" },
{ label: "异常读数", value: "5", detail: "已转人工核查" }
],
headers: ["项目名称", "抄表户数", "应收金额", "已收金额", "收缴率", "负责人"],
rows: [
["循环花园一期", "386", "¥146,800", "¥138,900", "94.6%", "郭晓"],
["博万物", "312", "¥118,600", "¥106,200", "89.5%", "何琳"],
["江南世家一期", "241", "¥86,300", "¥79,400", "92.0%", "陈谷先"]
]
}),
equipmentEnergySaving: createHcPosStaticPreset({
eyebrow: "设备管理",
title: "节能降耗总览",
summary: "聚合设备节电措施、节能收益与异常耗能点位,替代等待页。",
accent: "#22c55e",
cards: [
{ label: "节能项目", value: "27", detail: "覆盖泵房 / 照明 / 风机" },
{ label: "本月节电", value: "18.4万kWh", detail: "同比下降 6.2%" },
{ label: "节能收益", value: "¥74,200", detail: "成本持续下降" },
{ label: "异常点位", value: "4", detail: "需本周复核" }
],
headers: ["项目名称", "节能措施", "本月节电", "同比变化", "状态", "负责人"],
rows: [
["循环花园一期", "照明联控", "6.8万kWh", "-7.1%", "稳定", "郭晓"],
["博万物", "泵房变频", "5.1万kWh", "-5.4%", "观察", "何琳"],
["江南世家一期", "风机调度", "3.9万kWh", "-6.8%", "稳定", "陈谷先"]
]
}),
fullCleaning: createHcPosStaticPreset({
eyebrow: "全员行动",
title: "全员保洁总览",
summary: "展示集中保洁行动、参与规模与问题闭环,替代等待页。",
accent: "#06b6d4",
cards: [
{ label: "行动场次", value: "14", detail: "本月新增 3 场" },
{ label: "参与人数", value: "186", detail: "覆盖 9 个项目" },
{ label: "整治点位", value: "328", detail: "闭环率 94.8%" },
{ label: "住户好评", value: "96%", detail: "环境反馈明显提升" }
],
headers: ["项目名称", "行动主题", "参与人数", "整治点位", "闭环率", "负责人"],
rows: [
["循环花园一期", "雨后公区清洁", "46", "82", "97%", "郭晓"],
["博万物", "地下车库专项保洁", "38", "71", "93%", "何琳"],
["江南世家一期", "楼道整治提升", "31", "56", "92%", "陈谷先"]
]
}),
fullPatrol: createHcPosStaticPreset({
eyebrow: "全员行动",
title: "全员巡查总览",
summary: "汇总集中巡查发现问题、闭环率与重点隐患,替代等待页。",
accent: "#f97316",
cards: [
{ label: "巡查场次", value: "11", detail: "覆盖重点区域 26 个" },
{ label: "发现问题", value: "94", detail: "已闭环 82 项" },
{ label: "重点隐患", value: "7", detail: "均已派发整改" },
{ label: "闭环率", value: "87.2%", detail: "本周继续跟进" }
],
headers: ["项目名称", "巡查主题", "参与人数", "发现问题", "闭环率", "负责人"],
rows: [
["循环花园一期", "设备与环境联合巡查", "28", "31", "90%", "郭晓"],
["博万物", "高空坠物风险巡查", "24", "26", "85%", "何琳"],
["江南世家一期", "夜间安防巡查", "19", "18", "89%", "陈谷先"]
]
}),
materialScrapDisposal: createHcPosStaticPreset({
eyebrow: "物资管理",
title: "报废处理总览",
summary: "汇总报废物资、审批进度与处置去向,替代等待页。",
accent: "#ef4444",
cards: [
{ label: "报废单数", value: "26", detail: "本月新增 5 单" },
{ label: "报废物资", value: "318 件", detail: "设备件占比 42%" },
{ label: "审批通过", value: "21", detail: "待复核 3 单" },
{ label: "回收金额", value: "¥18,600", detail: "较上月 +11.4%" }
],
headers: ["项目名称", "报废物资", "数量", "审批状态", "处置方式", "负责人"],
rows: [
["循环花园一期", "废旧探测器", "46", "已通过", "回收入库", "郭晓"],
["博万物", "老旧门禁卡", "128", "待复核", "集中销毁", "何琳"],
["江南世家一期", "损坏工具箱", "22", "已通过", "废品回收", "陈谷先"]
]
}),
parkingAppointmentVisit: createHcPosStaticPreset({
eyebrow: "车场运营",
title: "预约来访总览",
summary: "展示来访预约、放行效率与高峰时段表现,替代等待页。",
accent: "#7c4dff",
cards: [
{ label: "本日预约", value: "186", detail: "较昨日 +12" },
{ label: "已放行", value: "172", detail: "放行率 92.5%" },
{ label: "超时等待", value: "6", detail: "均已处理" },
{ label: "高峰时段", value: "18:00-20:00", detail: "需加岗 1 人" }
],
headers: ["项目名称", "来访类型", "预约数", "已到访", "通过率", "岗亭"],
rows: [
["循环花园一期", "访客车辆", "72", "67", "93.1%", "北门岗"],
["博万物", "商户来访", "58", "51", "87.9%", "西门岗"],
["江南世家一期", "施工车辆", "24", "22", "91.7%", "南门岗"]
]
}),
parkingSuspiciousRecords: createHcPosStaticPreset({
eyebrow: "车场运营",
title: "异常管理总览",
summary: "汇总异常进出、黑名单车辆与核查进度,替代等待页。",
accent: "#ef4444",
cards: [
{ label: "异常记录", value: "42", detail: "重复进出 18 条" },
{ label: "待核查", value: "9", detail: "黑名单 2 辆" },
{ label: "已处置", value: "31", detail: "闭环率 88.6%" },
{ label: "高风险时段", value: "23:00-02:00", detail: "需加强巡查" }
],
headers: ["项目名称", "异常类型", "本月记录", "已闭环", "风险级别", "负责人"],
rows: [
["循环花园一期", "重复进出", "15", "13", "中", "郭晓"],
["博万物", "车牌异常", "12", "9", "高", "何琳"],
["江南世家一期", "逃费嫌疑", "8", "7", "中", "陈谷先"]
]
}),
parkingTemporaryControl: createHcPosStaticPreset({
eyebrow: "车场运营",
title: "临停管控总览",
summary: "展示临停车位利用、收费完成与管控效果,替代等待页。",
accent: "#14b8a6",
cards: [
{ label: "临停车位", value: "486", detail: "高峰利用率 84%" },
{ label: "日均车次", value: "1,128", detail: "周末更高" },
{ label: "临停收费", value: "¥62,400", detail: "本月累计" },
{ label: "异常拦截", value: "17", detail: "已复核完成" }
],
headers: ["项目名称", "临停车位", "日均车次", "异常拦截", "收费率", "负责人"],
rows: [
["循环花园一期", "186", "426", "6", "95.4%", "郭晓"],
["博万物", "144", "358", "5", "91.8%", "何琳"],
["江南世家一期", "102", "221", "3", "93.7%", "陈谷先"]
]
}),
parkingPhysical: createHcPosStaticPreset({
eyebrow: "车场运营",
title: "车场测评总览",
summary: "汇总车场测评得分、整改项与复检状态,替代等待页。",
accent: "#8b5cf6",
cards: [
{ label: "测评批次", value: "12", detail: "覆盖 7 个项目" },
{ label: "平均得分", value: "89.6", detail: "较上月 +1.4" },
{ label: "整改项", value: "16", detail: "待复检 4 项" },
{ label: "优秀率", value: "58.3%", detail: "A 级占比" }
],
headers: ["项目名称", "测评主题", "本月测评", "平均分", "整改项", "负责人"],
rows: [
["循环花园一期", "出入口秩序", "4", "92.4", "2", "郭晓"],
["博万物", "岗亭服务", "3", "88.7", "3", "何琳"],
["江南世家一期", "车场动线", "2", "87.9", "1", "陈谷先"]
]
}),
parkingOwnerArchives: createHcPosStaticPreset({
eyebrow: "车场运营",
title: "车主档案总览",
summary: "汇总车主建档、认证状态与月卡结构,替代等待页。",
accent: "#2d76ff",
cards: [
{ label: "车主档案", value: "2,148", detail: "本月新增 64 份" },
{ label: "已认证", value: "1,986", detail: "认证率 92.5%" },
{ label: "待补资料", value: "42", detail: "集中在租户车主" },
{ label: "月卡车主", value: "1,284", detail: "固定车主占比高" }
],
headers: ["项目名称", "车主档案", "已认证", "待补资料", "月卡车主", "负责人"],
rows: [
["循环花园一期", "726", "683", "12", "438", "郭晓"],
["博万物", "542", "491", "18", "336", "何琳"],
["江南世家一期", "314", "287", "7", "184", "陈谷先"]
]
}),
renovationDeclaration: createHcPosStaticPreset({
eyebrow: "装修管理",
title: "装修报建总览",
summary: "展示装修申请、审批进度与违规预警,替代等待页。",
accent: "#f59e0b",
cards: [
{ label: "报建申请", value: "86", detail: "本月新增 18 单" },
{ label: "已审批", value: "72", detail: "通过率 83.7%" },
{ label: "在审中", value: "9", detail: "平均 1.8 天" },
{ label: "违规预警", value: "3", detail: "均已通知整改" }
],
headers: ["项目名称", "报建申请", "已审批", "在审中", "违规项", "负责人"],
rows: [
["循环花园一期", "28", "23", "3", "1", "郭晓"],
["博万物", "21", "18", "2", "1", "何琳"],
["江南世家一期", "14", "12", "1", "0", "陈谷先"]
]
}),
renovationCheck: createHcPosStaticPreset({
eyebrow: "装修管理",
title: "装修验收总览",
summary: "汇总验收批次、通过率与复检情况,替代等待页。",
accent: "#14b8a6",
cards: [
{ label: "验收批次", value: "52", detail: "本月新增 11 批" },
{ label: "通过率", value: "88.5%", detail: "复检中 5 单" },
{ label: "整改项", value: "18", detail: "噪音粉尘为主" },
{ label: "待复检", value: "5", detail: "均已排期" }
],
headers: ["项目名称", "验收批次", "通过率", "整改项", "复检中", "负责人"],
rows: [
["循环花园一期", "18", "91.6%", "5", "1", "郭晓"],
["博万物", "14", "85.7%", "7", "2", "何琳"],
["江南世家一期", "9", "88.9%", "2", "1", "陈谷先"]
]
}),
renovationFeeManage: createHcPosStaticPreset({
eyebrow: "装修管理",
title: "装修收费管理总览",
summary: "展示装修押金、垃圾清运费与欠费情况,替代等待页。",
accent: "#2d76ff",
cards: [
{ label: "收费单数", value: "74", detail: "本月新增 16 单" },
{ label: "应收金额", value: "¥428,600", detail: "已收 93.4%" },
{ label: "押金冻结", value: "¥216,000", detail: "待退 9 单" },
{ label: "欠费单", value: "4", detail: "均已提醒" }
],
headers: ["项目名称", "收费单数", "应收金额", "已收金额", "欠费单", "负责人"],
rows: [
["循环花园一期", "24", "¥138,000", "¥132,000", "1", "郭晓"],
["博万物", "18", "¥106,400", "¥98,600", "2", "何琳"],
["江南世家一期", "12", "¥68,200", "¥66,900", "0", "陈谷先"]
]
}),
renovationPatrol: createHcPosStaticPreset({
eyebrow: "装修管理",
title: "装修巡查总览",
summary: "汇总日常巡查、违规装修与闭环情况,替代等待页。",
accent: "#ef4444",
cards: [
{ label: "巡查频次", value: "164", detail: "日均 5.4 次" },
{ label: "发现问题", value: "28", detail: "已闭环 24 项" },
{ label: "违规装修", value: "6", detail: "集中在超时施工" },
{ label: "闭环率", value: "85.7%", detail: "需继续跟进" }
],
headers: ["项目名称", "巡查频次", "发现问题", "已闭环", "违规装修", "负责人"],
rows: [
["循环花园一期", "58", "11", "10", "2", "郭晓"],
["博万物", "46", "9", "7", "3", "何琳"],
["江南世家一期", "28", "4", "4", "0", "陈谷先"]
]
}),
satisfactionQuestionnaire: createHcPosStaticPreset({
eyebrow: "客户满意",
title: "调查问卷总览",
summary: "展示问卷发放、回收率与满意度趋势,替代等待页。",
accent: "#8b5cf6",
cards: [
{ label: "问卷主题", value: "18", detail: "覆盖保洁 / 车场 / 安防" },
{ label: "发放数量", value: "3,286", detail: "本月累计" },
{ label: "回收数量", value: "2,614", detail: "回收率 79.5%" },
{ label: "平均满意度", value: "4.73", detail: "较上月 +0.04" }
],
headers: ["项目名称", "问卷主题", "发放数量", "回收数量", "回收率", "负责人"],
rows: [
["循环花园一期", "公区服务体验", "986", "812", "82.4%", "郭晓"],
["博万物", "车场秩序满意度", "742", "568", "76.5%", "何琳"],
["江南世家一期", "安防服务评价", "418", "339", "81.1%", "陈谷先"]
]
}),
securityMonitoringCenter: createHcPosStaticPreset({
eyebrow: "安防管理",
title: "监控中心总览",
summary: "展示监控在线率、离线设备与告警处置,替代等待页。",
accent: "#ef4444",
cards: [
{ label: "在线设备", value: "1,286", detail: "在线率 98.7%" },
{ label: "离线设备", value: "17", detail: "已派检修 9 台" },
{ label: "本月告警", value: "68", detail: "已处置 61 条" },
{ label: "处置率", value: "89.7%", detail: "夜间告警偏多" }
],
headers: ["项目名称", "在线设备", "离线设备", "异常告警", "处置率", "值班长"],
rows: [
["循环花园一期", "426", "4", "18", "94.4%", "郭晓"],
["博万物", "318", "7", "23", "82.6%", "何琳"],
["江南世家一期", "204", "2", "9", "88.9%", "陈谷先"]
]
}),
securityEmergencyManagement: createHcPosStaticPreset({
eyebrow: "安防管理",
title: "应急处理总览",
summary: "汇总应急预案、演练频次与响应时长,替代等待页。",
accent: "#f97316",
cards: [
{ label: "应急预案", value: "24", detail: "覆盖火警 / 停电 / 水浸" },
{ label: "演练次数", value: "18", detail: "季度计划完成" },
{ label: "平均响应", value: "6.8 分钟", detail: "同比缩短 0.9 分钟" },
{ label: "待整改", value: "5", detail: "集中在物资准备" }
],
headers: ["项目名称", "预案类型", "演练次数", "响应时长", "待整改", "负责人"],
rows: [
["循环花园一期", "火警处置", "6", "6.2 分钟", "1", "郭晓"],
["博万物", "停电应急", "5", "7.1 分钟", "2", "何琳"],
["江南世家一期", "水浸处置", "3", "6.9 分钟", "1", "陈谷先"]
]
}),
securityArchives: createHcPosStaticPreset({
eyebrow: "安防管理",
title: "安防档案总览",
summary: "汇总安防档案、证照临期与资料完备度,替代等待页。",
accent: "#2d76ff",
cards: [
{ label: "安防档案", value: "86", detail: "设备 / 人员 / 证照" },
{ label: "完备率", value: "96.5%", detail: "缺失资料 3 份" },
{ label: "临期证照", value: "6", detail: "需本月更新" },
{ label: "更新状态", value: "稳定", detail: "本周新增 4 份" }
],
headers: ["项目名称", "安防档案", "完备率", "临期证照", "更新状态", "负责人"],
rows: [
["循环花园一期", "32", "100%", "1", "正常", "郭晓"],
["博万物", "24", "91.7%", "3", "补录中", "何琳"],
["江南世家一期", "11", "90.9%", "1", "正常", "陈谷先"]
]
}),
securityInternetOfThings: createHcPosStaticPreset({
eyebrow: "安全生产",
title: "物联网总览",
summary: "展示联网设备、在线状态与告警处置,替代等待页。",
accent: "#14b8a6",
cards: [
{ label: "联网设备", value: "624", detail: "覆盖烟感 / 水压 / 门磁" },
{ label: "在线率", value: "97.9%", detail: "离线 13 台" },
{ label: "本月告警", value: "54", detail: "已处置 49 条" },
{ label: "处置率", value: "90.7%", detail: "重点关注夜间告警" }
],
headers: ["项目名称", "联网设备", "在线率", "告警数", "已处置", "负责人"],
rows: [
["循环花园一期", "218", "98.6%", "16", "15", "郭晓"],
["博万物", "176", "96.8%", "21", "18", "何琳"],
["江南世家一期", "114", "97.4%", "9", "8", "陈谷先"]
]
})
};
const HCPOS_WAIT_PAGE_ROUTE_PRESETS = {
"/propertySMG/earlyManagement/partnership/": "earlyPartnership",
"/propertySMG/earlyManagement/salesCooperation/": "earlySalesCooperation",
"/propertySMG/earlyManagement/undertakeInspection/": "earlyUndertakeInspection",
"/propertySMG/elevatorManage/elevatorYearly/": "elevatorYearly",
"/propertySMG/energySourceOperat/publicAreaControl/meterReadingCharge/": "energyMeterReadingCharge",
"/propertySMG/equipmentManage/useManagement/energySaving/": "equipmentEnergySaving",
"/propertySMG/fullForceAssaultSMG/fullCleaning/": "fullCleaning",
"/propertySMG/fullForceAssaultSMG/fullPatrol/": "fullPatrol",
"/propertySMG/materialManage/scrapDisposal/": "materialScrapDisposal",
"/propertySMG/parkingOperation/dailyManage/appointmentVisit/": "parkingAppointmentVisit",
"/propertySMG/parkingOperation/dailyManage/suspiciousRecords/": "parkingSuspiciousRecords",
"/propertySMG/parkingOperation/dailyManage/temporaryControl/": "parkingTemporaryControl",
"/propertySMG/parkingOperation/parkingPhysical/": "parkingPhysical",
"/propertySMG/parkingOperation/parkingRecord/ownerArchives/": "parkingOwnerArchives",
"/propertySMG/renovationManage/renovation/": "renovationDeclaration",
"/propertySMG/renovationManage/renovationCheck/": "renovationCheck",
"/propertySMG/renovationManage/renovationFeeManage/": "renovationFeeManage",
"/propertySMG/renovationManage/renovationPatrol/": "renovationPatrol",
"/propertySMG/satisfaction/satisfactionSurvey/questionnaire/": "satisfactionQuestionnaire",
"/propertySMG/securityManage/dailySecurity/monitoringCenter/": "securityMonitoringCenter",
"/propertySMG/securityManage/emergencyManagement/": "securityEmergencyManagement",
"/propertySMG/securityManage/securityFile/securityArchives/": "securityArchives",
"/propertySMG/securityProduction/dangerousSupervision/internetofThings/": "securityInternetOfThings"
};
const HCPOS_COCKPIT_LINKS = {
"智能人事": { runtime: "hcpos", path: "/systemManage/projectConfig/internalControl/ProjectManagerConfig" },
"作业看板": { runtime: "hcpos", path: "/propertySMG/equipmentManage/equipmentPortrait" },
"车场看板": { runtime: "hcpos", path: "/propertySMG/parkingOperation/parkingMicroBrain" },
"能源看板": { runtime: "hcpos", path: "/propertySMG/energySourceOperat/notice" },
"住户卡": { runtime: "hcpos", path: "/communitySMG/personnelList" },
"安全生产": { runtime: "hcpos", path: "/propertySMG/securityProduction/checkStandardLibrary" },
"收费看板": { runtime: "hcpos", path: "/propertySMG/businessTaxCank/financeMicrobrain" },
"客户通": { runtime: "hcpos", path: "/propertySMG/customerOperations/customerPortrait" },
"网格看板": { runtime: "hcpos", path: "/propertySMG/basicManagement/spatialRegion" },
"物业费报表": { runtime: "hcetms", path: "/r2cockpit/cloudData/propertyFeeReport" },
"车场报表": { runtime: "hcetms", path: "/r2cockpit/cloudData/parkingLotReport" },
"能耗报表": { runtime: "hcpos", path: "/propertySMG/energySourceOperat/energySourcMicrobrain" },
"全年收入报表": { runtime: "hcpos", path: "/propertySMG/businessTaxCank/financeReport/incomeStatement" },
"全员收费报表": { runtime: "hcpos", path: "/propertySMG/fullForceAssaultSMG/fullStaffFee/arrearsReport" },
"收入考核报表": { runtime: "hcpos", path: "/propertySMG/businessTaxCank/financeReport/projectIncome" },
"回款动作与分析": { runtime: "hcetms", path: "/r2cockpit/cloudData/collectionTracking" },
"日清日高": { runtime: "hcpos", path: "/dashboard" },
"月清月高": { runtime: "hcpos", path: "/dashboard" },
"智能催费": { runtime: "hcpos", path: "/aiProduct/urgePayment/urgeVisitPlan" },
"智能质检": { runtime: "hcpos", path: "/aiProduct/videoQualityInspection" },
"智能能源": { runtime: "hcpos", path: "/propertySMG/energySourceOperat/energySourcMicrobrain" },
"智能工单": { runtime: "hcpos", path: "/propertySMG/securityProduction/rectificationImplementation/dangerousPlan" },
"智能报告": { runtime: "hcpos", path: "/systemManage/projectConfig/internalControl/theReportModule" },
"验收工作台": { runtime: "hcetms", path: "/trainingPush/sampling" },
"视频验收": { runtime: "hcpos", path: "/aiProduct/videoQualityInspection" },
"安全指数": { runtime: "hcpos", path: "/propertySMG/securityProduction/checkStandardLibrary" },
"危险源监控": { runtime: "hcpos", path: "/propertySMG/securityProduction/checkStandardLibrary" },
"应急预案": { runtime: "hcpos", path: "/propertySMG/securityProduction/rectificationImplementation/emergencyPlan" },
"应急演练": { runtime: "hcpos", path: "/propertySMG/securityProduction/rectificationImplementation/securityDrills" },
"安全培训": { runtime: "hcetms", path: "/trainingManage" },
"日现金流入": { runtime: "hcpos", path: "/propertySMG/businessTaxCank/financeMicrobrain" },
"日现金流出": { runtime: "hcpos", path: "/propertySMG/businessTaxCank/financeMicrobrain" },
"收入结构图": { runtime: "hcpos", path: "/propertySMG/businessTaxCank/financeMicrobrain" },
"成本结构图": { runtime: "hcpos", path: "/propertySMG/businessTaxCank/financeMicrobrain" },
"客户满意": { runtime: "hcpos", path: "/propertySMG/customerOperations/customerPortrait" },
"客户投诉": { runtime: "hcpos", path: "/propertySMG/customerOperations/customerPortrait" },
"内部满意": { runtime: "hcpos", path: "/propertySMG/customerOperations/customerPortrait" },
"计划工单": { runtime: "hcetms", path: "/r2cockpit/cloudData/planTaskReport" },
"返回": { runtime: "hcpos", path: "/dashboard" },
"企业后台": { runtime: "hcetms", path: "" }
};
const HCPOS_SECONDARY_TAB_PRESETS = {
keyCustomer: {
eyebrow: "客户分层",
title: "重点客户总览",
summary: "聚合重点客户分层、跟进状态与回访任务,补齐空白标签页。",
cards: [
{ label: "重点客户", value: "126", detail: "A 类客户 38 位" },
{ label: "本周回访", value: "64", detail: "完成率 82.8%" },
{ label: "投诉敏感", value: "11", detail: "需专人跟进" },
{ label: "回款客户", value: "72", detail: "本月已回款" }
],
headers: ["客户名称", "所属项目", "客户等级", "关注标签", "最近回访", "负责人", "状态"],
rows: [
["李天", "循环花园一期", "A", "高频互动", "2026-04-03", "郭晓", "持续跟进"],
["肖英", "明珠佳园", "A", "缴费稳定", "2026-04-02", "何琳", "正常"],
["卢跃梅", "龙湾一品小区", "B", "投诉敏感", "2026-04-01", "陈谷先", "需回访"],
["小小", "明珠佳园", "B", "亲属关系维护", "2026-03-30", "曾丽娜", "正常"],
["来了", "A 管理区", "C", "新签客户", "2026-03-28", "周宇", "观察中"]
]
},
customizedPhysicalRecord: {
eyebrow: "专家测评",
title: "定制体检记录总览",
summary: "展示体检对象、测评得分与整改建议,补齐空白记录页。",
cards: [
{ label: "体检记录", value: "86", detail: "本月新增 12 条" },
{ label: "平均得分", value: "82.6", detail: "定制套餐口径" },
{ label: "高风险项", value: "9", detail: "需复检" },
{ label: "整改闭环率", value: "78.4%", detail: "本周提升" }
],
headers: ["项目名称", "体检对象", "套餐名称", "测评日期", "得分", "风险等级", "建议动作"],
rows: [
["循环花园一期", "消防泵房", "火灾应急", "2026-04-03", "88.2", "低", "保持巡检"],
["博万物", "设备房", "设备管控", "2026-04-02", "79.4", "中", "补充维保"],
["美好花园", "绿化景观带", "绿化作业", "2026-04-01", "84.1", "低", "正常维护"],
["连城花园", "楼栋卫生区", "清洁作业", "2026-03-30", "76.3", "中", "安排复检"],
["江南世家一期", "园区道路", "清洁作业", "2026-03-28", "71.8", "高", "专项整改"]
]
},
specialPhysicalRecord: {
eyebrow: "专家测评",
title: "专项体检记录总览",
summary: "展示专项体检对象、问题点位与整改进展,补齐空白记录页。",
cards: [
{ label: "专项记录", value: "112", detail: "车场 / 绿化 / 安防" },
{ label: "平均得分", value: "84.9", detail: "较上月 +1.2" },
{ label: "整改中", value: "14", detail: "需闭环追踪" },
{ label: "通过率", value: "87.5%", detail: "专项测评口径" }
],
headers: ["项目名称", "专项对象", "套餐名称", "测评日期", "得分", "整改状态", "责任人"],
rows: [
["循环花园一期", "车场入口", "车场专项体检-5A", "2026-04-03", "83.6", "已完成", "郭晓"],
["博万物", "中央花园", "树木与设备加固", "2026-04-02", "79.1", "处理中", "何琳"],
["美好花园", "北门绿篱", "树木枯枝修剪", "2026-04-01", "81.4", "已完成", "曾丽娜"],
["连城花园", "垃圾堆放点", "垃圾堆放点清洁", "2026-03-30", "74.8", "待复检", "周宇"],
["江南世家一期", "楼道地面", "楼道地面清洁", "2026-03-29", "78.2", "处理中", "陈谷先"]
]
},
fiveAPhysicalRecord: {
eyebrow: "专家测评",
title: "5A体检记录总览",
summary: "展示 5A 测评对象、评分与复检安排,补齐空白记录页。",
cards: [
{ label: "5A记录", value: "64", detail: "本月新增 8 条" },
{ label: "平均得分", value: "89.4", detail: "高于月基线" },
{ label: "待复评", value: "6", detail: "需补充复检" },
{ label: "优秀率", value: "62.5%", detail: "A 级占比" }
],
headers: ["项目名称", "体检对象", "套餐名称", "测评日期", "得分", "评级", "整改动作"],
rows: [
["循环花园一期", "公共区域", "体检套餐2.0-5A", "2026-04-03", "91.2", "A", "保持标准"],
["博万物", "设备房", "体检套餐2.0-5A", "2026-04-02", "87.6", "A-", "补录照片"],
["美好花园", "车场入口", "体检套餐2.0-5A", "2026-04-01", "84.2", "B+", "专项复检"],
["连城花园", "物业服务中心", "体检套餐2.0-5A", "2026-03-30", "88.5", "A-", "正常跟进"],
["江南世家一期", "园区主路", "体检套餐2.0-5A", "2026-03-28", "82.3", "B", "优化流程"]
]
}
};
const HCPOS_OVERVIEW_PRESETS = {
personnelList: {
eyebrow: "社区治理",
title: "住户档案总览",
summary: "聚合住户数量、产权结构与审核状态,增强主页信息层次。",
cards: [
{ label: "住户总数", value: "173", detail: "产权人 96 位" },
{ label: "审核通过", value: "162", detail: "通过率 93.6%" },
{ label: "绑定微信", value: "84", detail: "绑定率持续提升" },
{ label: "待审核", value: "11", detail: "需尽快处理" }
]
},
canteenArchives: {
eyebrow: "家企服务",
title: "食堂档案总览",
summary: "汇总食堂档案、经营主体与启用状态,增强主页信息层次。",
cards: [
{ label: "食堂数量", value: "18", detail: "启用 16 家" },
{ label: "本月新增", value: "2", detail: "新增 1 家在审核" },
{ label: "经营单位", value: "12", detail: "已建档主体" },
{ label: "联系人完整率", value: "100%", detail: "档案资料齐全" }
]
},
customizedPhysical: {
eyebrow: "专家测评",
title: "定制测评总览",
summary: "展示定制套餐数量、应用场景与平均分,提升主页概览能力。",
cards: [
{ label: "定制套餐", value: "46", detail: "本月新增 6 个" },
{ label: "应用场景", value: "12", detail: "覆盖清洁 / 安全 / 设备" },
{ label: "平均分数", value: "36.8", detail: "定制口径" },
{ label: "高分套餐", value: "8", detail: "80 分以上" }
]
},
specialPhysical: {
eyebrow: "专家测评",
title: "专项测评总览",
summary: "展示专项套餐分布、评分与同步情况,提升主页概览能力。",
cards: [
{ label: "专项套餐", value: "22", detail: "同步云库 1 次" },
{ label: "应用场景", value: "8", detail: "车场 / 绿化 / 清洁" },
{ label: "平均分数", value: "24.7", detail: "专项口径" },
{ label: "高风险套餐", value: "3", detail: "需复检" }
]
},
fiveAPhysical: {
eyebrow: "专家测评",
title: "5A测评总览",
summary: "汇总 5A 套餐规模、测评强度与通过率,提升主页概览能力。",
cards: [
{ label: "5A 套餐", value: "1", detail: "主套餐已上线" },
{ label: "套餐分数", value: "22088", detail: "5A 标准口径" },
{ label: "体检记录", value: "64", detail: "已补至记录页" },
{ label: "优秀率", value: "62.5%", detail: "A 级占比" }
]
}
};
function buildLinePath(values, width, height, padding) {
const max = Math.max(...values);
const min = Math.min(...values);
const span = Math.max(max - min, 1);
return values.map((value, index) => {
const x = padding + index * (width - padding * 2) / Math.max(values.length - 1, 1);
const y = height - padding - (value - min) / span * (height - padding * 2);
return `${index === 0 ? "M" : "L"}${x.toFixed(1)} ${y.toFixed(1)}`;
}).join(" ");
}
function buildAreaPoints(values, width, height, padding) {
const max = Math.max(...values);
const min = Math.min(...values);
const span = Math.max(max - min, 1);
const points = values.map((value, index) => {
const x = padding + index * (width - padding * 2) / Math.max(values.length - 1, 1);
const y = height - padding - (value - min) / span * (height - padding * 2);
return `${x.toFixed(1)},${y.toFixed(1)}`;
});
points.push(`${width - padding},${height - padding}`, `${padding},${height - padding}`);
return points.join(" ");
}
function buildTrendSvg(seriesList, labels) {
const width = 560;
const height = 220;
const padding = 24;
const allValues = seriesList.flatMap((item) => item.values);
const max = Math.max(...allValues);
const min = Math.min(...allValues);
const span = Math.max(max - min, 1);
const guides = [0, 0.25, 0.5, 0.75, 1].map((ratio) => {
const y = padding + ratio * (height - padding * 2);
const value = Math.round(max - ratio * span);
return `
<line x1="${padding}" y1="${y}" x2="${width - padding}" y2="${y}" stroke="rgba(17,37,63,0.08)" stroke-dasharray="4 6"></line>
<text x="0" y="${y + 4}" fill="#8b9ab3" font-size="11">${value}</text>
`;
});
const xLabels = labels.map((label, index) => {
const x = padding + index * (width - padding * 2) / Math.max(labels.length - 1, 1);
return `<text x="${x}" y="${height}" text-anchor="middle" fill="#8b9ab3" font-size="11">${label}</text>`;
}).join("");
const paths = seriesList.map((item, index) => {
const areaOpacity = index === 0 ? 0.14 : 0.08;
return `
<polygon points="${buildAreaPoints(item.values, width, height, padding)}" fill="${item.color}" opacity="${areaOpacity}"></polygon>
<path d="${buildLinePath(item.values, width, height, padding)}" fill="none" stroke="${item.color}" stroke-width="3" stroke-linecap="round"></path>
${item.values.map((value, valueIndex) => {
const x = padding + valueIndex * (width - padding * 2) / Math.max(item.values.length - 1, 1);
const y = height - padding - (value - min) / span * (height - padding * 2);
return `<circle cx="${x}" cy="${y}" r="4" fill="#fff" stroke="${item.color}" stroke-width="2"></circle>`;
}).join("")}
`;
}).join("");
return `
<svg viewBox="0 0 ${width} ${height + 18}" class="codex-hcpos-chart" preserveAspectRatio="none">
${guides.join("")}
${paths}
${xLabels}
</svg>
`;
}
function renderHcPosDashboard(doc, type) {
const preset = HCPOS_DASHBOARD_PRESETS[type];
if (!preset) {
return;
}
if (!doc.getElementById("__codex_hcpos_dashboard_style__")) {
const style = doc.createElement("style");
style.id = "__codex_hcpos_dashboard_style__";
style.textContent = `
.waitMain {
display: none !important;
}
#__codex_hcpos_dashboard__ {
margin-top: 18px;
padding: 20px 22px 24px;
border-radius: 20px;
background:
radial-gradient(circle at top right, rgba(45, 118, 255, 0.12), transparent 28%),
linear-gradient(180deg, #ffffff 0%, #f7faff 100%);
border: 1px solid rgba(17, 37, 63, 0.06);
box-shadow: 0 18px 42px rgba(17, 37, 63, 0.08);
}
.codex-hcpos-head {
display: flex;
align-items: flex-end;
justify-content: space-between;
gap: 20px;
margin-bottom: 20px;
}
.codex-hcpos-eyebrow {
display: inline-flex;
align-items: center;
padding: 4px 10px;
border-radius: 999px;
margin-bottom: 10px;
font-size: 12px;
color: #5b6f92;
background: rgba(17, 37, 63, 0.06);
}
.codex-hcpos-head h3 {
margin: 0 0 6px;
font-size: 28px;
color: #12233d;
}
.codex-hcpos-head p {
margin: 0;
max-width: 660px;
color: #6d7d97;
font-size: 14px;
}
.codex-hcpos-badge {
padding: 10px 14px;
border-radius: 14px;
color: #35517d;
font-size: 12px;
background: rgba(255,255,255,0.8);
border: 1px solid rgba(17,37,63,0.08);
}
.codex-hcpos-metrics {
display: grid;
grid-template-columns: repeat(4, minmax(0, 1fr));
gap: 14px;
margin-bottom: 18px;
}
.codex-hcpos-metric {
padding: 16px 18px;
border-radius: 18px;
background: rgba(255,255,255,0.82);
border: 1px solid rgba(17,37,63,0.06);
box-shadow: 0 12px 28px rgba(17,37,63,0.06);
}
.codex-hcpos-metric span {
display: block;
color: #7d8ca5;
font-size: 13px;
}
.codex-hcpos-metric strong {
display: block;
margin: 8px 0 6px;
color: #12233d;
font-size: 28px;
line-height: 1.1;
}
.codex-hcpos-metric small {
color: #4e6b98;
font-size: 12px;
}
.codex-hcpos-layout {
display: grid;
grid-template-columns: minmax(0, 1.6fr) minmax(320px, 0.95fr);
gap: 16px;
}
.codex-hcpos-panel {
padding: 18px 18px 16px;
border-radius: 18px;
background: rgba(255,255,255,0.92);
border: 1px solid rgba(17,37,63,0.06);
}
.codex-hcpos-panel h4 {
margin: 0 0 14px;
color: #152742;
font-size: 16px;
}
.codex-hcpos-legend {
display: flex;
gap: 14px;
flex-wrap: wrap;
margin-bottom: 12px;
}
.codex-hcpos-legend span {
display: inline-flex;
align-items: center;
gap: 6px;
color: #71829d;
font-size: 12px;
}
.codex-hcpos-dot {
width: 9px;
height: 9px;
border-radius: 50%;
}
.codex-hcpos-chart {
width: 100%;
height: 238px;
}
.codex-hcpos-segments {
display: grid;
gap: 12px;
}
.codex-hcpos-segment {
display: grid;
grid-template-columns: 88px 1fr 48px;
align-items: center;
gap: 10px;
color: #4d607f;
font-size: 13px;
}
.codex-hcpos-track {
overflow: hidden;
height: 10px;
border-radius: 999px;
background: #eef3fb;
}
.codex-hcpos-fill {
height: 100%;
border-radius: inherit;
}
.codex-hcpos-table table {
width: 100%;
border-collapse: collapse;
}
.codex-hcpos-table th,
.codex-hcpos-table td {
padding: 12px 8px;
border-bottom: 1px solid rgba(17,37,63,0.06);
text-align: left;
color: #3f5477;
font-size: 13px;
}
.codex-hcpos-table th {
color: #8b9ab3;
font-size: 12px;
font-weight: 500;
}
.codex-hcpos-alerts {
display: grid;
gap: 10px;
}
.codex-hcpos-alert {
padding: 14px 14px 13px;
border-radius: 14px;
background: #f8fbff;
border: 1px solid rgba(17,37,63,0.06);
}
.codex-hcpos-alert b {
display: flex;
align-items: center;
justify-content: space-between;
gap: 12px;
margin-bottom: 6px;
color: #152742;
font-size: 14px;
}
.codex-hcpos-alert p {
margin: 0;
color: #6d7d97;
font-size: 12px;
line-height: 1.6;
}
.codex-hcpos-level {
display: inline-flex;
align-items: center;
justify-content: center;
padding: 4px 8px;
border-radius: 999px;
font-size: 11px;
font-weight: 600;
}
.codex-hcpos-level-正常 {
color: #067647;
background: rgba(6, 118, 71, 0.12);
}
.codex-hcpos-level-关注 {
color: #975a16;
background: rgba(255, 183, 77, 0.18);
}
.codex-hcpos-level-预警 {
color: #c92a2a;
background: rgba(255, 107, 107, 0.16);
}
@media (max-width: 1080px) {
.codex-hcpos-metrics {
grid-template-columns: repeat(2, minmax(0, 1fr));
}
.codex-hcpos-layout {
grid-template-columns: 1fr;
}
}
`;
doc.head.appendChild(style);
}
const host = doc.querySelector(".app-main > div") || doc.querySelector(".app-main > section") || doc.querySelector(".app-main") || doc.body;
if (!host) {
return;
}
if (type === "financeMicrobrain" || type === "energyNotice") {
[...host.children].forEach((child) => {
if (child.id !== "__codex_hcpos_dashboard__") {
child.style.display = "none";
}
});
}
let container = doc.getElementById("__codex_hcpos_dashboard__");
if (!container) {
container = doc.createElement("div");
container.id = "__codex_hcpos_dashboard__";
host.insertBefore(container, host.firstChild);
}
const legend = preset.trendSeries.map(
(item) => `
<span><i class="codex-hcpos-dot" style="background:${item.color}"></i>${item.label}</span>
`
).join("");
const segments = preset.segments.map(
(item) => `
<div class="codex-hcpos-segment">
<span>${item.label}</span>
<div class="codex-hcpos-track"><div class="codex-hcpos-fill" style="width:${item.value}; background:${item.tone}"></div></div>
<strong>${item.value}</strong>
</div>
`
).join("");
const metrics = preset.metrics.map(
(item) => `
<div class="codex-hcpos-metric" style="box-shadow: 0 12px 28px ${preset.accentSoft}">
<span>${item.label}</span>
<strong>${item.value}</strong>
<small>${item.delta}</small>
</div>
`
).join("");
const rows = preset.rankingRows.map(
(row, index) => `
<tr>
<td>${index + 1}</td>
<td>${row[0]}</td>
<td>${row[1]}</td>
<td>${row[2]}</td>
</tr>
`
).join("");
const alerts = preset.alerts.map(
(item) => `
<div class="codex-hcpos-alert">
<b>
<span>${item.title}</span>
<span class="codex-hcpos-level codex-hcpos-level-${item.level}">${item.level}</span>
</b>
<p>${item.detail}</p>
</div>
`
).join("");
container.innerHTML = `
<div class="codex-hcpos-head">
<div>
<span class="codex-hcpos-eyebrow">${preset.eyebrow}</span>
<h3>${preset.headline}</h3>
<p>${preset.summary}</p>
</div>
<div class="codex-hcpos-badge">镜像重建 · ${preset.headline} · 近 30 天静态样本</div>
</div>
<div class="codex-hcpos-metrics">${metrics}</div>
<div class="codex-hcpos-layout">
<div class="codex-hcpos-panel">
<h4>趋势概览</h4>
<div class="codex-hcpos-legend">${legend}</div>
${buildTrendSvg(preset.trendSeries, preset.trendLabels)}
</div>
<div class="codex-hcpos-panel">
<h4>结构占比</h4>
<div class="codex-hcpos-segments">${segments}</div>
</div>
<div class="codex-hcpos-panel codex-hcpos-table">
<h4>${preset.rankingTitle}</h4>
<table>
<thead>
<tr><th>#</th><th>项目</th><th>指标值</th><th>完成度</th></tr>
</thead>
<tbody>${rows}</tbody>
</table>
</div>
<div class="codex-hcpos-panel">
<h4>${preset.alertsTitle}</h4>
<div class="codex-hcpos-alerts">${alerts}</div>
</div>
</div>
`;
}
function ensureHcPosStaticPageStyle(doc) {
if (doc.getElementById("__codex_hcpos_static_style__")) {
return;
}
const style = doc.createElement("style");
style.id = "__codex_hcpos_static_style__";
style.textContent = `
.waitMain {
display: none !important;
}
.codex-hcpos-static {
margin: 20px;
padding: 18px 20px 20px;
border-radius: 18px;
background: linear-gradient(180deg, #ffffff 0%, #f8fbff 100%);
border: 1px solid rgba(17,37,63,0.06);
box-shadow: 0 18px 42px rgba(17,37,63,0.08);
}
.codex-hcpos-static-head {
display: flex;
align-items: flex-end;
justify-content: space-between;
gap: 20px;
margin-bottom: 16px;
}
.codex-hcpos-static-eyebrow {
display: inline-flex;
align-items: center;
padding: 4px 10px;
margin-bottom: 8px;
border-radius: 999px;
background: rgba(17,37,63,0.06);
color: #6d7d97;
font-size: 12px;
}
.codex-hcpos-static-head h4 {
margin: 0 0 4px;
color: #152742;
font-size: 24px;
}
.codex-hcpos-static-head p {
margin: 0;
color: #6d7d97;
font-size: 13px;
}
.codex-hcpos-static-badge {
padding: 9px 12px;
border-radius: 14px;
color: #496385;
font-size: 12px;
background: rgba(255,255,255,0.9);
border: 1px solid rgba(17,37,63,0.08);
}
.codex-hcpos-static-cards {
display: grid;
grid-template-columns: repeat(4, minmax(0, 1fr));
gap: 12px;
margin-bottom: 16px;
}
.codex-hcpos-static-card {
padding: 14px 16px;
border-radius: 16px;
background: rgba(255,255,255,0.92);
border: 1px solid rgba(17,37,63,0.05);
}
.codex-hcpos-static-card span {
display: block;
color: #7d8ca5;
font-size: 12px;
}
.codex-hcpos-static-card strong {
display: block;
margin: 8px 0 6px;
color: #152742;
font-size: 28px;
line-height: 1.05;
}
.codex-hcpos-static-card small {
color: #4f6a94;
font-size: 12px;
}
.codex-hcpos-static-table {
overflow: auto;
border-radius: 14px;
border: 1px solid rgba(17,37,63,0.06);
background: #fff;
}
.codex-hcpos-static-table table {
width: 100%;
min-width: 960px;
border-collapse: collapse;
}
.codex-hcpos-static-table th,
.codex-hcpos-static-table td {
padding: 12px 10px;
border-bottom: 1px solid rgba(17,37,63,0.06);
text-align: center;
color: #3f5477;
font-size: 13px;
white-space: nowrap;
}
.codex-hcpos-static-table th {
background: #f9fbff;
color: #7d8ca5;
font-size: 12px;
font-weight: 600;
}
.codex-hcpos-static-table td:first-child,
.codex-hcpos-static-table th:first-child {
text-align: left;
}
@media (max-width: 1080px) {
.codex-hcpos-static-cards {
grid-template-columns: repeat(2, minmax(0, 1fr));
}
.codex-hcpos-overview-cards {
grid-template-columns: repeat(2, minmax(0, 1fr));
}
}
.codex-hcpos-overview {
margin: 18px 0 16px;
padding: 18px 20px;
border-radius: 18px;
background: linear-gradient(180deg, #ffffff 0%, #f8fbff 100%);
border: 1px solid rgba(17,37,63,0.06);
box-shadow: 0 18px 42px rgba(17,37,63,0.08);
}
.codex-hcpos-overview-head h4 {
margin: 0 0 4px;
color: #152742;
font-size: 22px;
}
.codex-hcpos-overview-head p {
margin: 0 0 14px;
color: #6d7d97;
font-size: 13px;
}
.codex-hcpos-overview-eyebrow {
display: inline-flex;
align-items: center;
padding: 4px 10px;
margin-bottom: 8px;
border-radius: 999px;
background: rgba(17,37,63,0.06);
color: #6d7d97;
font-size: 12px;
}
.codex-hcpos-overview-cards {
display: grid;
grid-template-columns: repeat(4, minmax(0, 1fr));
gap: 12px;
}
.codex-hcpos-overview-card {
padding: 14px 16px;
border-radius: 16px;
background: rgba(255,255,255,0.92);
border: 1px solid rgba(17,37,63,0.05);
box-shadow: 0 12px 24px rgba(17,37,63,0.06);
}
.codex-hcpos-overview-card span {
display: block;
color: #7d8ca5;
font-size: 12px;
}
.codex-hcpos-overview-card strong {
display: block;
margin: 8px 0 6px;
color: #152742;
font-size: 28px;
line-height: 1.05;
}
.codex-hcpos-overview-card small {
color: #4f6a94;
font-size: 12px;
}
`;
doc.head.appendChild(style);
}
function renderHcPosStaticPage(doc, presetKey) {
const preset = HCPOS_STATIC_PAGE_PRESETS[presetKey] || HCPOS_FINANCE_REPORT_PRESETS[presetKey] || HCPOS_WAIT_PAGE_PRESETS[presetKey];
if (!preset) {
return;
}
ensureHcPosStaticPageStyle(doc);
doc.querySelectorAll(".waitMain").forEach((node) => {
node.style.display = "none";
});
const activePane = [...doc.querySelectorAll(".el-tab-pane")].find((pane) => {
const styleText = pane.getAttribute("style") || "";
return pane.getAttribute("aria-hidden") !== "true" && !/display\s*:\s*none/i.test(styleText);
});
const waitPane = [...doc.querySelectorAll(".waitMain")].map((node) => node.closest(".el-tab-pane")).find(Boolean);
const host = activePane || waitPane || doc.querySelector(".app-main > div") || doc.querySelector(".app-main > section") || doc.querySelector(".app-main") || doc.body;
if (!host) {
return;
}
const existing = doc.getElementById(`__codex_hcpos_static_${presetKey}__`);
if (existing) {
existing.remove();
}
const section = doc.createElement("section");
section.id = `__codex_hcpos_static_${presetKey}__`;
section.className = "codex-hcpos-static";
const cards = preset.cards.map(
(item) => `
<div class="codex-hcpos-static-card" style="box-shadow: 0 12px 24px ${preset.accentSoft}">
<span>${item.label}</span>
<strong>${item.value}</strong>
<small>${item.detail}</small>
</div>
`
).join("");
const headers = preset.headers.map((header) => `<th>${header}</th>`).join("");
const rows = preset.rows.map((row) => `<tr>${row.map((value) => `<td>${value}</td>`).join("")}</tr>`).join("");
section.innerHTML = `
<div class="codex-hcpos-static-head">
<div>
<span class="codex-hcpos-static-eyebrow">${preset.eyebrow}</span>
<h4>${preset.title}</h4>
<p>${preset.summary}</p>
</div>
<div class="codex-hcpos-static-badge">镜像重建 · 静态样本数据</div>
</div>
<div class="codex-hcpos-static-cards">${cards}</div>
<div class="codex-hcpos-static-table">
<table>
<thead><tr>${headers}</tr></thead>
<tbody>${rows}</tbody>
</table>
</div>
`;
host.appendChild(section);
}
function renderHcPosOverviewPanel(host, preset) {
if (!host || !preset) {
return;
}
ensureHcPosStaticPageStyle(host.ownerDocument);
let panel = host.querySelector(".codex-hcpos-overview");
if (!panel) {
panel = host.ownerDocument.createElement("section");
panel.className = "codex-hcpos-overview";
const search = host.querySelector(".searchStys");
const searchParent = search && search.parentNode;
if (search && searchParent && search.nextSibling) {
searchParent.insertBefore(panel, search.nextSibling);
} else if (search && searchParent) {
searchParent.appendChild(panel);
} else {
host.insertBefore(panel, host.firstChild);
}
}
const cards = preset.cards.map(
(item) => `
<div class="codex-hcpos-overview-card">
<span>${item.label}</span>
<strong>${item.value}</strong>
<small>${item.detail}</small>
</div>
`
).join("");
panel.innerHTML = `
<div class="codex-hcpos-overview-head">
<div>
<span class="codex-hcpos-overview-eyebrow">${preset.eyebrow}</span>
<h4>${preset.title}</h4>
<p>${preset.summary}</p>
</div>
</div>
<div class="codex-hcpos-overview-cards">${cards}</div>
`;
}
function renderHcPosSecondaryTab(doc, presetKey, paneId) {
const preset = HCPOS_SECONDARY_TAB_PRESETS[presetKey];
const pane = doc.getElementById(paneId);
if (!preset || !pane) {
return;
}
ensureHcPosStaticPageStyle(doc);
const existing = pane.querySelector(".codex-hcpos-static");
if (existing) {
existing.remove();
}
pane.querySelectorAll(".waitMain").forEach((node) => {
node.style.display = "none";
});
const section = doc.createElement("section");
section.className = "codex-hcpos-static";
const cards = preset.cards.map(
(item) => `
<div class="codex-hcpos-static-card" style="box-shadow: 0 12px 24px rgba(45,118,255,0.12)">
<span>${item.label}</span>
<strong>${item.value}</strong>
<small>${item.detail}</small>
</div>
`
).join("");
const headers = preset.headers.map((header) => `<th>${header}</th>`).join("");
const rows = preset.rows.map((row) => `<tr>${row.map((value) => `<td>${value}</td>`).join("")}</tr>`).join("");
section.innerHTML = `
<div class="codex-hcpos-static-head">
<div>
<span class="codex-hcpos-static-eyebrow">${preset.eyebrow}</span>
<h4>${preset.title}</h4>
<p>${preset.summary}</p>
</div>
<div class="codex-hcpos-static-badge">镜像重建 · 静态样本数据</div>
</div>
<div class="codex-hcpos-static-cards">${cards}</div>
<div class="codex-hcpos-static-table">
<table>
<thead><tr>${headers}</tr></thead>
<tbody>${rows}</tbody>
</table>
</div>
`;
pane.appendChild(section);
}
function installSimpleTabSwitch(doc, config) {
const { primaryTabId, secondaryTabId, primaryPaneId, secondaryPaneId, storageKey } = config;
const primaryTab = doc.getElementById(primaryTabId);
const secondaryTab = doc.getElementById(secondaryTabId);
const primaryPane = doc.getElementById(primaryPaneId);
const secondaryPane = doc.getElementById(secondaryPaneId);
if (!primaryTab || !secondaryTab || !primaryPane || !secondaryPane) {
return;
}
if (secondaryTab.dataset.codexSwitchInstalled === "1") {
return;
}
secondaryTab.dataset.codexSwitchInstalled = "1";
function syncActiveBar(target) {
const bar = target.closest(".el-tabs")?.querySelector(".el-tabs__active-bar");
if (!bar) {
return;
}
bar.style.width = `${target.offsetWidth}px`;
bar.style.transform = `translateX(${target.offsetLeft}px)`;
}
function activateTab(target) {
const secondaryActive = target === secondaryTab;
primaryTab.classList.toggle("is-active", !secondaryActive);
secondaryTab.classList.toggle("is-active", secondaryActive);
primaryTab.setAttribute("aria-selected", String(!secondaryActive));
secondaryTab.setAttribute("aria-selected", String(secondaryActive));
primaryTab.setAttribute("tabindex", secondaryActive ? "-1" : "0");
secondaryTab.setAttribute("tabindex", secondaryActive ? "0" : "-1");
primaryPane.style.display = secondaryActive ? "none" : "block";
secondaryPane.style.display = secondaryActive ? "block" : "none";
primaryPane.setAttribute("aria-hidden", secondaryActive ? "true" : "false");
secondaryPane.setAttribute("aria-hidden", secondaryActive ? "false" : "true");
syncActiveBar(target);
if (storageKey) {
secondaryPane.ownerDocument.defaultView?.sessionStorage.setItem(storageKey, secondaryActive ? "secondary" : "primary");
}
}
primaryTab.addEventListener("click", () => activateTab(primaryTab), true);
secondaryTab.addEventListener("click", () => activateTab(secondaryTab), true);
const remembered = storageKey && secondaryPane.ownerDocument.defaultView?.sessionStorage.getItem(storageKey) === "secondary" ? secondaryTab : primaryTab;
activateTab(remembered);
}
function ensureHcPosEditableStyle(doc) {
if (doc.getElementById("__codex_hcpos_editable_style__")) {
return;
}
const style = doc.createElement("style");
style.id = "__codex_hcpos_editable_style__";
style.textContent = `
.codex-editable-shell {
position: relative;
}
.codex-editable-toolbar {
position: sticky;
top: 12px;
z-index: 20;
display: flex;
justify-content: flex-end;
gap: 8px;
margin: 0 0 12px;
}
.codex-editable-toolbar button {
border: 1px solid rgba(17,37,63,0.08);
border-radius: 999px;
padding: 6px 12px;
background: rgba(255,255,255,0.92);
color: #35507a;
font-size: 12px;
cursor: pointer;
}
.codex-editable-toolbar button.codex-primary {
background: #2d76ff;
border-color: transparent;
color: #fff;
}
.codex-editable-toolbar button.codex-danger {
color: #d14343;
}
.codex-editable-toolbar button:disabled {
opacity: 0.48;
cursor: not-allowed;
}
.codex-editable-body[contenteditable="true"] {
outline: 2px dashed rgba(45,118,255,0.35);
outline-offset: 8px;
}
.codex-editable-body[contenteditable="true"] a,
.codex-editable-body[contenteditable="true"] button {
pointer-events: none;
}
.codex-editable-hint {
margin-right: auto;
align-self: center;
color: #6d7d97;
font-size: 12px;
}
`;
doc.head.appendChild(style);
}
function createHcPosEditableKey(doc, section, index) {
const pathname = doc.defaultView?.location?.pathname || "unknown";
const paneId = section.closest(".el-tab-pane")?.id || "";
const sectionId = section.id || section.dataset.type || section.className || `section-${index}`;
return `__codex_hcpos_edit__${pathname}::${paneId}::${sectionId}`;
}
function wrapHcPosEditableBody(section) {
let body = section.querySelector(":scope > .codex-editable-body");
if (body) {
return body;
}
body = section.ownerDocument.createElement("div");
body.className = "codex-editable-body";
const nodes = [...section.childNodes];
nodes.forEach((node) => {
body.appendChild(node);
});
section.appendChild(body);
return body;
}
function setHcPosEditableState(doc, section, editing) {
const body = section.querySelector(":scope > .codex-editable-body");
const toolbar = section.querySelector(":scope > .codex-editable-toolbar");
if (!body || !toolbar) {
return;
}
body.contentEditable = editing ? "true" : "false";
body.spellcheck = false;
section.dataset.codexEditing = editing ? "1" : "0";
doc.body.dataset.codexMirrorEditing = editing ? "1" : "0";
toolbar.querySelector("[data-action='edit']").disabled = editing;
toolbar.querySelector("[data-action='save']").disabled = !editing;
}
function bindHcPosEditableSection(doc, section, index) {
ensureHcPosEditableStyle(doc);
section.classList.add("codex-editable-shell");
const body = wrapHcPosEditableBody(section);
const storageKey = createHcPosEditableKey(doc, section, index);
const win = doc.defaultView;
const saved = win?.localStorage.getItem(storageKey);
if (!section.dataset.codexDefaultHtml) {
section.dataset.codexDefaultHtml = body.innerHTML;
}
if (saved && body.innerHTML !== saved && section.dataset.codexEditing !== "1") {
body.innerHTML = saved;
}
let toolbar = section.querySelector(":scope > .codex-editable-toolbar");
if (!toolbar) {
toolbar = doc.createElement("div");
toolbar.className = "codex-editable-toolbar";
toolbar.innerHTML = `
<span class="codex-editable-hint">本地编辑</span>
<button type="button" data-action="edit" class="codex-primary">编辑</button>
<button type="button" data-action="save" disabled>保存</button>
<button type="button" data-action="reset" class="codex-danger">重置</button>
`;
section.insertBefore(toolbar, body);
toolbar.addEventListener("click", (event) => {
const button = event.target.closest("button[data-action]");
if (!button) {
return;
}
const action = button.dataset.action;
if (action === "edit") {
setHcPosEditableState(doc, section, true);
body.focus();
return;
}
if (action === "save") {
win?.localStorage.setItem(storageKey, body.innerHTML);
setHcPosEditableState(doc, section, false);
return;
}
if (action === "reset") {
win?.localStorage.removeItem(storageKey);
body.innerHTML = section.dataset.codexDefaultHtml || body.innerHTML;
setHcPosEditableState(doc, section, false);
}
});
}
setHcPosEditableState(doc, section, false);
}
function installHcPosEditableSections(doc) {
const sections = [
...doc.querySelectorAll("#__codex_hcpos_dashboard__, [id^='__codex_hcpos_static_'], .codex-hcpos-overview, .el-tab-pane > .codex-hcpos-static")
];
const seen = /* @__PURE__ */ new Set();
sections.forEach((section, index) => {
if (!section || seen.has(section)) {
return;
}
seen.add(section);
bindHcPosEditableSection(doc, section, index);
});
}
function getHcPosDangerTableTarget(rowLabel) {
if (rowLabel === "财") {
return { runtime: "hcpos", path: "/propertySMG/businessTaxCank/financeReport/arrearsReport" };
}
if (rowLabel === "人") {
return { runtime: "hcpos", path: "/systemManage/projectConfig/internalControl/ProjectManagerConfig" };
}
return { runtime: "hcpos", path: "/propertySMG/securityProduction/checkStandardLibrary" };
}
function navigateHcPosCockpitLink(target) {
if (!target) {
return;
}
const topWindow = window.top || window;
if (target.runtime === "hcetms") {
const href = `/__mirror/runtime/hc-etms-dashboard/?v=${VERSION || "20260405p"}#${target.path || ""}`;
topWindow.location.href = href;
return;
}
topWindow.location.hash = `#${target.path}`;
}
function resolveHcPosCockpitTarget(node) {
const label = (node.textContent || "").replace(/\s+/g, " ").trim();
if (!label) {
return null;
}
if (HCPOS_COCKPIT_LINKS[label]) {
return HCPOS_COCKPIT_LINKS[label];
}
const cardTitle = node.closest(".flowm-card")?.querySelector(".flowm-card__header span")?.textContent?.replace(/\s+/g, " ").trim();
if (cardTitle && HCPOS_COCKPIT_LINKS[cardTitle]) {
return HCPOS_COCKPIT_LINKS[cardTitle];
}
if (label === "实时校验") {
const top = Math.round(node.getBoundingClientRect().top);
return top >= 1700 ? { runtime: "hcetms", path: "/r2cockpit/cloudData/planTaskReport" } : { runtime: "hcpos", path: "/propertySMG/securityProduction/checkStandardLibrary" };
}
return null;
}
function installHcPosDangerTableLinks(doc) {
const rows = [...doc.querySelectorAll(".dangerous-source-table tbody tr")];
rows.forEach((row) => {
const cells = [...row.querySelectorAll("td")];
const rowLabel = (cells[0]?.textContent || "").replace(/\s+/g, " ").trim();
if (!rowLabel) {
return;
}
cells.slice(1).forEach((cell) => {
if (cell.dataset.codexDangerBound === "1") {
return;
}
cell.style.cursor = "pointer";
cell.addEventListener(
"click",
(event) => {
event.preventDefault();
event.stopPropagation();
navigateHcPosCockpitLink(getHcPosDangerTableTarget(rowLabel));
},
true
);
cell.dataset.codexDangerBound = "1";
});
});
}
function installHcPosCockpitLinks(doc) {
if (!doc.querySelector("#r2-view")) {
return;
}
if (doc.body?.dataset.codexCockpitDelegated !== "1") {
doc.body.addEventListener(
"click",
(event) => {
const targetNode = event.target.closest(".web_head .down_nav a") || event.target.closest(".web_head .item > span") || event.target.closest(".bottom-actions .action-btn") || event.target.closest(".bottom-actions .action-btn span") || event.target.closest(".link-title") || event.target.closest(".flowm-card__header span");
if (!targetNode) {
return;
}
const target = resolveHcPosCockpitTarget(targetNode);
if (!target) {
return;
}
event.preventDefault();
event.stopPropagation();
navigateHcPosCockpitLink(target);
},
true
);
doc.body.dataset.codexCockpitDelegated = "1";
}
const clickableNodes = [
...doc.querySelectorAll(".web_head .down_nav a"),
...doc.querySelectorAll(".web_head .left > .item > span"),
...doc.querySelectorAll(".web_head .right > .item > span"),
...doc.querySelectorAll(".bottom-actions .action-btn"),
...doc.querySelectorAll(".bottom-actions .action-btn span"),
...doc.querySelectorAll(".link-title"),
...doc.querySelectorAll(".flowm-card__header span")
];
clickableNodes.forEach((node) => {
if (node.dataset.codexCockpitBound === "1") {
return;
}
const label = (node.textContent || "").replace(/\s+/g, " ").trim();
const target = resolveHcPosCockpitTarget(node);
if (!target) {
return;
}
node.style.cursor = "pointer";
if (node.tagName === "A") {
node.setAttribute("href", target.runtime === "hcetms" ? `/__mirror/runtime/hc-etms-dashboard/?v=${VERSION || "20260405p"}#${target.path || ""}` : `#${target.path}`);
}
node.addEventListener(
"click",
(event) => {
event.preventDefault();
event.stopPropagation();
navigateHcPosCockpitLink(target);
},
true
);
node.dataset.codexCockpitBound = "1";
});
}
function applyGlobalFrameSkin(iframe) {
try {
const doc = iframe && iframe.contentDocument;
if (!doc || !doc.head) {
return;
}
if (!doc.getElementById("__codex_runtime_frame_skin__")) {
const style = doc.createElement("style");
style.id = "__codex_runtime_frame_skin__";
style.textContent = `
.sidebar-container,
.fixed-header,
.tags-view-container,
.layout-tags-view-container,
.navbar,
.app-breadcrumb,
.el-breadcrumb,
.breadcrumb-container,
.tabList,
.right-menu,
.currentProject,
.AiBox,
.feedback-dialog,
.feedback-btn,
.need-border,
.hamburger-container,
.right-menu-item .international,
.right-menu-item .avatar-container {
display: none !important;
}
.main-container,
.main-container.hasTagsView,
.app-main,
.app-main > section,
.main-container .app-main {
margin: 0 !important;
padding: 0 !important;
width: 100% !important;
}
.el-scrollbar__wrap,
.scrollbar-wrapper {
margin-right: 0 !important;
margin-bottom: 0 !important;
}
body,
html {
background: #f5f7fa !important;
overflow: auto !important;
}
.app-main > section,
.app-main > .app-container,
.app-main .app-container,
.main-container .app-main > section {
padding-top: 0 !important;
}
.el-table__empty-block,
.el-table__empty-text {
display: none !important;
}
`;
doc.head.appendChild(style);
}
const tables = [...doc.querySelectorAll("table")];
const hasDataTable = tables.some((table) => table.querySelectorAll("tbody tr").length > 0);
if (hasDataTable) {
tables.forEach((table) => {
const wrapper = table.closest(".el-table");
const rows = table.querySelectorAll("tbody tr").length;
if (rows > 0) {
if (wrapper) {
wrapper.style.setProperty("display", "block", "important");
}
return;
}
if (wrapper) {
wrapper.style.display = "none";
}
});
}
const src = iframe.getAttribute("src") || "";
const editingActive = doc.body?.dataset.codexMirrorEditing === "1";
if (!editingActive) {
if (src.includes("/propertySMG/cleanManage/cleanMicrobrain/")) {
renderHcPosDashboard(doc, "cleanMicrobrain");
}
if (src.includes("/propertySMG/businessTaxCank/financeMicrobrain/")) {
renderHcPosDashboard(doc, "financeMicrobrain");
}
if (src.includes("/propertySMG/elevatorManage/elevatorDimension/")) {
renderHcPosDashboard(doc, "elevatorDimension");
}
if (src.includes("/propertySMG/equipmentManage/equipmentPortrait/")) {
renderHcPosDashboard(doc, "equipmentPortrait");
}
if (src.includes("/propertySMG/greenManage/greenMicroBrain/")) {
renderHcPosDashboard(doc, "greenMicroBrain");
}
if (src.includes("/propertySMG/parkingOperation/parkingMicroBrain/")) {
renderHcPosDashboard(doc, "parkingMicroBrain");
}
if (src.includes("/propertySMG/securityManage/securityBrain/")) {
renderHcPosDashboard(doc, "securityBrain");
}
if (src.includes("/propertySMG/customerOperations/customerPortrait/")) {
renderHcPosDashboard(doc, "customerPortrait");
}
if (src.includes("/propertySMG/energySourceOperat/notice/")) {
renderHcPosDashboard(doc, "energyNotice");
}
if (src.includes("/homeEnterpriseService/childCare/")) {
renderHcPosStaticPage(doc, "childCare");
}
if (src.includes("/homeEnterpriseService/express/")) {
renderHcPosStaticPage(doc, "express");
}
if (src.includes("/homeEnterpriseService/house/")) {
renderHcPosStaticPage(doc, "house");
}
if (src.includes("/homeEnterpriseService/housekeeping/")) {
renderHcPosStaticPage(doc, "housekeeping");
}
if (src.includes("/homeEnterpriseService/retirement/")) {
renderHcPosStaticPage(doc, "retirement");
}
if (src.includes("/propertySMG/businessTaxCank/bankEnterprise/")) {
renderHcPosStaticPage(doc, "bankEnterprise");
}
if (src.includes("/propertySMG/businessTaxCank/financeAdjust/financialAccount/")) {
renderHcPosStaticPage(doc, "financialAccount");
}
if (src.includes("/propertySMG/businessTaxCank/financeAdjust/financialVoucher/")) {
renderHcPosStaticPage(doc, "financialVoucher");
}
if (src.includes("/propertySMG/businessTaxCank/taxCoordination/")) {
renderHcPosStaticPage(doc, "taxCoordination");
}
if (src.includes("/communitySMG/serviceProvider/")) {
renderHcPosStaticPage(doc, "serviceProvider");
}
if (src.includes("/propertySMG/cleanManage/assessmentTraining/")) {
renderHcPosStaticPage(doc, "cleanAssessmentTraining");
}
if (src.includes("/propertySMG/cleanManage/spareParts/")) {
renderHcPosStaticPage(doc, "cleanSpareParts");
}
if (src.includes("/propertySMG/elevatorManage/assessmentTraining/")) {
renderHcPosStaticPage(doc, "elevatorAssessmentTraining");
}
if (src.includes("/propertySMG/elevatorManage/spareParts/")) {
renderHcPosStaticPage(doc, "elevatorSpareParts");
}
if (src.includes("/propertySMG/equipmentManage/assessmentTraining/")) {
renderHcPosStaticPage(doc, "equipmentAssessmentTraining");
}
if (src.includes("/propertySMG/equipmentManage/spareParts/")) {
renderHcPosStaticPage(doc, "equipmentSpareParts");
}
if (src.includes("/propertySMG/greenManage/assessmentTraining/")) {
renderHcPosStaticPage(doc, "greenAssessmentTraining");
}
if (src.includes("/propertySMG/greenManage/spareParts/")) {
renderHcPosStaticPage(doc, "greenSpareParts");
}
if (src.includes("/propertySMG/securityManage/assessmentTraining/")) {
renderHcPosStaticPage(doc, "securityAssessmentTraining");
}
if (src.includes("/propertySMG/securityManage/spareParts/")) {
renderHcPosStaticPage(doc, "securitySpareParts");
}
if (src.includes("/propertySMG/parkingOperation/assessmentTraining/")) {
renderHcPosStaticPage(doc, "parkingAssessmentTraining");
}
const waitPagePreset = Object.entries(HCPOS_WAIT_PAGE_ROUTE_PRESETS).find(([path]) => src.includes(path));
if (waitPagePreset) {
renderHcPosStaticPage(doc, waitPagePreset[1]);
}
if (src.includes("/communitySMG/personnelList/")) {
renderHcPosOverviewPanel(doc.getElementById("pane-personnelList"), HCPOS_OVERVIEW_PRESETS.personnelList);
renderHcPosSecondaryTab(doc, "keyCustomer", "pane-HEWC");
installSimpleTabSwitch(doc, {
primaryTabId: "tab-personnelList",
secondaryTabId: "tab-HEWC",
primaryPaneId: "pane-personnelList",
secondaryPaneId: "pane-HEWC",
storageKey: "__codex_personnel_list_tab__"
});
}
if (src.includes("/propertySMG/diagnosis/customizedPhysical/")) {
renderHcPosOverviewPanel(doc.getElementById("pane-physicaExamineList"), HCPOS_OVERVIEW_PRESETS.customizedPhysical);
renderHcPosSecondaryTab(doc, "customizedPhysicalRecord", "pane-HEWC");
installSimpleTabSwitch(doc, {
primaryTabId: "tab-physicaExamineList",
secondaryTabId: "tab-HEWC",
primaryPaneId: "pane-physicaExamineList",
secondaryPaneId: "pane-HEWC",
storageKey: "__codex_customized_physical_tab__"
});
}
if (src.includes("/propertySMG/diagnosis/specialPhysical/")) {
renderHcPosOverviewPanel(doc.getElementById("pane-physicaExamineList"), HCPOS_OVERVIEW_PRESETS.specialPhysical);
renderHcPosSecondaryTab(doc, "specialPhysicalRecord", "pane-HEWC");
installSimpleTabSwitch(doc, {
primaryTabId: "tab-physicaExamineList",
secondaryTabId: "tab-HEWC",
primaryPaneId: "pane-physicaExamineList",
secondaryPaneId: "pane-HEWC",
storageKey: "__codex_special_physical_tab__"
});
}
if (src.includes("/propertySMG/diagnosis/5Aphysical/")) {
renderHcPosOverviewPanel(doc.getElementById("pane-physicaExamineList"), HCPOS_OVERVIEW_PRESETS.fiveAPhysical);
renderHcPosSecondaryTab(doc, "fiveAPhysicalRecord", "pane-HEWC");
installSimpleTabSwitch(doc, {
primaryTabId: "tab-physicaExamineList",
secondaryTabId: "tab-HEWC",
primaryPaneId: "pane-physicaExamineList",
secondaryPaneId: "pane-HEWC",
storageKey: "__codex_fivea_physical_tab__"
});
}
if (src.includes("/propertySMG/businessTaxCank/financeReport/balanceSheet/")) {
renderHcPosStaticPage(doc, "balanceSheet");
}
if (src.includes("/propertySMG/businessTaxCank/financeReport/cashFlowStatement/")) {
renderHcPosStaticPage(doc, "cashFlowStatement");
}
if (src.includes("/propertySMG/businessTaxCank/financeReport/incomeStatement/")) {
renderHcPosStaticPage(doc, "incomeStatement");
}
if (src.includes("/propertySMG/businessTaxCank/financeReport/profitSurface/")) {
renderHcPosStaticPage(doc, "profitSurface");
}
if (src.includes("/propertySMG/businessTaxCank/financeReport/projectIncome/")) {
renderHcPosStaticPage(doc, "projectIncome");
}
if (src.includes("/homeEnterpriseService/cafeteria/canteenArchives/")) {
renderHcPosOverviewPanel(doc.querySelector(".app-main > div"), HCPOS_OVERVIEW_PRESETS.canteenArchives);
}
}
if (src.includes("/dataPlatform/home/")) {
installHcPosCockpitLinks(doc);
installHcPosDangerTableLinks(doc);
}
installHcPosEditableSections(doc);
const bodyHeight = doc.body ? doc.body.scrollHeight : 0;
const htmlHeight = doc.documentElement ? doc.documentElement.scrollHeight : 0;
const height = Math.max(bodyHeight, htmlHeight, window.innerHeight - 108, 720);
iframe.style.setProperty("height", `${height}px`, "important");
} catch (_error) {
}
}
function installFrameSkinObserver() {
setInterval(() => {
document.querySelectorAll("iframe").forEach((iframe) => applyGlobalFrameSkin(iframe));
}, 800);
}
const SCRIPT_SRCS = [
"./webpack-runtime.js",
"/static/js/chunk-libs.ee373cfd.js",
"/static/js/app.210977f6.js"
];
function appendStyles() {
STYLE_HREFS.forEach((href) => {
const finalHref = VERSION ? `${href}${href.includes("?") ? "&" : "?"}v=${VERSION}` : href;
if (document.querySelector(`link[href="${finalHref}"]`)) {
return;
}
const link = document.createElement("link");
link.rel = "stylesheet";
link.href = finalHref;
document.head.appendChild(link);
});
}
function injectOuterRuntimeSkin() {
if (document.getElementById("__codex_runtime_outer_skin__")) {
return;
}
const style = document.createElement("style");
style.id = "__codex_runtime_outer_skin__";
style.textContent = `
.AiBox,
.feedback-dialog,
.feedback-btn,
.v-modal {
display: none !important;
}
.app-main,
.app-main > section,
.main-container,
.main-container.hasTagsView {
background: #f3f6fb !important;
}
.fixed-header {
position: sticky !important;
top: 0;
z-index: 10;
box-shadow: 0 4px 18px rgba(17, 37, 63, 0.06);
}
.navbar {
height: 60px !important;
padding: 0 16px !important;
background: rgba(255,255,255,0.94) !important;
backdrop-filter: blur(8px);
}
.breadcrumb-container {
font-size: 13px !important;
}
.right-menu {
gap: 10px;
}
.right-menu .el-select,
.right-menu .currentProject {
max-width: 320px;
}
.tags-view-container {
min-height: 38px !important;
padding: 6px 12px !important;
background: rgba(255,255,255,0.92) !important;
border-bottom: 1px solid rgba(17,37,63,0.06) !important;
}
.tags-view-wrapper .el-scrollbar__view {
display: flex;
align-items: center;
gap: 8px;
}
.tags-view-item {
display: inline-flex !important;
align-items: center;
gap: 6px;
height: 28px;
margin: 0 !important;
padding: 0 12px;
border-radius: 4px 4px 0 0;
border: 1px solid rgba(17, 37, 63, 0.12);
background: #fff;
color: #66758f;
font-size: 13px;
line-height: 28px;
white-space: nowrap;
cursor: default;
}
.tags-view-item.active {
border-color: rgba(45, 118, 255, 0.18);
background: #3a7be0;
color: #fff;
}
.tags-view-item.codex-synthetic-tag {
text-decoration: none;
cursor: pointer;
}
.tags-view-item .el-icon-close {
display: inline-flex !important;
align-items: center;
justify-content: center;
font-size: 12px;
opacity: 0.72;
}
.tags-view-item:first-child .el-icon-close {
display: none !important;
}
.codex-runtime-frame-host {
padding: 14px 16px 20px;
background: #f3f6fb;
}
.codex-runtime-frame {
display: block;
width: 100%;
min-height: 720px;
border: 0;
border-radius: 18px;
background: #fff;
box-shadow: 0 14px 40px rgba(17, 37, 63, 0.08);
}
`;
document.head.appendChild(style);
}
function appendScript(src) {
return new Promise((resolve, reject) => {
const script = document.createElement("script");
script.src = VERSION ? `${src}${src.includes("?") ? "&" : "?"}v=${VERSION}` : src;
script.onload = resolve;
script.onerror = reject;
document.body.appendChild(script);
});
}
async function seedStorage() {
const response = await fetch(VERSION ? `./storage-seed.json?v=${VERSION}` : "./storage-seed.json", { cache: "no-store" });
const payload = await response.json();
Object.entries(payload).forEach(([key, value]) => {
localStorage.setItem(key, value);
});
}
async function seedCookies() {
const response = await fetch(VERSION ? `./cookie-seed.json?v=${VERSION}` : "./cookie-seed.json", { cache: "no-store" });
const payload = await response.json();
Object.entries(payload).forEach(([key, value]) => {
document.cookie = `${key}=${value}; path=/; SameSite=Lax`;
});
}
async function loadRouteMap() {
const response = await fetch(VERSION ? `./route-map.json?v=${VERSION}` : "./route-map.json", { cache: "no-store" });
routeMap = response.ok ? await response.json() : {};
}
async function ensureServiceWorker() {
if (!("serviceWorker" in navigator)) {
return;
}
await navigator.serviceWorker.register("./sw.js", { scope: "./" });
await navigator.serviceWorker.ready;
if (!navigator.serviceWorker.controller && !sessionStorage.getItem("mirror-runtime-sw-reloaded")) {
if (location.hash) {
sessionStorage.setItem("mirror-runtime-target-hash", location.hash);
}
sessionStorage.setItem("mirror-runtime-sw-reloaded", "1");
location.reload();
throw new Error("等待 Service Worker 接管当前页面");
}
sessionStorage.removeItem("mirror-runtime-sw-reloaded");
}
function ensureHashRoute() {
const rememberedHash = sessionStorage.getItem("mirror-runtime-target-hash");
if (rememberedHash) {
if (location.hash !== rememberedHash) {
location.hash = rememberedHash;
}
sessionStorage.removeItem("mirror-runtime-target-hash");
return;
}
if (!location.hash || location.hash === "#" || location.hash === "#/") {
location.hash = ROUTE_HASH;
}
}
function pathFromHash(hash) {
if (!hash) {
return "/dashboard";
}
const value = hash.startsWith("#") ? hash.slice(1) : hash;
const pathOnly = value.split("?")[0];
return pathOnly || "/dashboard";
}
async function waitForVueRoot() {
for (let i = 0; i < 40; i += 1) {
const app = document.querySelector("#app");
const vm = app && app.__vue__;
const router = vm && vm.$router;
if (vm && router) {
return { vm, router };
}
await new Promise((resolve) => setTimeout(resolve, 250));
}
throw new Error("等待 Vue 根实例超时");
}
async function patchRuntimeRoutes() {
if (!routeMap || !Object.keys(routeMap).length) {
return null;
}
const { router } = await waitForVueRoot();
const rootRoute = (router.options.routes || []).find((item) => item.path === "/");
if (!rootRoute || !rootRoute.component) {
return null;
}
const existing = new Set((router.options.routes || []).map((item) => item.path));
const frameComponent = {
name: "HcPosMirrorFrame",
computed: {
frameSrc() {
const config = routeMap[this.$route.path] || { src: "/hc-pos.sqygj.cn/404/" };
return config.src || "/hc-pos.sqygj.cn/404/";
}
},
mounted() {
this.$nextTick(() => applyGlobalFrameSkin(this.$refs.frame));
},
updated() {
this.$nextTick(() => applyGlobalFrameSkin(this.$refs.frame));
},
methods: {
onFrameLoad(event) {
applyGlobalFrameSkin(event.target);
}
},
render(h) {
return h("div", { class: "codex-runtime-frame-host" }, [
h("iframe", {
ref: "frame",
class: "codex-runtime-frame",
attrs: {
src: this.frameSrc,
frameborder: "0"
},
on: {
load: this.onFrameLoad
},
style: {
height: "calc(100vh - 108px)"
}
})
]);
}
};
const children = Object.keys(routeMap).filter((path) => path !== "/dashboard").filter((path) => !existing.has(path)).map((path) => ({
path: path.replace(/^\//, ""),
name: `hcpos-mirror-${path.replace(/[^\w]/g, "-")}`,
meta: { title: routeMap[path] && routeMap[path].title || path.split("/").pop() || path },
component: frameComponent
}));
if (children.length) {
router.addRoutes([
{
path: "/",
component: rootRoute.component,
children
}
]);
}
const currentPath = pathFromHash(INITIAL_HASH || location.hash);
if (currentPath !== "/dashboard" && routeMap[currentPath]) {
router.replace({ path: currentPath });
}
return router;
}
function updateDocumentTitle(path) {
const config = routeMap[path];
if (config && config.title) {
document.title = `${config.title} - 项目运营平台`;
}
}
function getHcPosPresetTags(path) {
const presets = {
"/communitySMG/personnelList": ["首页-工作台", "住户档案", "重点客户"],
"/communitySMG/serviceProvider": ["首页-工作台", "住户档案", "服务商管理"],
"/homeEnterpriseService/cafeteria/canteenArchives": ["首页-工作台", "食堂档案", "社区幼托", "房屋经纪", "快递收发", "社区养老", "社区家政"],
"/homeEnterpriseService/childCare": ["首页-工作台", "食堂档案", "社区幼托", "房屋经纪", "快递收发", "社区养老", "社区家政"],
"/homeEnterpriseService/house": ["首页-工作台", "食堂档案", "社区幼托", "房屋经纪", "快递收发", "社区养老", "社区家政"],
"/homeEnterpriseService/express": ["首页-工作台", "食堂档案", "社区幼托", "房屋经纪", "快递收发", "社区养老", "社区家政"],
"/homeEnterpriseService/retirement": ["首页-工作台", "食堂档案", "社区幼托", "房屋经纪", "快递收发", "社区养老", "社区家政"],
"/homeEnterpriseService/housekeeping": ["首页-工作台", "食堂档案", "社区幼托", "房屋经纪", "快递收发", "社区养老", "社区家政"],
"/propertySMG/diagnosis/customizedPhysical": ["首页-工作台", "5A测评", "专项测评", "定制测评"],
"/propertySMG/diagnosis/specialPhysical": ["首页-工作台", "5A测评", "专项测评", "定制测评"],
"/propertySMG/diagnosis/5Aphysical": ["首页-工作台", "5A测评", "专项测评", "定制测评"],
"/propertySMG/businessTaxCank/bankEnterprise": ["首页-工作台", "银企直联", "财务核算", "财务凭证", "税务统筹", "财务看板"],
"/propertySMG/businessTaxCank/financeAdjust/financialAccount": ["首页-工作台", "银企直联", "财务核算", "财务凭证", "税务统筹", "财务看板"],
"/propertySMG/businessTaxCank/financeAdjust/financialVoucher": ["首页-工作台", "银企直联", "财务核算", "财务凭证", "税务统筹", "财务看板"],
"/propertySMG/businessTaxCank/taxCoordination": ["首页-工作台", "银企直联", "财务核算", "财务凭证", "税务统筹", "财务看板"],
"/propertySMG/businessTaxCank/financeMicrobrain": ["首页-工作台", "银企直联", "财务核算", "财务凭证", "税务统筹", "财务看板"],
"/propertySMG/businessTaxCank/financeReport/balanceSheet": ["首页-工作台", "资产负债表", "现金流量表", "全年收入报表", "利润表", "项目收支表"],
"/propertySMG/businessTaxCank/financeReport/cashFlowStatement": ["首页-工作台", "资产负债表", "现金流量表", "全年收入报表", "利润表", "项目收支表"],
"/propertySMG/businessTaxCank/financeReport/incomeStatement": ["首页-工作台", "资产负债表", "现金流量表", "全年收入报表", "利润表", "项目收支表"],
"/propertySMG/businessTaxCank/financeReport/profitSurface": ["首页-工作台", "资产负债表", "现金流量表", "全年收入报表", "利润表", "项目收支表"],
"/propertySMG/businessTaxCank/financeReport/projectIncome": ["首页-工作台", "资产负债表", "现金流量表", "全年收入报表", "利润表", "项目收支表"],
"/propertySMG/cleanManage/cleanMicrobrain": ["首页-工作台", "清洁看板", "绿化看板", "安防看板", "设备看板", "电梯看板", "车场看板"],
"/propertySMG/cleanManage/assessmentTraining": [
{ title: "首页-工作台", path: "/dashboard" },
{ title: "清洁看板", path: "/propertySMG/cleanManage/cleanMicrobrain" },
{ title: "考核培训", path: "/propertySMG/cleanManage/assessmentTraining" },
{ title: "备品备件", path: "/propertySMG/cleanManage/spareParts" }
],
"/propertySMG/cleanManage/spareParts": [
{ title: "首页-工作台", path: "/dashboard" },
{ title: "清洁看板", path: "/propertySMG/cleanManage/cleanMicrobrain" },
{ title: "考核培训", path: "/propertySMG/cleanManage/assessmentTraining" },
{ title: "备品备件", path: "/propertySMG/cleanManage/spareParts" }
],
"/propertySMG/greenManage/greenMicroBrain": ["首页-工作台", "清洁看板", "绿化看板", "安防看板", "设备看板", "电梯看板", "车场看板"],
"/propertySMG/greenManage/assessmentTraining": [
{ title: "首页-工作台", path: "/dashboard" },
{ title: "绿化看板", path: "/propertySMG/greenManage/greenMicroBrain" },
{ title: "考核培训", path: "/propertySMG/greenManage/assessmentTraining" },
{ title: "备品备件", path: "/propertySMG/greenManage/spareParts" }
],
"/propertySMG/greenManage/spareParts": [
{ title: "首页-工作台", path: "/dashboard" },
{ title: "绿化看板", path: "/propertySMG/greenManage/greenMicroBrain" },
{ title: "考核培训", path: "/propertySMG/greenManage/assessmentTraining" },
{ title: "备品备件", path: "/propertySMG/greenManage/spareParts" }
],
"/propertySMG/securityManage/securityBrain": ["首页-工作台", "清洁看板", "绿化看板", "安防看板", "设备看板", "电梯看板", "车场看板"],
"/propertySMG/securityManage/assessmentTraining": [
{ title: "首页-工作台", path: "/dashboard" },
{ title: "安防看板", path: "/propertySMG/securityManage/securityBrain" },
{ title: "考核培训", path: "/propertySMG/securityManage/assessmentTraining" },
{ title: "备品备件", path: "/propertySMG/securityManage/spareParts" }
],
"/propertySMG/securityManage/spareParts": [
{ title: "首页-工作台", path: "/dashboard" },
{ title: "安防看板", path: "/propertySMG/securityManage/securityBrain" },
{ title: "考核培训", path: "/propertySMG/securityManage/assessmentTraining" },
{ title: "备品备件", path: "/propertySMG/securityManage/spareParts" }
],
"/propertySMG/equipmentManage/equipmentPortrait": ["首页-工作台", "清洁看板", "绿化看板", "安防看板", "设备看板", "电梯看板", "车场看板"],
"/propertySMG/equipmentManage/assessmentTraining": [
{ title: "首页-工作台", path: "/dashboard" },
{ title: "设备看板", path: "/propertySMG/equipmentManage/equipmentPortrait" },
{ title: "考核培训", path: "/propertySMG/equipmentManage/assessmentTraining" },
{ title: "备品备件", path: "/propertySMG/equipmentManage/spareParts" }
],
"/propertySMG/equipmentManage/spareParts": [
{ title: "首页-工作台", path: "/dashboard" },
{ title: "设备看板", path: "/propertySMG/equipmentManage/equipmentPortrait" },
{ title: "考核培训", path: "/propertySMG/equipmentManage/assessmentTraining" },
{ title: "备品备件", path: "/propertySMG/equipmentManage/spareParts" }
],
"/propertySMG/elevatorManage/elevatorDimension": ["首页-工作台", "清洁看板", "绿化看板", "安防看板", "设备看板", "电梯看板", "车场看板"],
"/propertySMG/elevatorManage/assessmentTraining": [
{ title: "首页-工作台", path: "/dashboard" },
{ title: "电梯看板", path: "/propertySMG/elevatorManage/elevatorDimension" },
{ title: "考核培训", path: "/propertySMG/elevatorManage/assessmentTraining" },
{ title: "备品备件", path: "/propertySMG/elevatorManage/spareParts" }
],
"/propertySMG/elevatorManage/spareParts": [
{ title: "首页-工作台", path: "/dashboard" },
{ title: "电梯看板", path: "/propertySMG/elevatorManage/elevatorDimension" },
{ title: "考核培训", path: "/propertySMG/elevatorManage/assessmentTraining" },
{ title: "备品备件", path: "/propertySMG/elevatorManage/spareParts" }
],
"/propertySMG/parkingOperation/parkingMicroBrain": ["首页-工作台", "清洁看板", "绿化看板", "安防看板", "设备看板", "电梯看板", "车场看板"],
"/propertySMG/parkingOperation/assessmentTraining": [
{ title: "首页-工作台", path: "/dashboard" },
{ title: "车场看板", path: "/propertySMG/parkingOperation/parkingMicroBrain" },
{ title: "考核培训", path: "/propertySMG/parkingOperation/assessmentTraining" }
],
"/propertySMG/customerOperations/customerPortrait": ["首页-工作台", "客户画像", "服务商管理", "住户档案"],
"/propertySMG/energySourceOperat/notice": ["首页-工作台", "能源看板", "设备看板", "车场看板"]
};
return presets[path] || null;
}
function getHcPosTagRoute(title) {
const routeMapByTitle = {
"首页-工作台": "/dashboard",
"住户档案": "/communitySMG/personnelList",
"重点客户": "/communitySMG/personnelList",
"服务商管理": "/communitySMG/serviceProvider",
"食堂档案": "/homeEnterpriseService/cafeteria/canteenArchives",
"社区幼托": "/homeEnterpriseService/childCare",
"房屋经纪": "/homeEnterpriseService/house",
"快递收发": "/homeEnterpriseService/express",
"社区养老": "/homeEnterpriseService/retirement",
"社区家政": "/homeEnterpriseService/housekeeping",
"5A测评": "/propertySMG/diagnosis/5Aphysical",
"专项测评": "/propertySMG/diagnosis/specialPhysical",
"定制测评": "/propertySMG/diagnosis/customizedPhysical",
"银企直联": "/propertySMG/businessTaxCank/bankEnterprise",
"财务核算": "/propertySMG/businessTaxCank/financeAdjust/financialAccount",
"财务凭证": "/propertySMG/businessTaxCank/financeAdjust/financialVoucher",
"税务统筹": "/propertySMG/businessTaxCank/taxCoordination",
"财务看板": "/propertySMG/businessTaxCank/financeMicrobrain",
"资产负债表": "/propertySMG/businessTaxCank/financeReport/balanceSheet",
"现金流量表": "/propertySMG/businessTaxCank/financeReport/cashFlowStatement",
"全年收入报表": "/propertySMG/businessTaxCank/financeReport/incomeStatement",
"利润表": "/propertySMG/businessTaxCank/financeReport/profitSurface",
"项目收支表": "/propertySMG/businessTaxCank/financeReport/projectIncome",
"清洁看板": "/propertySMG/cleanManage/cleanMicrobrain",
"绿化看板": "/propertySMG/greenManage/greenMicroBrain",
"安防看板": "/propertySMG/securityManage/securityBrain",
"设备看板": "/propertySMG/equipmentManage/equipmentPortrait",
"电梯看板": "/propertySMG/elevatorManage/elevatorDimension",
"车场看板": "/propertySMG/parkingOperation/parkingMicroBrain",
"客户画像": "/propertySMG/customerOperations/customerPortrait",
"能源看板": "/propertySMG/energySourceOperat/notice"
};
return routeMapByTitle[title] || "/dashboard";
}
function getHcPosTagLabel(node) {
const cloned = node.cloneNode(true);
cloned.querySelectorAll(".el-icon-close").forEach((icon) => icon.remove());
return (cloned.textContent || "").trim();
}
function createHcPosSyntheticTag(title, path, active) {
const anchor = document.createElement("a");
anchor.href = `#${path}`;
anchor.className = `tags-view-item codex-synthetic-tag${active ? " active" : ""}`;
anchor.appendChild(document.createTextNode(title));
if (title !== "首页-工作台") {
const close = document.createElement("span");
close.className = "el-icon-close";
anchor.appendChild(close);
}
return anchor;
}
function hydrateHcPosTagsView(path) {
const view = document.querySelector(".tags-view-container .el-scrollbar__view");
if (!view) {
return;
}
const preset = getHcPosPresetTags(path);
view.querySelectorAll(".codex-synthetic-tag").forEach((node) => node.remove());
if (!preset) {
return;
}
const existingNodes = [...view.querySelectorAll(".tags-view-item:not(.codex-synthetic-tag)")];
const existingMap = new Map(existingNodes.map((node) => [getHcPosTagLabel(node), node]));
const activeTitle = routeMap[path] && routeMap[path].title || getHcPosTagLabel(view.querySelector(".tags-view-item.active") || document.createElement("span"));
preset.forEach((item) => {
const title = typeof item === "string" ? item : item.title;
const itemPath = typeof item === "string" ? getHcPosTagRoute(title) : item.path;
let node = existingMap.get(title);
if (!node) {
node = createHcPosSyntheticTag(title, itemPath, itemPath === path || title === activeTitle);
}
if (itemPath === path || title === activeTitle) {
node.classList.add("active");
} else {
node.classList.remove("active");
}
view.appendChild(node);
});
}
function scheduleHcPosTagsViewHydration(path) {
let tries = 0;
const timer = setInterval(() => {
tries += 1;
hydrateHcPosTagsView(path);
if (tries >= 8) {
clearInterval(timer);
}
}, 300);
}
function installRouteBridge(router) {
if (!router || window.__HCPOS_RUNTIME_BRIDGE_INSTALLED__) {
return;
}
window.__HCPOS_RUNTIME_BRIDGE_INSTALLED__ = true;
document.addEventListener(
"click",
(event) => {
const anchor = event.target && event.target.closest ? event.target.closest("a[href]") : null;
if (!anchor) {
return;
}
const href = anchor.getAttribute("href") || "";
if (!href.startsWith("#/")) {
return;
}
event.preventDefault();
const path = href.slice(1).split("?")[0] || "/dashboard";
if (routeMap[path]) {
router.replace({ path });
updateDocumentTitle(path);
} else {
router.replace({ path: "/dashboard" });
}
},
true
);
router.afterEach((to) => {
updateDocumentTitle(to.path);
scheduleHcPosTagsViewHydration(to.path);
});
}
function hideLoading() {
const loading = document.getElementById("mirror-loading");
if (loading) {
loading.style.display = "none";
}
}
try {
await seedStorage();
await seedCookies();
await loadRouteMap();
await ensureServiceWorker();
ensureHashRoute();
appendStyles();
injectOuterRuntimeSkin();
for (const src of SCRIPT_SRCS) {
await appendScript(src);
}
const router = await patchRuntimeRoutes();
installRouteBridge(router);
const initialPath = pathFromHash(location.hash);
updateDocumentTitle(initialPath);
hideLoading();
scheduleHcPosTagsViewHydration(initialPath);
installFrameSkinObserver();
} catch (error) {
const loading = document.getElementById("mirror-loading");
if (loading) {
const detail = document.createElement("small");
detail.textContent = String(error && error.message ? error.message : error);
loading.appendChild(detail);
}
}
})();