Source code for notes.migrations.0001_initial

# Generated by Django 4.2.7 on 2024-08-26 17:07

from django.conf import settings
import django.core.validators
from django.db import migrations, models
import django.db.models.deletion
import notes.models


[docs] class Migration(migrations.Migration): initial = True dependencies = [ migrations.swappable_dependency(settings.AUTH_USER_MODEL), ('core', '0014_alter_user_account'), ] operations = [ migrations.CreateModel( name='Notes', fields=[ ('id', models.BigAutoField(auto_created=True, primary_key=True, serialize=False, verbose_name='ID')), ('key', models.CharField(blank=True, default='', max_length=100)), ('type', models.CharField(choices=[('Cellar', 'Cellar'), ('General', 'General'), ('Tasting', 'Non cellar Tasting')], default='G', max_length=8)), ('title', models.CharField(default='', max_length=75)), ('year', models.CharField(blank=True, default='', max_length=8)), ('notes', models.TextField()), ('fruit_description', models.CharField(choices=[('Lemon', 'Lemon'), ('Grapefruit', 'Grapefruit'), ('Orange', 'Orange'), ('Pineapple', 'Pineapple'), ('Banana', 'Banana'), ('Lychee', 'Lychee'), ('Melon', 'Melon'), ('Muscat', 'Muscat'), ('Apple', 'Apple'), ('Pear', 'Pear'), ('Quince', 'Quince'), ('Strawberry', 'Strawberry'), ('Raspberry', 'Raspberry'), ('Redcurrant', 'Recurrant'), ('Blackcurrant', 'Blackcurrant'), ('Blueberry', 'Blueberry'), ('Blackberry', 'Blackberry'), ('Cherry', 'Cherry'), ('Apricot', 'Apricot'), ('Peach', 'Peach'), ('Almond', 'Almond'), ('Prune', 'Prune'), ('Walnut', 'Walnut'), ('-', '-')], default='-', max_length=30)), ('vegetal_description', models.CharField(choices=[('Green Pepper', 'Green Pepper'), ('Mushroom', 'Mushroom'), ('Truffle', 'Truffle'), ('Wine Lees', 'Wine Lees'), ('Cedar', 'Cedar'), ('Pine', 'Pine'), ('Liquorice', 'Liquorice'), ('Blackcurrant bud', 'Blackcurrant bud'), ('Cut Hay', 'Cut Hay'), ('Thyme', 'Thyme'), ('Vanilla', 'Vanilla'), ('Cinamon', 'Cinamon'), ('Clove', 'Clove'), ('Pepper', 'Pepper'), ('Saffron', 'Saffron'), ('-', '-')], default='-', max_length=30)), ('floral_description', models.CharField(choices=[('Violet', 'Violet'), ('Rose', 'Rose'), ('Acacia', 'Acacia'), ('Hawthorn', 'Hawthorn'), ('Roasted Hazlenut', 'Roasted Hazlenut'), ('Honey', 'Honey'), ('Linden', 'Linden'), ('-', '-')], default='-', max_length=30)), ('roasted_description', models.CharField(choices=[('Leather', 'Leather'), ('Musk', 'Musk'), ('Butter', 'Butter'), ('Toast', 'Toast'), ('Roasted Almond', 'Roasted Almond'), ('Caramel', 'Caramel'), ('Coffee', 'Coffee'), ('Smoke', 'Smoke'), ('Dark Chocolate', 'Dark Chocolate'), ('-', '-')], default='-', max_length=30)), ('nosescore', models.CharField(blank=True, choices=[('Pending', 'Pending'), ('Bronze', 'Bronze'), ('Silver', 'Silver'), ('Gold', 'Gold'), ('Platinum', 'Platinum')], max_length=30)), ('appearancescore', models.CharField(blank=True, choices=[('Pending', 'Pending'), ('Bronze', 'Bronze'), ('Silver', 'Silver'), ('Gold', 'Gold'), ('Platinum', 'Platinum')], max_length=30)), ('tastescore', models.CharField(blank=True, choices=[('Pending', 'Pending'), ('Bronze', 'Bronze'), ('Silver', 'Silver'), ('Gold', 'Gold'), ('Platinum', 'Platinum')], max_length=30)), ('overallscore', models.CharField(blank=True, choices=[('Pending', 'Pending'), ('Bronze', 'Bronze'), ('Silver', 'Silver'), ('Gold', 'Gold'), ('Platinum', 'Platinum')], max_length=30)), ('created', models.DateTimeField(auto_now_add=True)), ('last_update', models.DateTimeField(auto_now=True)), ('image', models.ImageField(blank=True, null=True, upload_to='images', validators=[django.core.validators.FileExtensionValidator(['png', 'jpg', 'jpeg'])])), ('account', models.ForeignKey(default='1', on_delete=django.db.models.deletion.DO_NOTHING, to='core.account')), ('addition', models.ForeignKey(blank=True, default='', null=True, on_delete=django.db.models.deletion.DO_NOTHING, to='core.addition')), ('country', models.ForeignKey(blank=True, null=True, on_delete=django.db.models.deletion.DO_NOTHING, to='core.country')), ('style', models.ForeignKey(blank=True, null=True, on_delete=django.db.models.deletion.DO_NOTHING, to='core.style')), ], options={ 'ordering': ['created'], }, ), migrations.CreateModel( name='NotesMedia', fields=[ ('id', models.BigAutoField(auto_created=True, primary_key=True, serialize=False, verbose_name='ID')), ('file', models.FileField(upload_to=notes.models.upload_path, validators=[django.core.validators.FileExtensionValidator(['pdf'])])), ('name', models.CharField(max_length=30)), ('note', models.ForeignKey(on_delete=django.db.models.deletion.CASCADE, related_name='note_key', to='notes.notes')), ('user', models.ForeignKey(on_delete=django.db.models.deletion.CASCADE, to=settings.AUTH_USER_MODEL)), ], ), ]