update lending contract

This commit is contained in:
2025-12-29 15:38:25 +08:00
parent dba8fa1af0
commit 2cd584be76
28 changed files with 50 additions and 88 deletions

View File

@@ -602,7 +602,7 @@
---
## 5. 借款流程(Borrow
## 5. 借款流程(Withdraw如果余额不足会自动借款
```
┌─────────────────────────────────────────────────────────────────────┐
@@ -614,12 +614,12 @@
│ 计划: 借款 1,000,000 USDC │
└────────────────────────────┬────────────────────────────────────────┘
│ 1. 调用 borrow(1000000e6)
│ 1. 调用 withdraw(1000000e6)进行借款
┌─────────────────────────────────────────────────────────────────────┐
│ Lending.borrow() │
│ Lending.withdraw() │
│ ───────────────────────────────────────────────────────────────── │
│ function borrow(uint256 amount) │
│ function withdraw(uint256 amount) │
│ • 非重入保护: nonReentrant │
│ • 暂停检查: whenNotPaused │
│ • 参数: 1,000,000 USDC (1000000e6) │
@@ -1824,7 +1824,6 @@ Configuration {
// 清算参数
storeFrontPriceFactor: 0.95e18 // 清算购买折扣 5%
trackingIndexScale: 1e15 // 追踪索引比例
baseBorrowMin: 100e6 // 最小借款 100 USDC
targetReserves: 5000000e6 // 目标储备 500万