This repository has been archived on 2019-10-13. You can view files and clone it, but cannot push or open issues or pull requests.

75 lines
2.9 KiB
Python

# -*- coding: utf-8 -*-
# Generated by Django 1.11.2 on 2017-10-25 23:47
from __future__ import unicode_literals
from django.db import migrations, models
import django.utils.timezone
class Migration(migrations.Migration):
initial = True
dependencies = [
]
operations = [
migrations.CreateModel(
name='Allergene',
fields=[
('id', models.AutoField(primary_key=True, serialize=False)),
('name', models.CharField(max_length=60, unique=True)),
],
),
migrations.CreateModel(
name='HappyHour',
fields=[
('id', models.AutoField(primary_key=True, serialize=False)),
('date', models.DateField(default=django.utils.timezone.now)),
('starttime', models.TimeField(default=django.utils.timezone.now)),
('endtime', models.TimeField(default=django.utils.timezone.now)),
('location', models.CharField(max_length=60)),
('description', models.CharField(max_length=60)),
],
),
migrations.CreateModel(
name='Menu',
fields=[
('id', models.AutoField(primary_key=True, serialize=False)),
('date', models.DateField(default=django.utils.timezone.now)),
('location', models.CharField(max_length=60)),
],
),
migrations.CreateModel(
name='SingleFood',
fields=[
('id', models.AutoField(primary_key=True, serialize=False)),
('name', models.CharField(max_length=60, unique=True)),
('price_student', models.CharField(blank=True, max_length=10, null=True)),
('price_employee', models.CharField(blank=True, max_length=10, null=True)),
('price_guest', models.CharField(blank=True, max_length=10, null=True)),
('image', models.ImageField(blank=True, upload_to='food/%Y/%m/')),
('rating', models.FloatField(default=0)),
('first_star', models.SmallIntegerField(default=0)),
('second_star', models.SmallIntegerField(default=0)),
('third_star', models.SmallIntegerField(default=0)),
('fourth_star', models.SmallIntegerField(default=0)),
('fifth_star', models.SmallIntegerField(default=0)),
('allergens', models.ManyToManyField(blank=True, to='food.Allergene')),
],
),
migrations.AddField(
model_name='menu',
name='menu',
field=models.ManyToManyField(to='food.SingleFood'),
),
migrations.AlterUniqueTogether(
name='happyhour',
unique_together=set([('date', 'location', 'starttime', 'endtime')]),
),
migrations.AlterUniqueTogether(
name='menu',
unique_together=set([('date', 'location')]),
),
]