mirror of
https://github.com/thecyberlearn/quantum-ai-v2.git
synced 2026-08-18 12:32:59 +00:00
- Add stripe_payment_intent_id field to WalletTransaction model with proper defaults - Update User.deduct_balance() to handle missing stripe_payment_intent_id gracefully - Update User.add_balance() to handle missing stripe_payment_intent_id gracefully - Use try-catch pattern to handle database schema mismatches - Provide empty string as default for stripe_payment_intent_id when field is required Issue: Database has NOT NULL constraint on stripe_payment_intent_id but code doesn't provide it Solution: Add field with proper defaults and graceful error handling Prevents: 'NOT NULL constraint failed: wallet_wallettransaction.stripe_payment_intent_id' |
||
|---|---|---|
| .. | ||
| migrations | ||
| __init__.py | ||
| admin.py | ||
| apps.py | ||
| models.py | ||
| stripe_handler.py | ||
| tests.py | ||
| views.py | ||