OK, I guess I'm stuck. Here is what I'm trying to do:
I export a bunch of data about my printers from my print server and SNMP (to pull toner data). I combine all that together into an array of PSObjects and export that to a JSON file. The object look like this:
Thanks! Its funny, a while back I built a tool that used Firebase and AgularFire to generate a dashboard, not unlike this one. This is obviously way easier since I don't have to be the one to keep up with whatever underlying web technology is running the whole thing :P
I've also thought about trying to dump each toner out as a json file and try to work with them that way. But I think I just run in to the same issue. I think once you get down to the Endpoint on New-UDChart, you lose the object from the loop and I'm not sure if you can pass it along.
Try this. https://pastebin.com/5PWR4cn3 Use pscustom object to assign the data from the toner variable, that way the dataproperties can be called from new-udchatdataset. This is what I have been doing for data sets.
3
u/JazDriveOmega Nov 07 '17
OK, I guess I'm stuck. Here is what I'm trying to do:
I export a bunch of data about my printers from my print server and SNMP (to pull toner data). I combine all that together into an array of PSObjects and export that to a JSON file. The object look like this:
I want to create a Colum and Chart for each printer, displaying the levels of toner from the toner property.
This is what my dashboard code looks like:
but what I get back is a chart that looks like this:
https://imgur.com/a/QafiC
I'm not sure what I'm missing here. Is this some kind of a scoping issue? I've tried debugging in VS Code but it didn't really get me anywhere.