parent
509e1c5d7a
commit
46c1b7741d
4 changed files with 79 additions and 22 deletions
@ -0,0 +1,35 @@ |
|||||||
|
# -*- coding: utf-8 -*- |
||||||
|
# Generated by Django 1.11.6 on 2018-05-14 13:29 |
||||||
|
from __future__ import unicode_literals |
||||||
|
|
||||||
|
from django.db import migrations, models |
||||||
|
import uuid |
||||||
|
|
||||||
|
|
||||||
|
class Migration(migrations.Migration): |
||||||
|
|
||||||
|
dependencies = [ |
||||||
|
('progress', '0014_auto_20180507_1412'), |
||||||
|
] |
||||||
|
|
||||||
|
operations = [ |
||||||
|
migrations.CreateModel( |
||||||
|
name='OpenToken', |
||||||
|
fields=[ |
||||||
|
('id', models.AutoField(auto_created=True, primary_key=True, serialize=False, verbose_name='ID')), |
||||||
|
('token', models.UUIDField(default=uuid.uuid4, editable=False, verbose_name='Токен')), |
||||||
|
('email', models.CharField(max_length=255, verbose_name='email пользователя')), |
||||||
|
('course_token', models.UUIDField(editable=False, verbose_name='Токен курса')), |
||||||
|
('period_days', models.SmallIntegerField(default=3, verbose_name='Период (в днях)')), |
||||||
|
('date', models.DateTimeField(auto_now_add=True, verbose_name='Дата создания')), |
||||||
|
], |
||||||
|
options={ |
||||||
|
'verbose_name': 'Токен на открытие курса', |
||||||
|
'verbose_name_plural': 'Токены на открытие курса', |
||||||
|
}, |
||||||
|
), |
||||||
|
migrations.AlterUniqueTogether( |
||||||
|
name='opentoken', |
||||||
|
unique_together=set([('email', 'course_token')]), |
||||||
|
), |
||||||
|
] |
||||||
Loading…
Reference in new issue