# Generated by Django 5.2.14 on 2026-07-06 11:39

import django.db.models.deletion
from django.db import migrations, models


class Migration(migrations.Migration):

    dependencies = [
        ('eveuniverse', '0012_alter_evebloodline_eve_ship_type'),
        ('shop', '0024_corporationblueprint'),
    ]

    operations = [
        migrations.CreateModel(
            name='ModuleListing',
            fields=[
                ('id', models.AutoField(auto_created=True, primary_key=True, serialize=False, verbose_name='ID')),
                ('featured', models.BooleanField(default=False)),
                ('featured_at', models.DateTimeField(blank=True, null=True)),
                ('price', models.PositiveBigIntegerField(default=0)),
                ('stock', models.PositiveIntegerField(default=0)),
                ('price_mode', models.CharField(choices=[('fixed', 'Fixed'), ('jita_buy_pct', '% Jita Buy'), ('jita_sell_pct', '% Jita Sell')], default='fixed', max_length=20)),
                ('price_pct', models.DecimalField(blank=True, decimal_places=2, max_digits=5, null=True)),
                ('created_at', models.DateTimeField(auto_now_add=True)),
                ('eve_type', models.ForeignKey(on_delete=django.db.models.deletion.PROTECT, related_name='+', to='eveuniverse.evetype')),
                ('shop', models.ForeignKey(on_delete=django.db.models.deletion.CASCADE, related_name='module_listings', to='shop.shop')),
            ],
            options={
                'constraints': [models.UniqueConstraint(fields=('shop', 'eve_type'), name='uniq_shop_module')],
            },
        ),
    ]
