Verified Commit 5f4560b3 authored by Sébastiaan Versteeg's avatar Sébastiaan Versteeg
Browse files

Split registration payment migration into three files

parent 87d38520
# -*- coding: utf-8 -*-
# Generated by Django 1.11 on 2017-07-21 19:18
from __future__ import unicode_literals
from django.db import migrations, models
class Migration(migrations.Migration):
dependencies = [
('events', '0017_auto_20170524_2046'),
]
operations = [
migrations.AddField(
model_name='registration',
name='payment',
field=models.CharField(choices=[('no_payment', 'No payment'), ('cash_payment', 'Paid with cash'), ('card_payment', 'Paid with card')], default='no_payment', max_length=20, verbose_name='payment'),
)
]
......@@ -6,9 +6,8 @@ from django.db import migrations, models
class Migration(migrations.Migration):
dependencies = [
('events', '0017_auto_20170524_2046'),
('events', '0018_0_registration_payment'),
]
def forwards_func(apps, schema_editor):
......@@ -28,14 +27,5 @@ class Migration(migrations.Migration):
reg.save()
operations = [
migrations.AddField(
model_name='registration',
name='payment',
field=models.CharField(choices=[('no_payment', 'No payment'), ('cash_payment', 'Paid with cash'), ('card_payment', 'Paid with card')], default='no_payment', max_length=20, verbose_name='payment'),
),
migrations.RunPython(forwards_func, reverse_func),
migrations.RemoveField(
model_name='registration',
name='paid'
)
]
# -*- coding: utf-8 -*-
# Generated by Django 1.11 on 2017-07-21 19:18
from __future__ import unicode_literals
from django.db import migrations, models
class Migration(migrations.Migration):
dependencies = [
('events', '0018_1_registration_payment'),
]
operations = [
migrations.RemoveField(
model_name='registration',
name='paid'
)
]
Markdown is supported
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment