0003_transactionevent.py 1.2 KB

123456789101112131415161718192021222324252627282930313233
  1. # Generated by Django 3.1.5 on 2021-01-24 17:54
  2. from django.db import migrations, models
  3. import django.db.models.deletion
  4. import uuid
  5. class Migration(migrations.Migration):
  6. initial = True
  7. dependencies = [
  8. ('projects', '0007_auto_20201026_2354'),
  9. ('performance', '0002_auto_20210124_1745'),
  10. ]
  11. operations = [
  12. migrations.CreateModel(
  13. name='TransactionEvent',
  14. fields=[
  15. ('event_id', models.UUIDField(default=uuid.uuid4, editable=False, primary_key=True, serialize=False)),
  16. ('created', models.DateTimeField(auto_now_add=True, db_index=True)),
  17. ('data', models.JSONField(help_text='General event data that is searchable')),
  18. ('timestamp', models.DateTimeField(blank=True, help_text='Date created as claimed by client it came from', null=True)),
  19. ('transaction', models.CharField(max_length=1024)),
  20. ('start_timestamp', models.DateTimeField()),
  21. ('project', models.ForeignKey(on_delete=django.db.models.deletion.CASCADE, to='projects.project')),
  22. ],
  23. options={
  24. 'ordering': ['-created'],
  25. },
  26. ),
  27. ]