|
|
|
# Generated by Django 3.2.23 on 2023-12-11 19:19
|
|
|
|
|
|
|
|
from django.db import migrations, models
|
|
|
|
|
|
|
|
def nastav_nove_contenttypes(apps, schema_editor):
|
|
|
|
ContentType = apps.get_model('contenttypes', 'ContentType')
|
|
|
|
old_ct = ContentType.objects.get_by_natural_key('seminar', 'nastaveni')
|
|
|
|
old_ct.update(appname='various')
|
|
|
|
|
|
|
|
def nastav_stare_contenttypes(apps, schema_editor):
|
|
|
|
ContentType = apps.get_model('contenttypes', 'ContentType')
|
|
|
|
new_ct = ContentType.objects.get_by_natural_key('various', 'nastaveni')
|
|
|
|
new_ct.update(appname='seminar')
|
|
|
|
|
|
|
|
class Migration(migrations.Migration):
|
|
|
|
|
|
|
|
initial = True
|
|
|
|
|
|
|
|
dependencies = [
|
|
|
|
('seminar', '0115_alter_nastaveni_options'),
|
|
|
|
]
|
|
|
|
|
|
|
|
operations = [
|
|
|
|
migrations.CreateModel(
|
|
|
|
name='Nastaveni',
|
|
|
|
fields=[
|
|
|
|
('id', models.AutoField(auto_created=True, primary_key=True, serialize=False, verbose_name='ID')),
|
|
|
|
('cena_sous', models.IntegerField(default=1000, verbose_name='Účastnický poplatek za soustředění')),
|
|
|
|
],
|
|
|
|
options={
|
|
|
|
'verbose_name': 'Nastavení semináře',
|
|
|
|
'db_table': 'seminar_nastaveni',
|
|
|
|
'managed': False,
|
|
|
|
},
|
|
|
|
),
|
|
|
|
migrations.RunPython(nastav_nove_contenttypes, nastav_stare_contenttypes),
|
|
|
|
]
|