View Issue Details

IDProjectCategoryView StatusLast Update
749RackTablesdefaultpublic2013-03-16 18:04
Reportergrin Assigned Toinfrastation  
Status closedResolutionfixed 
Product Version0.20.1 
Target Version0.20.4Fixed in Version0.20.4 
Summary749: Show inner interface IDs
DescriptionActivating a new SFP type is a pain in the arse, took quite a time to find this email:
Is it wikified? :)

Anyway, it's hard to figure out IIF ids for "Default port outer interface IDs", since they seem to be unlisted everywhere.

Patch included to, well, include them.
TagsNo tags attached.




2013-02-19 16:10


iif_id.patch (976 bytes)   
--- interface.php.20130219	2013-02-19 16:03:30.000000000 +0100
+++ interface.php	2013-02-19 16:05:49.000000000 +0100
@@ -6507,7 +6507,7 @@
 	global $nextorder;
 	echo '<br><table class=cooltable align=center border=0 cellpadding=5 cellspacing=0>';
-	echo '<tr><th class=tdleft>inner interface</th><th class=tdleft>outer interface</th></tr>';
+	echo '<tr><th class=tdleft>inner interface</th><th></th><th class=tdleft>outer interface</th><th></th></tr>';
 	$last_iif_id = 0;
 	$order = 'even';
 	foreach (getPortInterfaceCompat() as $record)
@@ -6517,7 +6517,7 @@
 			$order = $nextorder[$order];
 			$last_iif_id = $record['iif_id'];
-		echo "<tr class=row_${order}><td class=tdleft>${record['iif_name']}</td><td class=tdleft>${record['oif_name']}</td></tr>";
+		echo "<tr class=row_${order}><td class=tdleft>${record['iif_name']}</td><td>${record['iif_id']}</td><td class=tdleft>${record['oif_name']}</td><td>${record['oif_id']}</td></tr>";
 	echo '</table>';
iif_id.patch (976 bytes)   


2013-02-19 18:38

administrator   ~0001139

Perhaps a mouse hover hint would do?


2013-02-19 19:01

reporter   ~0001141

I have reached the conclusion that you have some secret love for mouseovers. :-) I'm rather for the explicit visuals especially when I have to figure out what's what and an overview (when everything is visible at once) helps much better than a mouseover (have to view them one by one).

As far as I know there is no way to get the list of IIF id's, so this table may be The One.

Btw I quite dislike the database-kind of stuff hidden in the intrface config. It would be much nicer to have a similar config table for:
* List source: object, for which asset tag should be set
* List of object with Cacti graphs
* List of devices running CDP
* List source: IPv4 NAT performers
* List source: IPv4-enabled objects
* List source: object, for which common name should be set
* List source: objects without ports

as well as
* Default port outer interface IDs
* List source: virtual objects


2013-02-20 05:07

administrator   ~0001143

The "list source" series of options accept arbitrary text in RackCode syntax, they are not database-like.

The default OIF map can indeed be backed with a table, but in this case it won't be overridable by each user any more. If this idea makes it through the users mailing list, I won't mind the change.

If you consider explicit table columns better than mouseovers, please make this consistent (THs and column ordering) with other similar tables and I will commit it.


2013-02-28 20:02

reporter   ~0001173

I will create the patch but please bear with me, I'm doing at least five different things at once. :-P


2013-02-28 20:08

administrator   ~0001175

Sure, take your time.


2013-03-07 13:27

reporter   ~0001237

So... I looked around.

First, a bit prettier is this:
--- a/inc/interface.php Mon Feb 25 22:31:57 2013 +0100
+++ b/inc/interface.php Thu Mar 07 13:21:01 2013 +0100
@@ -6507,7 +6507,7 @@
        global $nextorder;
        echo '
<table class=cooltable align=center border=0 cellpadding=5 cellspacing=0>';
- echo '<tr><th class=tdleft>inner interface</th><th></th><th class=tdleft>outer interface</th><th></th></tr>';
+ echo '<tr><th class=tdleft>inner interface</th><th>iif key</th><th class=tdleft>index.php?page=chapter&chapter_no=2</th><th>oif key</th></tr>';
        $last_iif_id = 0;
        $order = 'even';
        foreach (getPortInterfaceCompat() as $record)

But that's basically the same as before.

I have checked most of the config tables an apart from Dictionary (which shows 'key' for me, I believe it's already in the upstream) I see no other tables which may benefit from showing the keys. The purpose to show the keys is to be able to reference them in the aforementioned "Interface config", and basically the iif and iof keys are used.

Th other thing you mentioned that the entries are RackCode. Yes, I am aware of that however I observed that I almost exclusively use a form "{$typeid_4} or {$typeid_7} or {$typeid_8} or {$typeid_798}...". I don't know the usual usage patterns but my guess is that most people don't use fancy features of RackCode here. It could be a solution to be able to use an auitomatic config to generate the rackcode and the possibiliy to override the result manually, if someone wants it. This may be true for the "iif=oif, ..." and similar lists, too.

And in fact I would have not looked for them in "USER INTERFACE" section: for me enabling ports is not really the part of the UI. :-)

But these are just feedback, its quite okay for me like it is now.


2013-03-16 18:04

administrator   ~0001245

Commit dc7a926 stands for the patch originally submitted, which seems to be cleaner than the second. Thank you!

Issue History

Date Modified Username Field Change
2013-02-19 16:10 grin New Issue
2013-02-19 16:10 grin File Added: iif_id.patch
2013-02-19 18:38 infrastation Note Added: 0001139
2013-02-19 19:01 grin Note Added: 0001141
2013-02-19 21:55 infrastation Assigned To => infrastation
2013-02-19 21:55 infrastation Status new => assigned
2013-02-19 21:56 infrastation Target Version => 0.20.4
2013-02-20 05:07 infrastation Note Added: 0001143
2013-02-28 18:42 infrastation Status assigned => feedback
2013-02-28 20:02 grin Note Added: 0001173
2013-02-28 20:02 grin Status feedback => assigned
2013-02-28 20:08 infrastation Note Added: 0001175
2013-03-02 16:37 infrastation Target Version 0.20.4 =>
2013-03-07 13:27 grin Note Added: 0001237
2013-03-16 18:04 infrastation Note Added: 0001245
2013-03-16 18:04 infrastation Status assigned => closed
2013-03-16 18:04 infrastation Resolution open => fixed
2013-03-16 18:04 infrastation Fixed in Version => 0.20.4
2013-03-16 18:04 infrastation Target Version => 0.20.4