diff --git a/chat/migrations/0010_remove_chatroom_unique_room_name_per_service.py b/chat/migrations/0010_remove_chatroom_unique_room_name_per_service.py new file mode 100644 index 00000000..27daaa40 --- /dev/null +++ b/chat/migrations/0010_remove_chatroom_unique_room_name_per_service.py @@ -0,0 +1,17 @@ +# Generated by Django 4.1.13 on 2024-12-15 08:23 + +from django.db import migrations + + +class Migration(migrations.Migration): + + dependencies = [ + ("chat", "0009_alter_chatrole_id_alter_chatroom_id"), + ] + + operations = [ + migrations.RemoveConstraint( + model_name="chatroom", + name="unique_room_name_per_service", + ), + ] diff --git a/chat/models.py b/chat/models.py index 13f39091..a58553d3 100644 --- a/chat/models.py +++ b/chat/models.py @@ -55,13 +55,6 @@ class ChatRoom(models.Model): audio_channel_url = models.URLField(null=True, blank=True) audio_channel_id = models.CharField(max_length=255, null=True, blank=True) - class Meta: - constraints = [ - models.UniqueConstraint( - name="unique_room_name_per_service", fields=["service", "name"] - ), - ] - def __str__(self): return self.name