Skip to content

Commit

Permalink
refactor(organization): Update database migration files with more acc…
Browse files Browse the repository at this point in the history
…urate names (#5342)

## 📣 Summary
Renamed database migration files for better clarity and consistency and
improved the readability and traceability of the migration history.
  • Loading branch information
noliveleger authored Dec 11, 2024
1 parent eb11221 commit 18628b1
Show file tree
Hide file tree
Showing 3 changed files with 76 additions and 0 deletions.
Original file line number Diff line number Diff line change
@@ -0,0 +1,22 @@
# flake8: noqa: E501
# Generated by Django 4.2.15 on 2024-12-10 18:57

from django.db import migrations, models


class Migration(migrations.Migration):

dependencies = [
('organizations', '0007_update_organization_name_website_and_type'),
]

operations = [
migrations.AlterField(
model_name='organization',
name='mmo_override',
field=models.BooleanField(
default=False,
verbose_name='Make organization multi-member (necessary for adding users)',
),
),
]
Original file line number Diff line number Diff line change
@@ -0,0 +1,54 @@
# Generated by Django 4.2.15 on 2024-12-10 19:00

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


class Migration(migrations.Migration):

dependencies = [
migrations.swappable_dependency(settings.AUTH_USER_MODEL),
('organizations', '0008_alter_mmo_override_verbose_name'),
]

operations = [
migrations.AlterField(
model_name='organization',
name='users',
field=models.ManyToManyField(
related_name='%(app_label)s_%(class)s',
through='organizations.OrganizationUser',
to=settings.AUTH_USER_MODEL,
),
),
migrations.AlterField(
model_name='organizationinvitation',
name='invited_by',
field=models.ForeignKey(
on_delete=django.db.models.deletion.CASCADE,
related_name='%(app_label)s_%(class)s_sent_invitations',
to=settings.AUTH_USER_MODEL,
),
),
migrations.AlterField(
model_name='organizationinvitation',
name='invitee',
field=models.ForeignKey(
blank=True,
null=True,
on_delete=django.db.models.deletion.CASCADE,
related_name='%(app_label)s_%(class)s_invitations',
to=settings.AUTH_USER_MODEL,
),
),
migrations.AlterField(
model_name='organizationuser',
name='user',
field=models.ForeignKey(
on_delete=django.db.models.deletion.CASCADE,
related_name='%(app_label)s_%(class)s',
to=settings.AUTH_USER_MODEL,
),
),
]

0 comments on commit 18628b1

Please sign in to comment.