# Generated by Django 5.2.11 on 2026-04-20 01:57

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


class Migration(migrations.Migration):

    dependencies = [
        ('companies', '0005_add_enable_audit_log'),
        ('core', '0017_aichatlog_aiprompt'),
        ('inventory', '0010_alter_product_image'),
    ]

    operations = [
        migrations.CreateModel(
            name='BranchStock',
            fields=[
                ('id', models.BigAutoField(auto_created=True, primary_key=True, serialize=False, verbose_name='ID')),
                ('quantity', models.IntegerField(default=0)),
                ('updated_at', models.DateTimeField(auto_now=True)),
                ('branch', models.ForeignKey(on_delete=django.db.models.deletion.CASCADE, related_name='branch_stocks', to='core.branch')),
                ('company', models.ForeignKey(on_delete=django.db.models.deletion.CASCADE, related_name='branch_stocks', to='companies.company')),
                ('product', models.ForeignKey(on_delete=django.db.models.deletion.CASCADE, related_name='branch_stocks', to='inventory.product')),
            ],
            options={
                'verbose_name': 'Branch Stock',
                'verbose_name_plural': 'Branch Stocks',
                'unique_together': {('branch', 'product')},
            },
        ),
    ]
