Commit Graph
4 Commits
Author SHA1 Message Date
WrBug 4e89f53c24 refactor: 重构市场数据接口和移除敏感信息
- 创建 MarketController,将市场相关接口从 AccountController 移出
- 添加 /api/copy-trading/markets/latest-price 接口供前端获取最新价
- 在 PolymarketClobService 中封装获取订单表和最优价的逻辑
- 支持多元市场(二元、三元及以上)的最优价获取
- 市价单价格添加调整系数(买单+0.01,卖单-0.02)
- 移除所有测试文件中的真实私钥和API凭证
- 更新前端API服务,添加markets相关接口
2025-11-29 11:08:01 +08:00
WrBug b4fb16af9e feat: 实现仓位出售功能并修复价格接口
- 新增仓位出售功能,支持市价和限价卖出
- 添加卖出模态框,包含订单类型选择、数量快捷按钮、限价输入
- 实现实时平仓收益计算和显示
- 修复价格接口:改用Gamma API获取价格(支持condition_ids参数)
- 优化价格选择逻辑:卖出使用bestBid,买入使用bestAsk
- 添加提交订单的加载状态和错误处理
- 优化UI提示,明确标注价格用途(买入/卖出参考)
2025-11-28 04:11:13 +08:00
WrBug f53ba1ca49 feat: 优化仓位管理页面功能和样式
- 添加卡片和列表视图切换功能
- 移动端支持卡片折叠/展开,默认只显示关键信息
- 历史仓位不显示盈亏和平仓收益
- 优化账户筛选:移除搜索功能,按账户名称排序
- 移动端强制使用卡片视图,隐藏视图切换按钮
- 优化侧边栏布局:固定高度,内容区域可滚动
- 优化当前仓位/历史仓位切换组件样式
- 修复账户筛选全部账户选项不生效的问题
2025-11-27 01:13:52 +08:00
WrBug 4f7fef145f Initial commit: Polymarket copy trading bot
- Backend: Spring Boot + Kotlin implementation
  - Account management with private key import
  - Leader management
  - Copy trading configuration
  - Order synchronization
  - Balance and position queries via Polymarket API
  - Ethereum RPC integration for USDC balance
  - Proxy address calculation

- Frontend: React + TypeScript
  - Account management UI
  - Mobile responsive design
  - Account import with private key/mnemonic support
  - Balance display and account details modal

- Database: MySQL with Flyway migrations
- API Integration: Polymarket CLOB API, Data API, Ethereum RPC
2025-11-21 04:32:08 +08:00