I'm trying to create a dropdown with some index values that I get from a previous array.
I first write this function to get the indexes:
let indexes = [];
// Iterate through each item in msg.payload
msg.payload.forEach((item, index) => {
// Push the index into the indexes array
indexes.push(index);
});
// Set the indexes for the dropdown
msg.payload = indexes;
return msg;
And then I connect it to the ui-dropdown node. However, the dropdown appears in blank on my dashboard.
Anyone that may know why ?????
Thanks