remove wrong unique constraint

This commit is contained in:
Kuroshini 2020-02-06 21:50:27 +03:00
parent 93da9370bc
commit 2c3beb78d8
2 changed files with 2 additions and 2 deletions

View File

@ -27,7 +27,7 @@ class Migration(migrations.Migration):
options={
'verbose_name': 'establishment gallery',
'verbose_name_plural': 'establishment galleries',
'unique_together': {('establishment', 'is_main'), ('establishment', 'image')},
'unique_together': {('establishment', 'image')},
},
),
migrations.AddField(

View File

@ -963,7 +963,7 @@ class EstablishmentGallery(IntermediateGalleryModelMixin):
"""Meta class."""
verbose_name = _('establishment gallery')
verbose_name_plural = _('establishment galleries')
unique_together = (('establishment', 'is_main'), ('establishment', 'image'))
unique_together = ('establishment', 'image')
class PositionQuerySet(models.QuerySet):