Files
one-pipe-system/openspec/changes/update-admin-asset-device-signal-and-audit-logs/proposal.md
sexygoat 81155fd8e4
All checks were successful
构建并部署前端到测试环境 / build-and-deploy (push) Successful in 4m44s
fix:进度条
2026-04-30 17:01:00 +08:00

2.7 KiB
Raw Blame History

Change: 更新后台资产信息设备信号摘要与操作审计日志展示

Why

当前后台资产信息页与操作审计日志展示和最新接口/产品口径存在两类偏差:

  • 设备实时信息仍以前端推导的“信号强度”加 RSSI/RSRP/RSRQ/SINR 原始字段为主,而最新需求要求后台直接展示后端摘要字段 signal_qualitysignal_bad_reason
  • 资产操作审计日志接口已经补充了更多可直接面向运营展示的业务字段,但前端仍可能显示内部 xxxid/xxxID 或缺少对可读字段的系统性支持。

如果不收敛这两类差异,后台页面会继续出现“展示口径与接口设计不一致”“日志可读性不足”的问题。

本提案仅覆盖后台管理端admin能力不包含 C 端接口和 C 端页面。

What Changes

  • 更新后台“资产信息”中的设备实时信息展示:
    • 接入并展示 data.device_realtime.signal_quality
    • 接入并展示 data.device_realtime.signal_bad_reason
    • 从后台页面移除 RSSI/RSRP/RSRQ/SINR 及前端推导的旧“信号强度”展示
    • 保留原始信号字段在类型契约中的可用性,但不再作为后台页面主展示内容
  • 更新后台“资产操作审计日志”展示:
    • 支持直接展示 operation_content_before / operation_content_after 中新增的可读业务字段
    • 优先展示 iccidiccidsdevice_virtual_nodevice_virtual_nosdevice_imeidevice_snshop_nameto_shop_nametarget_shop_namesource_shop_name
    • 统一隐藏内部 id / *_id / *Id / *ID 字段,避免继续向运营暴露内部标识
    • 明确覆盖 card_allocatecard_recalldevice_allocatedevice_recalldevice_bind_carddevice_unbind_card 等关键日志类型
  • 范围约束:
    • 不修改 C 端 spec
    • 不要求本次提案改造 C 端接口消费逻辑
    • 不改变后端接口路径、HTTP 方法和返回字段命名

Impact

  • Affected specs:
    • asset-information
    • asset-operation-logs
  • Affected code:
    • src/types/api/asset.ts
    • src/views/asset-management/asset-information/components/BasicInfoCard.vue
    • src/views/asset-management/asset-information/composables/useAssetFormatters.ts
    • src/views/asset-management/asset-information/components/OperationLogsCard.vue
    • src/components/business/OperationLogsDialog.vue
  • Dependencies:
    • 与活跃变更 update-order-upload-and-device-switch-mode 存在同页组件交集,实施前需要先对齐 BasicInfoCard.vue 的最新状态
    • 依赖后端已按文档提供 admin 侧新增字段与日志内容
  • Breaking changes:
    • 无外部接口破坏性变更;本次主要是后台展示契约与类型定义的增量调整