when clicking on the photoeye alarm highlighting the conveyor it is based on

This commit is contained in:
guga kakhadze 2025-06-26 15:48:03 +04:00
parent 0abb58ffdd
commit f98724dad6

View File

@ -3,6 +3,17 @@ def handleTagHighlight(view, currentValue):
if tag == "":
return
splitedTag = str(tag).split("/")
deviceName = splitedTag[-1]
system.perspective.print(splitedTag)
tagCopy = tag
if "PE" in deviceName:
tag = "/".join(splitedTag[:2]) + "/Conveyor/" + deviceName[:-3] + "VFD1"
system.perspective.print(tag)
components = view.rootContainer.getChildren()
@ -19,7 +30,6 @@ def handleTagHighlight(view, currentValue):
if tag == tagPath:
child.props.params["isHighlighted"] = True
system.perspective.openDock('Docked-East-VFD', params={'tagProps': tagProps})
break
return True
return False