Files
pwap/web/public/sdk_docs/search.index/3eef340d86c8.js
T
pezkuwichain 14f5e84d15 feat(p2p): implement OKX-style internal ledger escrow system
Phase 5 implementation - Internal Ledger Escrow (OKX Model):
- No blockchain transactions during P2P trades
- Blockchain tx only at deposit/withdraw
- Fast and fee-free P2P trading

Database:
- Add user_internal_balances table
- Add p2p_deposit_withdraw_requests table
- Add p2p_balance_transactions table
- Add lock_escrow_internal(), release_escrow_internal() functions
- Add process_deposit(), request_withdraw() functions

UI Components:
- Add InternalBalanceCard showing available/locked balances
- Add DepositModal for crypto deposits to P2P balance
- Add WithdrawModal for withdrawals from P2P balance
- Integrate balance card into P2PDashboard

Backend:
- Add process-withdrawal Edge Function
- Add verify-deposit Edge Function

Updated p2p-fiat.ts:
- createFiatOffer() uses internal balance lock
- confirmPaymentReceived() uses internal balance transfer
- Add internal balance management functions
2025-12-12 00:41:11 +03:00

1 line
551 B
JavaScript

rn_("AQIBoDAABfkVZDswAAABBAAtAAEASPQtAPMCAXM7MAAAAQEALQABAG9xLQAFAcAFAATp+QUf/Wd3AQIAOzAAAAEEAEEBAQANfEEB+wJkZwEAADswAAABBQBBAQEABHhBAfsCZG7hQAUADf0O/Q/9EP0R/RL9E/0U/RX9Fv0X/Rj9Gf0a/Rv9AQQAOzAAAAEFABERAQCHTBER8wACZXM7MAEAAwIADRoFAA4aAQCkPg0aAgCZXQ0aHfkAAAEAAaAAAAX75nM7MAAAAQUAsQIBAGPtsQIBAQA7MAAAAQQALQABAE/7LQABAwA7MAAAAQUADRoBAEy3DRoxQgUA4/vk++X7qv0zAAOgkAAF+R1laXM7MAAAAQUAkQACAPn5kAD5/AAAAQIAOzAAAAEDABERAQDJuxERAQUAOzAAAAEFAF4AAQAf+V4A8wIBYzswAAABAwAREQEAt6oREfsCMTL7xQICiEDHBACHoRAABf0eoDAABfkVoIAABZv0oAAABfz9HCEKOzAAAAEEAG8BAgAcf0EBSPQtAA==")