Port search also searches on the Remote ID and Type
This commit is contained in:
@@ -4,6 +4,10 @@
|
|||||||
|
|
||||||
* netdisco-sshcollector script to get ARP data on devices without SNMP (C. Ramseyer)
|
* netdisco-sshcollector script to get ARP data on devices without SNMP (C. Ramseyer)
|
||||||
|
|
||||||
|
[ENHANCEMENTS]
|
||||||
|
|
||||||
|
* Port search also searches on the Remote ID and Type
|
||||||
|
|
||||||
2.029005 - 2014-08-13
|
2.029005 - 2014-08-13
|
||||||
|
|
||||||
[ENHANCEMENTS]
|
[ENHANCEMENTS]
|
||||||
|
|||||||
@@ -37,6 +37,8 @@ get '/ajax/content/search/port' => require_login sub {
|
|||||||
? { "me.mac" => $q }
|
? { "me.mac" => $q }
|
||||||
: \[ 'me.mac::text ILIKE ?', $likeval ]
|
: \[ 'me.mac::text ILIKE ?', $likeval ]
|
||||||
),
|
),
|
||||||
|
{ "me.remote_id" => $likeclause },
|
||||||
|
{ "me.remote_type" => $likeclause },
|
||||||
]
|
]
|
||||||
},
|
},
|
||||||
{ '+columns' => [qw/ device.dns device.name port_vlans.vlan /],
|
{ '+columns' => [qw/ device.dns device.name port_vlans.vlan /],
|
||||||
|
|||||||
@@ -32,7 +32,9 @@ $(document).ready(function() {
|
|||||||
if (row.device.dns || row.device.name) {
|
if (row.device.dns || row.device.name) {
|
||||||
ddns = ' (' + he.encode(row.device.dns || row.device.name) + ')';
|
ddns = ' (' + he.encode(row.device.dns || row.device.name) + ')';
|
||||||
}
|
}
|
||||||
return '<a href="[% device_ports %]&q=' + encodeURIComponent(data) + '&f=' + encodeURIComponent(row.port) + '">' + he.encode(data) + '[' + he.encode(row.port) + ']</a>' + ddns;
|
return '<a href="[% device_ports %]&q=' + encodeURIComponent(data)
|
||||||
|
+ '&f=' + encodeURIComponent(row.port) + '">' + he.encode(data)
|
||||||
|
+ ' [' + he.encode(row.port) + ']</a>' + ddns;
|
||||||
}
|
}
|
||||||
}, {
|
}, {
|
||||||
"data": 'descr',
|
"data": 'descr',
|
||||||
|
|||||||
Reference in New Issue
Block a user