Django 1.8(b2) support.
[django-cas-provider.git] / cas_provider / migrations / 0001_initial.py
1 # -*- coding: utf-8 -*-
2 from __future__ import unicode_literals
3
4 from django.db import models, migrations
5 from django.conf import settings
6
7
8 class Migration(migrations.Migration):
9
10     dependencies = [
11         migrations.swappable_dependency(settings.AUTH_USER_MODEL),
12     ]
13
14     operations = [
15         migrations.CreateModel(
16             name='LoginTicket',
17             fields=[
18                 ('id', models.AutoField(verbose_name='ID', serialize=False, auto_created=True, primary_key=True)),
19                 ('ticket', models.CharField(max_length=32, verbose_name='ticket')),
20                 ('created', models.DateTimeField(auto_now=True, verbose_name='created')),
21             ],
22             options={
23                 'verbose_name': 'Login Ticket',
24                 'verbose_name_plural': 'Login Tickets',
25             },
26             bases=(models.Model,),
27         ),
28         migrations.CreateModel(
29             name='ProxyGrantingTicket',
30             fields=[
31                 ('id', models.AutoField(verbose_name='ID', serialize=False, auto_created=True, primary_key=True)),
32                 ('ticket', models.CharField(max_length=32, verbose_name='ticket')),
33                 ('created', models.DateTimeField(auto_now=True, verbose_name='created')),
34                 ('pgtiou', models.CharField(max_length=256, verbose_name='PGTiou')),
35             ],
36             options={
37                 'verbose_name': 'Proxy Granting Ticket',
38                 'verbose_name_plural': 'Proxy Granting Tickets',
39             },
40             bases=(models.Model,),
41         ),
42         migrations.CreateModel(
43             name='ProxyGrantingTicketIOU',
44             fields=[
45                 ('id', models.AutoField(verbose_name='ID', serialize=False, auto_created=True, primary_key=True)),
46                 ('ticket', models.CharField(max_length=32, verbose_name='ticket')),
47                 ('created', models.DateTimeField(auto_now=True, verbose_name='created')),
48                 ('proxyGrantingTicket', models.ForeignKey(verbose_name='Proxy Granting Ticket', to='cas_provider.ProxyGrantingTicket')),
49             ],
50             options={
51                 'verbose_name': 'Proxy Granting Ticket IOU',
52                 'verbose_name_plural': 'Proxy Granting Tickets IOU',
53             },
54             bases=(models.Model,),
55         ),
56         migrations.CreateModel(
57             name='ServiceTicket',
58             fields=[
59                 ('id', models.AutoField(verbose_name='ID', serialize=False, auto_created=True, primary_key=True)),
60                 ('ticket', models.CharField(max_length=32, verbose_name='ticket')),
61                 ('created', models.DateTimeField(auto_now=True, verbose_name='created')),
62                 ('service', models.URLField(verbose_name='service')),
63             ],
64             options={
65                 'verbose_name': 'Service Ticket',
66                 'verbose_name_plural': 'Service Tickets',
67             },
68             bases=(models.Model,),
69         ),
70         migrations.CreateModel(
71             name='ProxyTicket',
72             fields=[
73                 ('serviceticket_ptr', models.OneToOneField(parent_link=True, auto_created=True, primary_key=True, serialize=False, to='cas_provider.ServiceTicket')),
74                 ('proxyGrantingTicket', models.ForeignKey(verbose_name='Proxy Granting Ticket', to='cas_provider.ProxyGrantingTicket')),
75             ],
76             options={
77                 'verbose_name': 'Proxy Ticket',
78                 'verbose_name_plural': 'Proxy Tickets',
79             },
80             bases=('cas_provider.serviceticket',),
81         ),
82         migrations.AddField(
83             model_name='serviceticket',
84             name='user',
85             field=models.ForeignKey(verbose_name='user', to=settings.AUTH_USER_MODEL),
86             preserve_default=True,
87         ),
88         migrations.AddField(
89             model_name='proxygrantingticket',
90             name='serviceTicket',
91             field=models.ForeignKey(to='cas_provider.ServiceTicket', null=True),
92             preserve_default=True,
93         ),
94     ]