init commit
This commit is contained in:
29
lottery/draw/migrations/0002_lotteryparticipant.py
Normal file
29
lottery/draw/migrations/0002_lotteryparticipant.py
Normal file
@@ -0,0 +1,29 @@
|
||||
# Generated by Django 5.1.6 on 2025-03-06 10:47
|
||||
|
||||
import django.db.models.deletion
|
||||
from django.db import migrations, models
|
||||
|
||||
|
||||
class Migration(migrations.Migration):
|
||||
|
||||
dependencies = [
|
||||
('draw', '0001_initial'),
|
||||
('webapp', '0002_invoice'),
|
||||
]
|
||||
|
||||
operations = [
|
||||
migrations.CreateModel(
|
||||
name='LotteryParticipant',
|
||||
fields=[
|
||||
('id', models.BigAutoField(auto_created=True, primary_key=True, serialize=False, verbose_name='ID')),
|
||||
('added_at', models.DateTimeField(auto_now_add=True, verbose_name='Дата добавления')),
|
||||
('invoice', models.ForeignKey(on_delete=django.db.models.deletion.CASCADE, to='webapp.invoice', verbose_name='Счет участника')),
|
||||
('lottery', models.ForeignKey(on_delete=django.db.models.deletion.CASCADE, related_name='participants', to='draw.lottery', verbose_name='Лотерея')),
|
||||
],
|
||||
options={
|
||||
'verbose_name': 'Участник лотереи',
|
||||
'verbose_name_plural': 'Участники лотереи',
|
||||
'unique_together': {('lottery', 'invoice')},
|
||||
},
|
||||
),
|
||||
]
|
||||
Reference in New Issue
Block a user