From 58df0d423d41800e6b5697e0dddca57ba1f40ac6 Mon Sep 17 00:00:00 2001 From: virusdefender <1670873886@qq.com> Date: Thu, 24 Sep 2015 15:31:16 +0800 Subject: [PATCH] =?UTF-8?q?=E5=A2=9E=E5=8A=A0=20model=20=E4=BF=AE=E6=94=B9?= =?UTF-8?q?=E7=9A=84=20migrations?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- account/migrations/0006_auto_20150924_1530.py | 20 +++++++++++++ contest/migrations/0011_contestrank.py | 29 +++++++++++++++++++ 2 files changed, 49 insertions(+) create mode 100644 account/migrations/0006_auto_20150924_1530.py create mode 100644 contest/migrations/0011_contestrank.py diff --git a/account/migrations/0006_auto_20150924_1530.py b/account/migrations/0006_auto_20150924_1530.py new file mode 100644 index 00000000..29a7222e --- /dev/null +++ b/account/migrations/0006_auto_20150924_1530.py @@ -0,0 +1,20 @@ +# -*- coding: utf-8 -*- +from __future__ import unicode_literals + +from django.db import models, migrations +import utils.models + + +class Migration(migrations.Migration): + + dependencies = [ + ('account', '0005_user_problems_status'), + ] + + operations = [ + migrations.AlterField( + model_name='user', + name='problems_status', + field=utils.models.JsonField(default={}), + ), + ] diff --git a/contest/migrations/0011_contestrank.py b/contest/migrations/0011_contestrank.py new file mode 100644 index 00000000..c014d7a9 --- /dev/null +++ b/contest/migrations/0011_contestrank.py @@ -0,0 +1,29 @@ +# -*- coding: utf-8 -*- +from __future__ import unicode_literals + +from django.db import models, migrations +from django.conf import settings +import utils.models + + +class Migration(migrations.Migration): + + dependencies = [ + migrations.swappable_dependency(settings.AUTH_USER_MODEL), + ('contest', '0010_auto_20150922_1703'), + ] + + operations = [ + migrations.CreateModel( + name='ContestRank', + fields=[ + ('id', models.AutoField(verbose_name='ID', serialize=False, auto_created=True, primary_key=True)), + ('total_submission_number', models.IntegerField(default=0)), + ('total_ac_number', models.IntegerField(default=0)), + ('total_time', models.IntegerField(default=0)), + ('submission_info', utils.models.JsonField(default={})), + ('contest', models.ForeignKey(to='contest.Contest')), + ('user', models.ForeignKey(to=settings.AUTH_USER_MODEL)), + ], + ), + ]