# Generated by Django 3.2.14 on 2022-07-06 02:25

from django.db import migrations, models


class Migration(migrations.Migration):

    initial = True

    dependencies = []

    operations = [
        migrations.CreateModel(
            name="CurrencyValue",
            fields=[
                (
                    "id",
                    models.AutoField(
                        auto_created=True,
                        primary_key=True,
                        serialize=False,
                        verbose_name="ID",
                    ),
                ),
                (
                    "value",
                    models.DecimalField(
                        decimal_places=6, max_digits=20, verbose_name="value"
                    ),
                ),
                ("date", models.DateField(db_index=True, verbose_name="currency date")),
                (
                    "base_currency",
                    models.CharField(
                        choices=[
                            ("CLP", "CLP"),
                            ("CLF", "CLF"),
                            ("USD", "USD"),
                            ("EUR", "EUR"),
                        ],
                        help_text="The acronym of the base currency",
                        max_length=5,
                        verbose_name="base currency",
                    ),
                ),
                (
                    "counter_currency",
                    models.CharField(
                        choices=[
                            ("CLP", "CLP"),
                            ("CLF", "CLF"),
                            ("USD", "USD"),
                            ("EUR", "EUR"),
                        ],
                        help_text="The acronym of the counter currency",
                        max_length=5,
                        verbose_name="counter currency",
                    ),
                ),
            ],
            options={
                "verbose_name": "currency value",
                "verbose_name_plural": "currency values",
                "ordering": ("date",),
                "unique_together": {("base_currency", "counter_currency", "date")},
            },
        ),
    ]
