runtime/NevowServer.py
branchnevow_service_rework
changeset 2219 73042b2d8d65
parent 2217 a603d1ba287b
child 2246 51047284cb0e
child 2266 ed415982a9aa
--- a/runtime/NevowServer.py	Fri Jul 06 15:09:44 2018 +0200
+++ b/runtime/NevowServer.py	Tue Jul 10 12:51:28 2018 +0200
@@ -171,6 +171,8 @@
                                            label=_("Send a message to the log"),
                                            action=_("Send"))
 
+customSettingsURLs = {
+}
 
 class SettingsPage(rend.Page):
     # We deserve a slash
@@ -196,9 +198,6 @@
                                        webform.renderForms('dynamicSettings'),
                                    ]]])
 
-    def __init__(self):
-        rend.Page.__init__(self)
-
     def configurable_staticSettings(self, ctx):
         return configurable.TypedInterfaceConfigurable(self)
 
@@ -210,6 +209,11 @@
         if _PySrv.plcobj is not None:
             _PySrv.plcobj.LogMessage(level, "Web form log message: " + message )
 
+    def locateChild(self, ctx, segments):
+        if segments[0] in customSettingsURLs :
+            return customSettingsURLs[segments[0]](ctx, segments)
+        return super(SettingsPage, self).locateChild(ctx, segments)
+
 
 class WebInterface(athena.LivePage):