Added support for invokers, non-docker runtime. Added ETREE and ELAN models, admin GUI, REST API and test domain
Change-Id: Iade143ba72f967390f0782a4e46e5aa289f9ffbb
diff --git a/xos/admin.py b/xos/admin.py
index cffd99d..6aae88b 100644
--- a/xos/admin.py
+++ b/xos/admin.py
@@ -7,10 +7,10 @@
from services.metronetwork.models import *
-class MetroServiceAdmin(ReadOnlyAwareAdmin):
- model = MetroNetworkService
- verbose_name = "MetroNetwork Service"
- verbose_name_plural = "MetroNetwork Services"
+class MetroNetworkSystemAdmin(ReadOnlyAwareAdmin):
+ model = MetroNetworkSystem
+ verbose_name = "MetroNetwork System"
+ verbose_name_plural = "MetroNetwork System"
list_display = ("name", "administrativeState")
list_display_links = ('name',)
fieldsets = [(None, {
@@ -27,61 +27,53 @@
class NetworkDeviceAdmin(XOSBaseAdmin):
-
+ verbose_name = "Network Device"
+ verbose_name_plural = "Network Devices"
form = NetworkDeviceAdminForm
list_display = ('id', 'restCtrlUrl', 'administrativeState', 'username')
list_display_links = ('id', 'restCtrlUrl', 'administrativeState', 'username')
fields = ('id', 'restCtrlUrl', 'administrativeState', 'username', 'password')
-class NetworkPortAdmin(XOSBaseAdmin):
- list_display = ('id', 'element')
- list_display_links = ('id', 'element')
-
- fields = ('id', 'element')
- readonly_fields = ('id', 'element')
-
class NetworkEdgePortAdmin(XOSBaseAdmin):
+ verbose_name = "Network Edge Port"
+ verbose_name_plural = "Network Edge Ports"
list_display = ('id', 'pid', 'element', 'bwpCfgCbs', 'bwpCfgEbs', 'bwpCfgCir', 'bwpCfgEir', 'name', 'location', 'latlng')
list_display_links = ('id', 'pid', 'element', 'bwpCfgCbs', 'bwpCfgEbs', 'bwpCfgCir', 'bwpCfgEir')
fields = ('id', 'pid', 'element', 'bwpCfgCbs', 'bwpCfgEbs', 'bwpCfgCir', 'bwpCfgEir', 'name', 'location', 'latlng')
readonly_fields = ('id', 'pid', 'element', 'bwpCfgCbs', 'bwpCfgEbs', 'bwpCfgCir', 'bwpCfgEir')
-
-class NetworkInterLinkAdmin(XOSBaseAdmin):
- list_display = ('discovery', 'src', 'dest', 'state')
- list_display_links = ('discovery', 'src', 'dest', 'state')
-
- fields = ('discovery', 'src', 'dest', 'state')
- readonly_fields = ('discovery', 'src', 'dest', 'state')
-
-class NetworkPointToPointConnectionAdmin(XOSBaseAdmin):
- list_display = ('id', 'sid', 'type', 'src', 'dest', 'adminstate', 'operstate')
- list_display_links = ('id', 'sid', 'type', 'src', 'dest', 'adminstate', 'operstate')
-
- fields = ('id', 'sid', 'type', 'src', 'dest', 'adminstate', 'operstate')
- readonly_fields = ('id', 'type', 'src', 'dest', 'operstate')
-
-class NetworkEdgePointToEdgePointConnectionAdmin(XOSBaseAdmin):
+class NetworkEdgeToEdgePointConnectionAdmin(XOSBaseAdmin):
+ verbose_name = "Metro Network E-Line Service"
+ verbose_name_plural = "Metro Network E-Line Services"
list_display = ('id', 'sid', 'type', 'uni1', 'uni2', 'adminstate', 'operstate')
list_display_links = ('id', 'sid', 'type', 'uni1', 'uni2', 'adminstate', 'operstate')
fields = ('id', 'sid', 'type', 'uni1', 'uni2', 'adminstate', 'operstate', 'backend_status')
readonly_fields = ('id', 'type', 'uni1', 'uni2', 'operstate', 'backend_status')
-class NetworkMultipointConnectionAdmin(XOSBaseAdmin):
- list_display = ('type', 'state')
- list_display_links = ('type', 'state')
+class NetworkMultipointToMultipointConnectionAdmin(XOSBaseAdmin):
+ verbose_name = "Metro Network E-LAN Service"
+ verbose_name_plural = "Metro Network E-LAN Services"
+ list_display = ('id', 'sid', 'type', 'adminstate', 'operstate')
+ list_display_links = ('id', 'sid', 'type', 'adminstate', 'operstate')
- fields = ('type', 'eps', 'state')
- readonly_fields = ('type', 'eps', 'state')
+ fields = ('id', 'sid', 'type', 'eps', 'adminstate', 'operstate', 'backend_status')
+ readonly_fields = ('id', 'sid', 'type', 'eps', 'adminstate', 'operstate', 'backend_status')
-admin.site.register(MetroNetworkService, MetroServiceAdmin)
+class NetworkEdgeToMultipointConnectionAdmin(XOSBaseAdmin):
+ verbose_name = "Metro Network E-Tree Service"
+ verbose_name_plural = "Metro Network E-Tree Services"
+ list_display = ('id', 'sid', 'type', 'adminstate', 'operstate')
+ list_display_links = ('id', 'sid', 'type', 'adminstate', 'operstate')
+
+ fields = ('id', 'sid', 'type', 'root', 'eps', 'adminstate', 'operstate', 'backend_status')
+ readonly_fields = ('id', 'sid', 'type', 'root', 'eps', 'adminstate', 'operstate', 'backend_status')
+
+admin.site.register(MetroNetworkSystem, MetroNetworkSystemAdmin)
admin.site.register(NetworkDevice, NetworkDeviceAdmin)
-admin.site.register(NetworkPort, NetworkPortAdmin)
admin.site.register(NetworkEdgePort, NetworkEdgePortAdmin)
-admin.site.register(NetworkInterLink, NetworkInterLinkAdmin)
-admin.site.register(NetworkPointToPointConnection, NetworkPointToPointConnectionAdmin)
-admin.site.register(NetworkEdgeToEdgePointConnection, NetworkEdgePointToEdgePointConnectionAdmin)
-admin.site.register(NetworkMultipointConnection, NetworkMultipointConnectionAdmin)
+admin.site.register(NetworkEdgeToEdgePointConnection, NetworkEdgeToEdgePointConnectionAdmin)
+admin.site.register(NetworkMultipointToMultipointConnection, NetworkMultipointToMultipointConnectionAdmin)
+admin.site.register(NetworkEdgeToMultipointConnection, NetworkEdgeToMultipointConnectionAdmin)