[Solved] Device tags column in data table

#1

What is the intended use of the “device tags” column in a dashboard data table? I noticed this option as I was looking for a way to put a single tag value next to every data row in data table. However, when I add a device tag column the default configuration shows up as empty in the preview. Is there a way to use Handlebars to pull out a specific tag? Apologies if there’s documentation on this, I looked through the data table page but didn’t see tags mentioned at all.

0 Likes

Tags or best form of grouping
#2

The device tag column does allow you to put one or more tag values in the table. Here’s an example I put together:

The raw value of the attributes is an object. In my case it’s:

{ "particleID": [ "45002e001951353338363036" ], "location": [ "terminal" ] }

You can see the raw data by making the template {{ format value }}.

So as you can see I have a tag named “particleID” with a value that is an array. The values are arrays because you could have the same tag key multiple times. If that happens, each value is added to the array. The template then to display just the value of the “particleID” tag is:

{{ value.particleID.[0] }}
0 Likes

#3

Maybe the issue is that {{format value}} is empty. I’m not exactly sure how my data maps to your example. Here’s how I have my data table defined:

and on the device properties page for the device I have these tags defined:

However, the data table doesn’t show anything for {{format value}}:

I also tried {{value.deviceType}} and {{value.deviceAlias}} with no luck.

0 Likes

#4

Looks like we found the underlying cause. The tag values are properly displayed when looking at a duration other than “Last received data point”. When using last received, the tag values are not displayed. We’ll have a fix out asap.

0 Likes

#5

Good to know, thanks for the update

0 Likes

#6

A fix has been released. You should now be good to go. Thanks for bringing this to our attention!

0 Likes

#7

Great, thanks! I was able to get the tag value I was looking for now

0 Likes