Fixes #15695: Clear any legacy group permission associations during migration
This commit is contained in:
parent
4562e347fd
commit
2a8876846f
|
@ -63,6 +63,11 @@ class Migration(migrations.Migration):
|
|||
field=models.ManyToManyField(blank=True, related_name='object_permissions', to='users.group'),
|
||||
),
|
||||
|
||||
# Delete any lingering group assignments for legacy permissions (from before NetBox v2.9)
|
||||
migrations.RunSQL(
|
||||
"DELETE from auth_group_permissions"
|
||||
),
|
||||
|
||||
# Delete groups from the old table
|
||||
migrations.RunSQL(
|
||||
"DELETE from auth_group"
|
||||
|
|
Loading…
Reference in New Issue