# Generated by Django 5.1.5 on 2025-02-09 11:07

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


class Migration(migrations.Migration):

    dependencies = [
        ('access', '0003_alter_team_organization_organizationnotes_teamnotes'),
        ('core', '0013_alter_manufacturer_organization_and_more'),
        ('settings', '0007_externallink_button_text_alter_externallink_name'),
    ]

    operations = [
        migrations.AlterField(
            model_name='externallink',
            name='organization',
            field=models.ForeignKey(help_text='Organization this belongs to', on_delete=django.db.models.deletion.CASCADE, related_name='+', to='access.organization', validators=[access.models.tenancy.TenancyObject.validatate_organization_exists], verbose_name='Organization'),
        ),
        migrations.CreateModel(
            name='ExternalLinkNotes',
            fields=[
                ('modelnotes_ptr', models.OneToOneField(auto_created=True, on_delete=django.db.models.deletion.CASCADE, parent_link=True, primary_key=True, serialize=False, to='core.modelnotes')),
                ('model', models.ForeignKey(help_text='Model this note belongs to', on_delete=django.db.models.deletion.CASCADE, related_name='notes', to='settings.externallink', verbose_name='Model')),
            ],
            options={
                'verbose_name': 'External Link Note',
                'verbose_name_plural': 'External Link Notes',
                'db_table': 'settings_external_link_notes',
                'ordering': ['-created'],
            },
            bases=('core.modelnotes',),
        ),
    ]
