From 4fc1c36ae9c6e219e248d4305a1769c95c838792 Mon Sep 17 00:00:00 2001 From: Nico Schottelius Date: Thu, 5 Mar 2020 11:17:30 +0100 Subject: [PATCH] fix incorrect migrations from fnux-stable branch Signed-off-by: Nico Schottelius --- .../uncloud_pay/migrations/0001_initial.py | 12 +++++++-- .../migrations/0014_auto_20200303_1027.py | 18 ------------- .../migrations/0015_stripecustomer.py | 24 ------------------ .../migrations/0016_auto_20200303_1552.py | 25 ------------------- 4 files changed, 10 insertions(+), 69 deletions(-) delete mode 100644 uncloud/uncloud_pay/migrations/0014_auto_20200303_1027.py delete mode 100644 uncloud/uncloud_pay/migrations/0015_stripecustomer.py delete mode 100644 uncloud/uncloud_pay/migrations/0016_auto_20200303_1552.py diff --git a/uncloud/uncloud_pay/migrations/0001_initial.py b/uncloud/uncloud_pay/migrations/0001_initial.py index f99021a..89fa586 100644 --- a/uncloud/uncloud_pay/migrations/0001_initial.py +++ b/uncloud/uncloud_pay/migrations/0001_initial.py @@ -1,4 +1,4 @@ -# Generated by Django 3.0.3 on 2020-03-03 16:50 +# Generated by Django 3.0.3 on 2020-03-05 10:17 from django.conf import settings import django.core.validators @@ -13,6 +13,7 @@ class Migration(migrations.Migration): dependencies = [ migrations.swappable_dependency(settings.AUTH_USER_MODEL), + ('uncloud_auth', '0001_initial'), ] operations = [ @@ -40,6 +41,13 @@ class Migration(migrations.Migration): ('owner', models.ForeignKey(editable=False, on_delete=django.db.models.deletion.CASCADE, to=settings.AUTH_USER_MODEL)), ], ), + migrations.CreateModel( + name='StripeCustomer', + fields=[ + ('owner', models.OneToOneField(on_delete=django.db.models.deletion.CASCADE, primary_key=True, serialize=False, to=settings.AUTH_USER_MODEL)), + ('stripe_id', models.CharField(max_length=32)), + ], + ), migrations.CreateModel( name='Payment', fields=[ @@ -54,7 +62,7 @@ class Migration(migrations.Migration): name='OrderRecord', fields=[ ('id', models.AutoField(auto_created=True, primary_key=True, serialize=False, verbose_name='ID')), - ('setup_fee', models.DecimalField(decimal_places=2, default=0.0, max_digits=10, validators=[django.core.validators.MinValueValidator(0)])), + ('one_time_price', models.DecimalField(decimal_places=2, default=0.0, max_digits=10, validators=[django.core.validators.MinValueValidator(0)])), ('recurring_price', models.DecimalField(decimal_places=2, default=0.0, max_digits=10, validators=[django.core.validators.MinValueValidator(0)])), ('description', models.TextField()), ('order', models.ForeignKey(on_delete=django.db.models.deletion.CASCADE, to='uncloud_pay.Order')), diff --git a/uncloud/uncloud_pay/migrations/0014_auto_20200303_1027.py b/uncloud/uncloud_pay/migrations/0014_auto_20200303_1027.py deleted file mode 100644 index bd71834..0000000 --- a/uncloud/uncloud_pay/migrations/0014_auto_20200303_1027.py +++ /dev/null @@ -1,18 +0,0 @@ -# Generated by Django 3.0.3 on 2020-03-03 10:27 - -from django.db import migrations - - -class Migration(migrations.Migration): - - dependencies = [ - ('uncloud_pay', '0001_initial'), - ] - - operations = [ - migrations.RenameField( - model_name='orderrecord', - old_name='setup_fee', - new_name='one_time_price', - ), - ] diff --git a/uncloud/uncloud_pay/migrations/0015_stripecustomer.py b/uncloud/uncloud_pay/migrations/0015_stripecustomer.py deleted file mode 100644 index 14fdbf0..0000000 --- a/uncloud/uncloud_pay/migrations/0015_stripecustomer.py +++ /dev/null @@ -1,24 +0,0 @@ -# Generated by Django 3.0.3 on 2020-03-03 13:56 - -from django.conf import settings -from django.db import migrations, models -import django.db.models.deletion - - -class Migration(migrations.Migration): - - dependencies = [ - migrations.swappable_dependency(settings.AUTH_USER_MODEL), - ('uncloud_pay', '0014_auto_20200303_1027'), - ] - - operations = [ - migrations.CreateModel( - name='StripeCustomer', - fields=[ - ('id', models.AutoField(auto_created=True, primary_key=True, serialize=False, verbose_name='ID')), - ('stripe_id', models.CharField(max_length=32)), - ('owner', models.ForeignKey(on_delete=django.db.models.deletion.CASCADE, to=settings.AUTH_USER_MODEL)), - ], - ), - ] diff --git a/uncloud/uncloud_pay/migrations/0016_auto_20200303_1552.py b/uncloud/uncloud_pay/migrations/0016_auto_20200303_1552.py deleted file mode 100644 index 08e3f2f..0000000 --- a/uncloud/uncloud_pay/migrations/0016_auto_20200303_1552.py +++ /dev/null @@ -1,25 +0,0 @@ -# Generated by Django 3.0.3 on 2020-03-03 15:52 - -from django.conf import settings -from django.db import migrations, models -import django.db.models.deletion - - -class Migration(migrations.Migration): - - dependencies = [ - migrations.swappable_dependency(settings.AUTH_USER_MODEL), - ('uncloud_pay', '0015_stripecustomer'), - ] - - operations = [ - migrations.RemoveField( - model_name='stripecustomer', - name='id', - ), - migrations.AlterField( - model_name='stripecustomer', - name='owner', - field=models.OneToOneField(on_delete=django.db.models.deletion.CASCADE, primary_key=True, serialize=False, to=settings.AUTH_USER_MODEL), - ), - ]