Files
platforms/apps/service_app/README.md

27 lines
1.1 KiB
Markdown
Raw Permalink 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.
# 瓶安芯服务工作台
配送员、安装维修员和安检员共用的 Android/iOS/Web Flutter 客户端。首期一账号一角色,统一访问 `/heqi/client/v1/staff`
## 本地运行
```bash
flutter pub get
flutter run --dart-define=API_BASE_URL=http://10.0.2.2:12426
```
Android 模拟器访问宿主机使用 `10.0.2.2`iOS Simulator 使用 `http://127.0.0.1:12426`。Release 环境必须注入 HTTPS 地址。
现场照片、签名和表单先按账号使用 AES-GCM 加密暂存。离线只表示“已暂存”,打卡、开始、异常、恢复、到达、签收与最终提交都必须获得服务端在线确认。
## 质量检查
```bash
flutter analyze
flutter test
flutter build apk --debug
flutter build ios --simulator --no-codesign
flutter build web --release --dart-define=API_BASE_URL=https://api.example.com
```
仓库根目录可使用 `API_BASE_URL=https://api.example.com ./scripts/build-apps.sh service_app all` 同时生成 Android 和 Web 产物。Web 端支持登录、任务处理、按浏览器授权采集位置和相机取证,但不支持 Android/iOS 的后台定位保障;生产环境必须使用 HTTPS API 地址。