Files
PackagingMallShipper/README.md
key fb65dceaa0 feat: 切换到商户号子账号登录端点 + 项目清理
- AuthService: 改用 http://common.apifm.com/loginAdmin/operator/v2 商户号登录
  * 验证码和登录统一使用该主机以保持 JSESSIONID 一致
  * 改用 FormUrlEncodedContent POST body
  * 未配置 MerchantId 时回退到旧的 pdomain 登录方式
- AppConfig: 新增 MerchantId 配置项
- App.config: 新增 MerchantId=15073
- LoginViewModel: captchaKey 由 GUID 改为 JS Math.random 风格 0.xxx
- setup.iss: 修复 GBK 编码损坏导致的字符串未闭合错误,改为 UTF-8 BOM
- README: 更新配置示例与相关文档链接
- .gitignore: 忽略 .env 本地密钥文件
- 清理过时/无关文档与未引用的 SFX 打包脚本
2026-04-17 12:03:15 +08:00

112 lines
3.1 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.
# 包装商城发货助手
> 轻量级订单发货客户端,专为子账号管理员设计
## 功能特性
- ✅ 手机号登录API工厂认证
- ✅ 订单列表查看本地SQLite缓存
- ✅ 订单同步(增量/全量)
- ✅ 单个订单发货
- ✅ 批量发货(并发控制)
- ✅ 导出待发货订单Excel
- ✅ 导入快递单号批量发货
- ✅ 离线查看缓存订单
## 技术栈
| 组件 | 技术 | 版本 |
|-----|------|------|
| 桌面框架 | WPF | .NET Framework 4.6.2 |
| 架构模式 | MVVM | CommunityToolkit.Mvvm 8.2 |
| 本地数据库 | SQLite | System.Data.SQLite 1.0.118 |
| Excel处理 | ClosedXML | 0.102.2 |
| JSON处理 | Newtonsoft.Json | 13.0.3 |
## 系统要求
- **操作系统**: Windows 7 SP1 或更高版本
- **运行时**: .NET Framework 4.6.2Win7 SP1 原生支持)
- **磁盘空间**: ~10MB
## 开发环境
- Visual Studio 2019+ 或 .NET SDK 8.0+
- .NET Framework 4.6.2+ 开发工具
## 编译步骤
### 方式一:命令行编译(推荐)
```bash
# 还原依赖并编译
dotnet build PackagingMallShipper.sln -c Release
# 输出文件位于
bin/Release/net462/PackagingMallShipper.exe
```
### 方式二Visual Studio
1. 使用 Visual Studio 2019+ 打开 `PackagingMallShipper.sln`
2. 还原 NuGet 包
3. 选择 `Release` 配置
4. 生成解决方案
5. 输出文件位于 `bin/Release/net462/` 目录
## 配置说明
编辑 `App.config` 配置API参数
```xml
<appSettings>
<!-- API工厂配置 -->
<add key="ApiBaseUrl" value="https://api.it120.cc" />
<add key="SubDomain" value="let5see" />
<!-- 商户ID用于 /loginAdmin/operator/v2 子账号登录 -->
<add key="MerchantId" value="15073" />
<!-- 同步配置 -->
<add key="SyncPageSize" value="50" />
<add key="ShipConcurrency" value="3" />
</appSettings>
```
> 登录采用 `http://common.apifm.com/loginAdmin/operator/v2` 商户号子账号登录接口;`MerchantId` 未配置时回退至 `https://user.api.it120.cc/login/userName/v2` 的 `pdomain` 登录方式。
## 数据存储
本地数据库位置:`%LOCALAPPDATA%\PackagingMallShipper\data.db`
## 使用流程
1. **登录** - 使用API工厂子账号登录
- 输入用户名或手机号
- 输入密码
- 输入图形验证码(点击图片可刷新)
- 首次登录建议勾选"记住用户名"
2. **同步订单** - 点击"同步订单"获取最新订单
3. **查看订单** - 切换状态筛选,搜索订单
4. **发货方式一** - 导出Excel → 填写快递信息 → 导入发货
5. **发货方式二** - 选择订单 → 填写快递信息 → 单个发货
## 项目结构
```
PackagingMallShipper/
├── Models/ # 数据模型
├── ViewModels/ # 视图模型MVVM
├── Views/ # XAML视图
├── Services/ # 业务服务
├── Data/ # 数据访问层
├── Helpers/ # 工具类
├── Converters/ # 值转换器
└── Resources/ # 资源文件
```
## 相关文档
- [技术方案文档](./轻量级订单发货客户端方案.md)
- [后台接口文档](./后台接口.md)
- [安装包构建说明](./BUILD_INSTALLER.md)