You can not select more than 25 topics Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.

23 lines
601 B

local WIT, core = ...
local GridColumns = core.GridColumns
function GridColumns.LocationsColumn()
local self = GridColumns.GridColumn('Locations')
function self.Value(data)
local locations = {}
if data.Locations then
for _, location in pairs(data.Locations) do
table.insert(locations, core.LocationHelper.GetAreaName(location))
end
elseif data.MapId then
table.insert(locations, core.LocationHelper.GetMapName(data.MapId))
end
return table.concat(locations, ", ")
end
return self
end