mirror of
https://github.com/netbox-community/netbox.git
synced 2025-12-20 04:12:25 -06:00
Move Keystone migration to Other migration
This commit is contained in:
@@ -5,6 +5,9 @@ def interface_type_to_slug(apps, schema_editor):
|
||||
Interface = apps.get_model('dcim', 'Interface')
|
||||
Interface.objects.filter(type=32767).update(type='other')
|
||||
|
||||
Interface = apps.get_model('dcim', 'Interface')
|
||||
Interface.objects.filter(type=32766).update(type='keystone')
|
||||
|
||||
|
||||
class Migration(migrations.Migration):
|
||||
|
||||
|
||||
@@ -1,19 +0,0 @@
|
||||
from django.db import migrations
|
||||
|
||||
|
||||
def interface_type_to_slug(apps, schema_editor):
|
||||
Interface = apps.get_model('dcim', 'Interface')
|
||||
Interface.objects.filter(type=32766).update(type='keystone')
|
||||
|
||||
|
||||
class Migration(migrations.Migration):
|
||||
|
||||
dependencies = [
|
||||
('dcim', '0098_devicetype_images'),
|
||||
]
|
||||
|
||||
operations = [
|
||||
migrations.RunPython(
|
||||
code=interface_type_to_slug
|
||||
),
|
||||
]
|
||||
Reference in New Issue
Block a user