mirror of
https://github.com/netbox-community/netbox.git
synced 2026-01-08 04:56:56 -06:00
Some checks are pending
CI / build (20.x, 3.10) (push) Waiting to run
CI / build (20.x, 3.11) (push) Waiting to run
CodeQL / Analyze (${{ matrix.language }}) (none, actions) (push) Waiting to run
CodeQL / Analyze (${{ matrix.language }}) (none, javascript-typescript) (push) Waiting to run
CodeQL / Analyze (${{ matrix.language }}) (none, python) (push) Waiting to run
CI / build (20.x, 3.12) (push) Waiting to run
26 lines
653 B
Python
26 lines
653 B
Python
from django.apps import AppConfig
|
|
|
|
from netbox import denormalized
|
|
|
|
|
|
class CircuitsConfig(AppConfig):
|
|
name = "circuits"
|
|
verbose_name = "Circuits"
|
|
|
|
def ready(self):
|
|
from netbox.models.features import register_models
|
|
from . import signals, search # noqa: F401
|
|
from .models import CircuitTermination
|
|
|
|
# Register models
|
|
register_models(*self.get_models())
|
|
|
|
denormalized.register(CircuitTermination, '_site', {
|
|
'_region': 'region',
|
|
'_site_group': 'group',
|
|
})
|
|
|
|
denormalized.register(CircuitTermination, '_location', {
|
|
'_site': 'site',
|
|
})
|