I am trying to update settings in an alarm on a tag, currently displaying the data in a simple Perspective table, double click to edit a cell, and the alarm should change for the tag.
I have added a "k" in the table cell as seen below.
in the onClick handler:
def runAction(self, event):
tagPath = self.getSibling("TextField").props.text
tagConfig = system.tag.getConfiguration(tagPath,False)
self.getSibling("Label").props.text = tagConfig
tagConfig[0]['alarms'][event.row][event.column] = event.value
self.getSibling("Label_0").props.text = tagConfig
system.tag.configure("", tagConfig,"o")
Contents of "Label":
[{"path":"[default]Testing/TestAlarms","alarms":[{"setpointA":1,"name":"Test Alarm","label":"Test Alarm 1","displayPath":"Testing ","priority":"Medium"}],"tagType":"AtomicTag","name":"TestAlarms","valueSource":"memory"}]
Contents of "Label_0":
[{"path":"[default]Testing/TestAlarms","alarms":[{"setpointA":1,"name":"Test Alarm","label":"kTest Alarm 1","displayPath":"Testing ","priority":"Medium"}],"tagType":"AtomicTag","name":"TestAlarms","valueSource":"memory"}]
The tag does not get updated.
Any ideas what I have done wrong here?
Nothing in console, nothing in server Logs.