新增举报摄影师模块并接入首页路由,桌面应用名改为随心瞰商家版。

Co-authored-by: Cursor <cursoragent@cursor.com>
This commit is contained in:
2026-07-01 16:51:22 +08:00
parent 19d681192c
commit fcb86d43f5
25 changed files with 5515 additions and 48 deletions

View File

@ -0,0 +1,66 @@
# WildPhotographerReport 模块业务逻辑
## 模块职责
WildPhotographerReport 模块负责首页 `photographer_report` 入口,为摄影师和景区运营提供「举报摄影师」能力。
本模块与 `LocationReport`(位置上报)无关:前者是用户举报疑似打野/未戴工牌摄影师,后者是摄影师 GPS 打卡。
当前阶段使用 Mock 数据完成业务闭环,不接入真实后端接口。
## 页面流程
```mermaid
flowchart TD
Home[举报摄影师首页] --> Submit[提交举报]
Home --> List[我的举报]
Home --> Map[附近风险地图]
Home --> Rules[举报规则]
Submit -->|提交成功| Success[举报成功]
Success --> Detail[举报详情]
List --> Detail
Detail --> Supplement[补充证据]
Detail --> Map
```
## 核心实体
| 类型 | 说明 |
| --- | --- |
| `WildReportType` | 举报类型:疑似打野 / 未戴工牌 / 其他 |
| `WildReportStatus` | 处理状态:待处理 / 处理中 / 已处理 |
| `WildReportRecord` | 举报记录 |
| `WildReportRiskPoint` | 附近风险点 |
| `WildReportSupplementaryEvidence` | 补充证据 |
## 数据来源
- 全部 Mock 数据由 `WildPhotographerReportMockStore` 提供种子数据。
- `WildPhotographerReportHomeViewModel` 持有共享举报列表,提交页、列表页、详情页通过依赖注入共享。
- 提交页定位使用 `ForegroundLocationProvider` 前台即时定位;失败时回退到 `fallbackLocation`
## 提交规则
1. 图片或视频至少上传一项。
2. 举报说明必填,最多 500 字。
3. 举报位置必须已确认。
4. 举报类型默认「疑似打野」。
5. 提交成功后生成 `JB` + 日期 + 3 位序号,状态为「待处理」。
## 路由
- 权限 URI`photographer_report`
- 首页路由:`HomeRoute.photographerReport`
- 入口不固定置顶,依赖权限下发或用户手动添加到常用应用(`HomeCommonMenuStore.androidHomeMenuURIs` 白名单已包含该 URI
## 与 LocationReport 的边界
| 模块 | URI | 用途 | 后端 |
| --- | --- | --- | --- |
| WildPhotographerReport | `photographer_report` | 举报摄影师 | Mock |
| LocationReport | `location_report` | 位置上报 | 真实 API |
## 测试要求
- `WildPhotographerReportTests`Home/Submit/List ViewModel 校验与提交成功路径。
- `HomeMenuRouterTests``photographer_report` 路由映射。