1006 B
1006 B
Change: Add agent distribution code viewing
Why
Agent accounts need a quick way to share their shop's distribution code. The authenticated user response already provides shop_id, and the shop detail endpoint returns distribution_code, but the agent home page does not expose or display it.
What Changes
- Add a “查看我的分销码” shortcut immediately after “提现管理” on the agent home page, visible only when
user_typeis3. - Add a distribution-code page that uses the current authenticated user's
shop_idto fetch/api/admin/shops/{shop_id}and renders the returneddistribution_codeas a QR code. - Reuse the existing
src/static/icons/分销码.pngshortcut icon.
Impact
- Affected specs:
agent-distribution-code(new capability) - Affected code:
src/pages/agent-system/home/index.vue,src/pages/agent-system/distribution-code/index.vue,src/pages.json, and the shop API module; a Uni-app-compatible local QR renderer may require a dependency.