13 lines
341 B
Plaintext
13 lines
341 B
Plaintext
[% USE CSV -%]
|
|
[% CSV.dump([ 'Description' 'Port' 'Name' 'Vlan' ]) %]
|
|
|
|
[% FOREACH row IN results %]
|
|
[% mylist = [] %]
|
|
[% myport = "$row.ip [ $row.port ] (" _ row.device.dns _ ")" IF row.device.dns %]
|
|
[% FOREACH col IN [ row.name myport row.descr row.vlan ] %]
|
|
[% mylist.push(col) %]
|
|
[% END %]
|
|
[% CSV.dump(mylist) %]
|
|
|
|
[% END %]
|