correct circuit model startup scripts
This commit is contained in:
parent
6ab38472be
commit
31f52041f8
6 changed files with 17 additions and 17 deletions
|
@ -13,6 +13,6 @@ for params in providers:
|
|||
provider, created = Provider.objects.get_or_create(**params)
|
||||
|
||||
if created:
|
||||
set_custom_fields_values(name, custom_field_data)
|
||||
set_custom_fields_values(provider, custom_field_data)
|
||||
|
||||
print("📡 Created provider", provider.name)
|
||||
|
|
|
@ -13,6 +13,6 @@ for params in circuit_types:
|
|||
circuit_type, created = CircuitType.objects.get_or_create(**params)
|
||||
|
||||
if created:
|
||||
set_custom_fields_values(name, custom_field_data)
|
||||
set_custom_fields_values(circuit_type, custom_field_data)
|
||||
|
||||
print("⚡ Created Circuit Type", circuit_type.name)
|
||||
|
|
|
@ -9,7 +9,7 @@ if circuits is None:
|
|||
|
||||
required_assocs = {
|
||||
'provider': (Provider, 'name'),
|
||||
'circuit_type': (CircuitType, 'name')
|
||||
'type': (CircuitType, 'name')
|
||||
}
|
||||
|
||||
for params in circuits:
|
||||
|
@ -24,6 +24,6 @@ for params in circuits:
|
|||
circuit, created = Circuit.objects.get_or_create(**params)
|
||||
|
||||
if created:
|
||||
set_custom_fields_values(cid, custom_field_data)
|
||||
set_custom_fields_values(circuit, custom_field_data)
|
||||
|
||||
print("⚡ Created Circuit", circuit.cid)
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue