Fixes VLAN Tag is cut when shortening Host Names (#5647)

This commit is contained in:
MatteoBiscosi 2021-07-08 12:31:27 +02:00
parent b941752b0a
commit 92f89917c3
3 changed files with 8 additions and 4 deletions

View file

@ -1312,13 +1312,17 @@ end
-- #################################
function hostVisualization(ip, name, vlan, short_version)
function hostVisualization(ip, name, vlan, short_version, short_name)
local res = ip
if not isEmptyString(name) then
res = name
end
if short_name and (short_name == true) then
res = shortenString(res)
end
if vlan ~= nil and tonumber(vlan) > 0 then
res = res .. "@" .. getFullVlanName(vlan, short_version)
end