In the Vision version of this module, there was a Notes field that could be enabled and would show the notes for the selected alarm from the list. I don’t see this feature on the Perspective module. It has a Notes column but generally the notes are too long to display in a table column. Is there a way to get the selected alarm from the Table object and use this to find the associated notes to display in a Label instead? I found that the notes are also visible in the Popup Modal, but it’s more difficult to find so I prefer the “notes area” method if possible.
The table has props.selection which appears to contain the data of the selected alarms in the table. props.selection.data[yourNdxHere] contains a notes key when alarms are selected.
Thank you. I have this working but trying to figure out how to deal with no alarm selected. In this case, the props.selection.data[0].notes does not exist so causes errors in the binding. I did an if statement checking if the value was null and fill in generic text instead, but I still get the red overlay.
I would expect something like this to work:
if(
!isNull({props.selection.data}) &&
len({props.selection.data}) > 0,
{props.selection.data}[0]['notes'], ""
)
(My path to the props is missing the leading selectors to the component because I don't know your view layout)
Show your expression, you might not be checking everything you need to.
I got it to work with this:
if(isNull({../AlarmStatusTable.props.selection.active.data[0]}),
"Select an alarm from the list above to see extended notes for that alarm",
if({../AlarmStatusTable.props.selection.active.data[0]}['notes']="",
"There are no extended notes for the selected alarm",
{../AlarmStatusTable.props.selection.active.data[0]}['notes']))