mirror of
https://github.com/thecyberlearn/quantum-ai-v2.git
synced 2026-08-18 21:32:59 +00:00
35 lines
1.3 KiB
Python
35 lines
1.3 KiB
Python
# Generated by Django 5.2.4 on 2025-07-08 15:00
|
|
|
|
import django.db.models.deletion
|
|
import uuid
|
|
from django.conf import settings
|
|
from django.db import migrations, models
|
|
|
|
|
|
class Migration(migrations.Migration):
|
|
|
|
initial = True
|
|
|
|
dependencies = [
|
|
migrations.swappable_dependency(settings.AUTH_USER_MODEL),
|
|
]
|
|
|
|
operations = [
|
|
migrations.CreateModel(
|
|
name='WalletTransaction',
|
|
fields=[
|
|
('id', models.UUIDField(default=uuid.uuid4, editable=False, primary_key=True, serialize=False)),
|
|
('amount', models.DecimalField(decimal_places=2, max_digits=10)),
|
|
('type', models.CharField(choices=[('top_up', 'Top Up'), ('agent_usage', 'Agent Usage'), ('refund', 'Refund')], max_length=20)),
|
|
('description', models.TextField()),
|
|
('agent_slug', models.CharField(blank=True, max_length=100)),
|
|
('stripe_session_id', models.CharField(blank=True, max_length=200)),
|
|
('created_at', models.DateTimeField(auto_now_add=True)),
|
|
('user', models.ForeignKey(on_delete=django.db.models.deletion.CASCADE, related_name='wallet_transactions', to=settings.AUTH_USER_MODEL)),
|
|
],
|
|
options={
|
|
'ordering': ['-created_at'],
|
|
},
|
|
),
|
|
]
|