Files
device-voice-h5/openspec/changes/update-july-h5-c-iteration/specs/asset-realname-flow/spec.md
luo 4f281da778
All checks were successful
构建并部署前端到生产环境 / build-and-deploy (push) Successful in 1m11s
feat: 7月迭代
2026-07-27 18:13:19 +08:00

1.8 KiB

ADDED Requirements

Requirement: Real-name behavior SHALL use the effective backend asset policy

The H5/C client SHALL use GET /api/c/v1/asset/info?identifier=... as the source of truth for real-name behavior. It SHALL consume effective_realname_policy, realname_required, and real_name_status and SHALL NOT infer policy or final device real-name status from asset type, card type, device type, or frontend-only rules.

Scenario: Asset does not require real name

  • WHEN asset information returns effective_realname_policy = none or realname_required = false
  • THEN the client SHALL show the asset as not requiring real-name completion
  • AND the client SHALL not block the normal order flow for real-name completion

Scenario: Real name is required before ordering

  • WHEN asset information returns effective_realname_policy = before_order, realname_required = true, and real_name_status as not completed
  • THEN the client SHALL show the real-name requirement
  • AND the client SHALL prevent package order submission until the existing real-name flow completes

Scenario: Real name is required after ordering

  • WHEN asset information returns effective_realname_policy = after_order
  • THEN the client SHALL allow the policy-defined post-order flow to proceed without applying a before-order block
  • AND the client SHALL display the returned real-name status and retain the existing real-name action entry when completion is needed

Scenario: Device status is resolved from server output

  • WHEN a device has cards with different local-looking real-name states but the asset info response returns the effective device real_name_status
  • THEN the client SHALL display and use that returned effective status
  • AND the client SHALL not replace it with a card/device inference