Files
arcx-app/datas/data.md
T
2026-08-08 11:20:14 +08:00

22 lines
2.4 KiB
Markdown
Raw Blame History

This file contains ambiguous Unicode characters
This file contains Unicode characters that might be confused with other characters. If you think that this is intentional, you can safely ignore this warning. Use the Escape button to reveal them.
## 接口与数据文件清单
进入 `point-book.vue` 页面调用的接口(已排除个人信息 `getHomeData`),均来自**测试环境** `apitest.shelingxingqiu.com`
| # | 接口函数 | URL | 调用时机 | 数据文件 |
| --- | ---------------------------- | ------------------------------------------------------------------- | ------------------ | ----------------------------------------------------------------------------------------------------------------------------- |
| 1 | `getPointBookConfigAPI` | `GET /user/score/sheet/option` | onMounted | [getPointBookConfigAPI.json](file:///Users/ZhuanZ/Documents/gdfw/shoot-miniprograms/datas/getPointBookConfigAPI.json) |
| 2 | `getPointBookStatisticsAPI` | `GET /v2/user/score/sheet/statistics` | onShow / user 变化 | [getPointBookStatisticsAPI.json](file:///Users/ZhuanZ/Documents/gdfw/shoot-miniprograms/datas/getPointBookStatisticsAPI.json) |
| 3 | `getPointBookRankListAPI(1)` | `GET /user/score/sheet/week/shoot/rank/list?pageNum=1&pageSize=100` | onShow | [getPointBookRankListAPI.json](file:///Users/ZhuanZ/Documents/gdfw/shoot-miniprograms/datas/getPointBookRankListAPI.json) |
## 关于环境的说明
之前失败是因为我默认请求了生产环境 `api.shelingxingqiu.com`,而你的 token 是测试环境签发的(小程序 envVersion 为 develop/trial 时走 `apitest.shelingxingqiu.com`,见 [apis.js:9-20](file:///Users/ZhuanZ/Documents/gdfw/shoot-miniprograms/src/apis.js#L9-L20))。切换到测试环境后三个接口均返回 `code:0` 成功。
## 数据结构说明
每个 JSON 文件保存的是接口响应中 `data` 字段的内容(与前端 `request` 函数 resolve 的结果一致,见 [apis.js:50](file:///Users/ZhuanZ/Documents/gdfw/shoot-miniprograms/src/apis.js#L50))。
- **Config**`bowOption`(5种弓) + `targetOption`(10种靶),两环境数据一致
- **Statistics**:签到/今日与累计箭数/训练天数/黄心率/平均环数/各环数分布/本周箭着点坐标(当前 `weekArrows` 为空)
- **Rank**`my`(当前用户) + `list`(榜单,本周共2人上榜) + `total`