Files
luo f2614d8efb
All checks were successful
构建并部署前端到测试环境 / deploy (push) Successful in 54s
fix: some
2026-10-28 15:18:44 +08:00

4.3 KiB
Raw Blame History

ADDED Requirements

Requirement: 订单分类与角色边界

The admin frontend SHALL expose independent platform, agent and online order pages using the corresponding documented endpoints and export scenes without category query parameters. It MUST preserve legacy order history and the shared detail contract. Enterprise accounts MUST not query or mutate orders, and agents MUST not access online orders.

Scenario: 分类查询和导出

  • WHEN 平台账号打开某类订单或创建该类导出
  • THEN 请求 MUST 使用对应路径和 scene,保留原筛选,不改变订单详情接口。

Scenario: 不允许的账号

  • WHEN 企业账号尝试进入订单页,或代理进入在线订单
  • THEN 菜单和页面请求 MUST 被限制,不以按钮授权覆盖身份限制。

Requirement: 企业资产操作限制

The frontend SHALL hide and block expiry adjustment, used-data adjustment, deactivation, polling toggle and realname-status adjustment for enterprise accounts across all existing asset entrypoints while preserving authorized start/stop and reads. A not-found asset response MUST remain ordinary not-found feedback.

Scenario: 已授权企业资产

  • WHEN 企业账号查看已授权卡或设备
  • THEN 五项禁止操作 MUST 不可见且处理函数不能提交,停复机仍按原权限可用。

Requirement: 套餐默认沉默期与购买覆盖

The frontend SHALL distinguish package defaults (1–90 days), purchase overrides (minimum 1, no documented upper bound) and backend-priced extensions. Formal activation-based packages MUST require defaults with 30 days prefilled only for creation; addons MUST omit silence fields. Forbidden expiry-base transitions MUST be prevented where source data is known and backend rejection preserved otherwise.

Scenario: 默认配置

  • WHEN 新建实名即生效正式套餐或将购买生效改为实名生效
  • THEN 保存 MUST 携带有效 silence_period_days,不能从实名改为购买生效。

Scenario: 单次购买覆盖

  • WHEN 有 override 权限的用户填写本次沉默期
  • THEN 请求 MUST 同时包含有效天数与原因;无权限或未填写时不发覆盖字段,等待审批不能显示为已延期。

Requirement: 可选沉默期与首次购买事实展示

The frontend SHALL show silence status and timestamps only when the server returns the applicable silence object. First-purchase timestamps SHALL remain read-only server facts with shared range filtering/export and generation history, never synthesized for bound cards or exchanges.

Scenario: 总开关关闭

  • WHEN 套餐响应不包含 silence
  • THEN 沉默期状态及延期入口 MUST 隐藏,不推算默认截止时间。

Scenario: 首次购买范围

  • WHEN 用户按首次购买时间查询卡或设备并导出
  • THEN 列表和导出 MUST 使用相同 RFC3339 范围,空时间仍显示为空且不开放修改。

Requirement: 延期与审批使用真实后端契约

The frontend SHALL use documented eligibility, quote, payment, special extension, policy, batch and history contracts. Amounts and state transitions MUST remain backend facts. Undefined DTO fields or money units MUST be reported as missing prerequisites rather than implemented through guessed writes or arbitrary JSON forms.

Scenario: 缺少财务契约

  • WHEN 汇总未定义政策保存字段、金额单位或收款结构且权威文档不可用
  • THEN 对应实现项 MUST 保持未完成,交付说明准确列出需要补充的契约。

Scenario: 专用总开关与错误反馈

  • WHEN 超管切换总开关或后端拒绝延期
  • THEN 前端 MUST 走专用开关接口并展示 precheck/failed_items 或具体错误;不得用通用系统配置绕过检查。

Requirement: 交付与验证边界

The change SHALL preserve existing routes, permissions, worktree edits and successful payment/approval behaviors. It MUST include targeted regression tests and an actual menu/permission handoff, excluding superadmin-only configuration from ordinary-user setup. H5/C-end work and real-backend validation MUST be disclosed separately.

Scenario: 执行交付

  • WHEN 本轮工作停止或完成
  • THEN 交付 MUST 区分已实现、已本地验证、真实联调待办与缺契约未实现项,不以 mock 或服务数量宣称全部完成。