forked from 0x2620/pandora
db migration
This commit is contained in:
parent
976860ec30
commit
4219246909
32 changed files with 1513 additions and 1 deletions
41
pandora/event/migrations/0001_initial.py
Normal file
41
pandora/event/migrations/0001_initial.py
Normal file
|
|
@ -0,0 +1,41 @@
|
|||
# -*- coding: utf-8 -*-
|
||||
# Generated by Django 1.9.2 on 2016-02-19 15:37
|
||||
from __future__ import unicode_literals
|
||||
|
||||
from django.db import migrations, models
|
||||
import ox.django.fields
|
||||
|
||||
|
||||
class Migration(migrations.Migration):
|
||||
|
||||
initial = True
|
||||
|
||||
dependencies = [
|
||||
('annotation', '0002_annotation_clip'),
|
||||
]
|
||||
|
||||
operations = [
|
||||
migrations.CreateModel(
|
||||
name='Event',
|
||||
fields=[
|
||||
('id', models.AutoField(auto_created=True, primary_key=True, serialize=False, verbose_name='ID')),
|
||||
('created', models.DateTimeField(auto_now_add=True)),
|
||||
('modified', models.DateTimeField(auto_now=True)),
|
||||
('defined', models.BooleanField(default=False)),
|
||||
('name', models.CharField(max_length=255, null=True, unique=True)),
|
||||
('name_sort', models.CharField(db_index=True, max_length=255, null=True)),
|
||||
('name_find', models.TextField(default=b'')),
|
||||
('wikipediaId', models.CharField(blank=True, max_length=1000)),
|
||||
('alternativeNames', ox.django.fields.TupleField(default=[])),
|
||||
('start', models.CharField(default=b'', max_length=255)),
|
||||
('startTime', models.BigIntegerField(default=None, null=True)),
|
||||
('end', models.CharField(default=b'', max_length=255)),
|
||||
('endTime', models.BigIntegerField(default=None, null=True)),
|
||||
('duration', models.CharField(default=b'', max_length=255)),
|
||||
('durationTime', models.BigIntegerField(default=None, null=True)),
|
||||
('type', models.CharField(default=b'', max_length=255)),
|
||||
('matches', models.IntegerField(default=0)),
|
||||
('annotations', models.ManyToManyField(blank=True, related_name='events', to='annotation.Annotation')),
|
||||
],
|
||||
),
|
||||
]
|
||||
31
pandora/event/migrations/0002_auto_20160219_1537.py
Normal file
31
pandora/event/migrations/0002_auto_20160219_1537.py
Normal file
|
|
@ -0,0 +1,31 @@
|
|||
# -*- coding: utf-8 -*-
|
||||
# Generated by Django 1.9.2 on 2016-02-19 15:37
|
||||
from __future__ import unicode_literals
|
||||
|
||||
from django.conf import settings
|
||||
from django.db import migrations, models
|
||||
import django.db.models.deletion
|
||||
|
||||
|
||||
class Migration(migrations.Migration):
|
||||
|
||||
initial = True
|
||||
|
||||
dependencies = [
|
||||
('event', '0001_initial'),
|
||||
migrations.swappable_dependency(settings.AUTH_USER_MODEL),
|
||||
('item', '0001_initial'),
|
||||
]
|
||||
|
||||
operations = [
|
||||
migrations.AddField(
|
||||
model_name='event',
|
||||
name='items',
|
||||
field=models.ManyToManyField(blank=True, related_name='events', to='item.Item'),
|
||||
),
|
||||
migrations.AddField(
|
||||
model_name='event',
|
||||
name='user',
|
||||
field=models.ForeignKey(null=True, on_delete=django.db.models.deletion.CASCADE, related_name='events', to=settings.AUTH_USER_MODEL),
|
||||
),
|
||||
]
|
||||
Loading…
Add table
Add a link
Reference in a new issue