2019-05-12 16:23:59 +00:00
|
|
|
# Generated by Django 2.1.2 on 2019-05-12 16:15
|
2018-10-26 23:42:53 +00:00
|
|
|
|
2019-05-12 16:23:59 +00:00
|
|
|
import GeoffreyApp.util
|
2018-10-26 23:42:53 +00:00
|
|
|
from django.db import migrations, models
|
|
|
|
import django.db.models.deletion
|
|
|
|
|
|
|
|
|
|
|
|
class Migration(migrations.Migration):
|
|
|
|
|
|
|
|
initial = True
|
|
|
|
|
|
|
|
dependencies = [
|
|
|
|
]
|
|
|
|
|
|
|
|
operations = [
|
2019-05-12 16:23:59 +00:00
|
|
|
migrations.CreateModel(
|
|
|
|
name='APIToken',
|
|
|
|
fields=[
|
|
|
|
('id', models.AutoField(auto_created=True, primary_key=True, serialize=False, verbose_name='ID')),
|
|
|
|
('key', models.CharField(default=GeoffreyApp.util.create_token, max_length=25, unique=True)),
|
|
|
|
('name', models.CharField(blank=True, max_length=50)),
|
|
|
|
('commands_perm', models.BooleanField(default=False)),
|
|
|
|
],
|
|
|
|
),
|
2018-10-26 23:42:53 +00:00
|
|
|
migrations.CreateModel(
|
|
|
|
name='ItemListing',
|
|
|
|
fields=[
|
|
|
|
('id', models.AutoField(auto_created=True, primary_key=True, serialize=False, verbose_name='ID')),
|
|
|
|
('item_name', models.CharField(max_length=128)),
|
|
|
|
('price', models.IntegerField()),
|
|
|
|
('amount', models.IntegerField()),
|
2019-05-12 16:23:59 +00:00
|
|
|
('date_restocked', models.DateTimeField(auto_now=True)),
|
2018-10-26 23:42:53 +00:00
|
|
|
],
|
|
|
|
),
|
|
|
|
migrations.CreateModel(
|
|
|
|
name='Location',
|
|
|
|
fields=[
|
|
|
|
('id', models.AutoField(auto_created=True, primary_key=True, serialize=False, verbose_name='ID')),
|
|
|
|
('name', models.CharField(max_length=128, unique=True)),
|
|
|
|
('x_coord', models.IntegerField()),
|
|
|
|
('z_coord', models.IntegerField()),
|
|
|
|
('dimension', models.CharField(choices=[('O', 'Overworld'), ('N', 'Nether'), ('E', 'The End')], max_length=1)),
|
|
|
|
],
|
|
|
|
),
|
|
|
|
migrations.CreateModel(
|
|
|
|
name='Player',
|
|
|
|
fields=[
|
|
|
|
('id', models.AutoField(auto_created=True, primary_key=True, serialize=False, verbose_name='ID')),
|
2019-05-12 16:23:59 +00:00
|
|
|
('name', models.CharField(max_length=30, unique=True)),
|
|
|
|
('mc_uuid', models.CharField(max_length=36, unique=True)),
|
|
|
|
('discord_uuid', models.CharField(max_length=50, unique=True)),
|
|
|
|
],
|
|
|
|
),
|
|
|
|
migrations.CreateModel(
|
|
|
|
name='Resource',
|
|
|
|
fields=[
|
|
|
|
('id', models.AutoField(auto_created=True, primary_key=True, serialize=False, verbose_name='ID')),
|
|
|
|
('resource_name', models.CharField(max_length=128)),
|
2018-10-26 23:42:53 +00:00
|
|
|
],
|
|
|
|
),
|
|
|
|
migrations.CreateModel(
|
|
|
|
name='Tunnel',
|
|
|
|
fields=[
|
|
|
|
('id', models.AutoField(auto_created=True, primary_key=True, serialize=False, verbose_name='ID')),
|
|
|
|
('tunnel_number', models.IntegerField()),
|
2019-05-12 16:23:59 +00:00
|
|
|
('tunnel_direction', models.CharField(choices=[('N', 'North'), ('E', 'East'), ('S', 'South'), ('W', 'West')], max_length=1)),
|
2018-10-26 23:42:53 +00:00
|
|
|
],
|
|
|
|
),
|
2019-05-12 16:23:59 +00:00
|
|
|
migrations.CreateModel(
|
|
|
|
name='Attraction',
|
|
|
|
fields=[
|
|
|
|
('location_ptr', models.OneToOneField(auto_created=True, on_delete=django.db.models.deletion.CASCADE, parent_link=True, primary_key=True, serialize=False, to='GeoffreyApp.Location')),
|
|
|
|
],
|
|
|
|
bases=('GeoffreyApp.location',),
|
|
|
|
),
|
2018-10-26 23:42:53 +00:00
|
|
|
migrations.CreateModel(
|
|
|
|
name='Base',
|
|
|
|
fields=[
|
2018-11-22 02:09:30 +00:00
|
|
|
('location_ptr', models.OneToOneField(auto_created=True, on_delete=django.db.models.deletion.CASCADE, parent_link=True, primary_key=True, serialize=False, to='GeoffreyApp.Location')),
|
2018-10-26 23:42:53 +00:00
|
|
|
],
|
2018-11-22 02:09:30 +00:00
|
|
|
bases=('GeoffreyApp.location',),
|
2018-10-26 23:42:53 +00:00
|
|
|
),
|
2019-05-12 16:23:59 +00:00
|
|
|
migrations.CreateModel(
|
|
|
|
name='Market',
|
|
|
|
fields=[
|
|
|
|
('location_ptr', models.OneToOneField(auto_created=True, on_delete=django.db.models.deletion.CASCADE, parent_link=True, primary_key=True, serialize=False, to='GeoffreyApp.Location')),
|
|
|
|
],
|
|
|
|
bases=('GeoffreyApp.location',),
|
|
|
|
),
|
|
|
|
migrations.CreateModel(
|
|
|
|
name='PointOfInterest',
|
|
|
|
fields=[
|
|
|
|
('location_ptr', models.OneToOneField(auto_created=True, on_delete=django.db.models.deletion.CASCADE, parent_link=True, primary_key=True, serialize=False, to='GeoffreyApp.Location')),
|
|
|
|
],
|
|
|
|
bases=('GeoffreyApp.location',),
|
|
|
|
),
|
|
|
|
migrations.CreateModel(
|
|
|
|
name='PublicFarm',
|
|
|
|
fields=[
|
|
|
|
('location_ptr', models.OneToOneField(auto_created=True, on_delete=django.db.models.deletion.CASCADE, parent_link=True, primary_key=True, serialize=False, to='GeoffreyApp.Location')),
|
|
|
|
],
|
|
|
|
bases=('GeoffreyApp.location',),
|
|
|
|
),
|
2018-10-26 23:42:53 +00:00
|
|
|
migrations.CreateModel(
|
|
|
|
name='Shop',
|
|
|
|
fields=[
|
2018-11-22 02:09:30 +00:00
|
|
|
('location_ptr', models.OneToOneField(auto_created=True, on_delete=django.db.models.deletion.CASCADE, parent_link=True, primary_key=True, serialize=False, to='GeoffreyApp.Location')),
|
2018-10-26 23:42:53 +00:00
|
|
|
],
|
2018-11-22 02:09:30 +00:00
|
|
|
bases=('GeoffreyApp.location',),
|
2018-10-26 23:42:53 +00:00
|
|
|
),
|
2019-05-12 16:23:59 +00:00
|
|
|
migrations.CreateModel(
|
|
|
|
name='Town',
|
|
|
|
fields=[
|
|
|
|
('location_ptr', models.OneToOneField(auto_created=True, on_delete=django.db.models.deletion.CASCADE, parent_link=True, primary_key=True, serialize=False, to='GeoffreyApp.Location')),
|
|
|
|
('residents', models.ManyToManyField(to='GeoffreyApp.Player')),
|
|
|
|
],
|
|
|
|
bases=('GeoffreyApp.location',),
|
|
|
|
),
|
2018-10-26 23:42:53 +00:00
|
|
|
migrations.AddField(
|
|
|
|
model_name='tunnel',
|
|
|
|
name='location',
|
2018-11-22 02:09:30 +00:00
|
|
|
field=models.ForeignKey(on_delete=django.db.models.deletion.CASCADE, related_name='tunnel_location', to='GeoffreyApp.Location'),
|
2018-10-26 23:42:53 +00:00
|
|
|
),
|
|
|
|
migrations.AddField(
|
|
|
|
model_name='location',
|
|
|
|
name='owner',
|
2019-05-12 16:23:59 +00:00
|
|
|
field=models.ManyToManyField(to='GeoffreyApp.Player'),
|
|
|
|
),
|
|
|
|
migrations.AddField(
|
|
|
|
model_name='resource',
|
|
|
|
name='farm',
|
|
|
|
field=models.ForeignKey(on_delete=django.db.models.deletion.CASCADE, related_name='resource', to='GeoffreyApp.PublicFarm'),
|
2018-10-26 23:42:53 +00:00
|
|
|
),
|
|
|
|
migrations.AddField(
|
|
|
|
model_name='itemlisting',
|
|
|
|
name='shop',
|
2018-11-22 02:09:30 +00:00
|
|
|
field=models.ForeignKey(on_delete=django.db.models.deletion.CASCADE, related_name='shop_selling', to='GeoffreyApp.Shop'),
|
2018-10-26 23:42:53 +00:00
|
|
|
),
|
|
|
|
]
|