torrus, UI, RT10574
[freeside.git] / torrus / templates / default-dir.html
index fe13a9b..bcdc001 100644 (file)
@@ -4,9 +4,26 @@
 
 [% INCLUDE legend %]
 
-[% IF matches(thepath,'Interface_Counters/$') %]
-   [% freesideComponent('/elements/init_overlib.html') %]
-[% END %]
+[% 
+ IF matches(thepath,'Interface_Counters/$');
+   freesideComponent('/elements/init_overlib.html');
+    nms = load_nms();
+    router = nodeName(parent(token));
+    serviceids = get_serviceids(nms,router);
+ END;
+ IF matches(thepath,'Interface_Counters/.*?/$');
+    nms = load_nms();
+    router = nodeName(parent(parent(token)));
+    serviceids = get_serviceids(nms,router);
+
+    # HACK! this doesn't do what you think it does...
+    popup_link('nms-add_iface.html',router,uri_escape(slash2underscore(nodeName(token))),nms,serviceids);
+ END; 
+ IF matches(thepath,'Routers/$');
+   freesideComponent('/elements/init_overlib.html');
+   popup_link('nms-add_router.html');
+ END;
+%]
 
 <P>Directories you can jump to:</P>
 <DIV CLASS="Listing">
@@ -45,7 +62,9 @@
       [% hidden ? '</EM>':'';
          thisIsAlias ? '</EM>':''; %]
       [% IF matches(thepath,'Interface_Counters/$') %]
-        [% popup_link('nms-add_iface.html',nodeName(parent(token)),uri_escape(nodeName(child))) %]
+       <FONT SIZE="-1">
+        [% popup_link('nms-add_iface.html',router,uri_escape(slash2underscore(nodeName(child))),nms,serviceids) %]
+       </FONT>
       [% END %]
     </SPAN>
        [% IF comment %]