def selectionChanged(self, selection):
 	cuIndex=""
 	phyName=""
     for row in selection:
     	cuIndex=row[0];
     	phyName=row[1]
     # change $(CU_INDEX) substitution
     macroInput = DataUtil.createMacrosInput(True)
     macroInput.put("CUB", cuIndex)
     macroInput.put("PHY_NAME", phyName)
     macroInput.put("FCT_NAME", fct_name)
     # open OPI
     # see https://svnpub.iter.org/codac/iter/codac/dev/units/m-css-boy/trunk/org.csstudio.opibuilder/src/org/csstudio/opibuilder/scriptUtil/ScriptUtil.java
     ScriptUtil.openOPI(display.getWidget("Table"), fct_name+"-CubicleDetails.opi", 1, macroInput)
コード例 #2
0
    def selectionChanged(self, selection):
        cuIndex = ""
        phyName = ""
        for row in selection:
            cuIndex = row[0]
            phyName = row[1]

    # change $(CU_INDEX) substitution
        macroInput = DataUtil.createMacrosInput(True)
        macroInput.put("CUB", cuIndex)
        macroInput.put("PHY_NAME", phyName)
        macroInput.put("FCT_NAME", fct_name)
        # open OPI
        # see https://svnpub.iter.org/codac/iter/codac/dev/units/m-css-boy/trunk/org.csstudio.opibuilder/src/org/csstudio/opibuilder/scriptUtil/ScriptUtil.java
        ScriptUtil.openOPI(display.getWidget("Table"),
                           fct_name + "-CubicleDetails.opi", 1, macroInput)
コード例 #3
0
 def selectionChanged(self, selection):
     cuName = ""
     phyName = ""
     for row in selection:
         phyName = row[1]
         cuName = row[0]
     # change $(CU) substitution
     macroInput = DataUtil.createMacrosInput(True)
     macroInput.put("CU", cuName)
     macroInput.put("PHY_NAME", phyName)
     macroInput.put("FCT_NAME", fct_name)
     # open OPI
     # see https://svnpub.iter.org/codac/iter/codac/dev/units/m-css-boy/trunk/org.csstudio.opibuilder/src/org/csstudio/opibuilder/scriptUtil/ScriptUtil.java
     if cuName.startswith("P"):
         ScriptUtil.openOPI(display.getWidget("Table"), fct_name + "-PLCDetails.opi", 1, macroInput)
     else:
         ScriptUtil.openOPI(display.getWidget("Table"), fct_name + "-CubiclePLCDetails.opi", 0, macroInput)
 def selectionChanged(self, selection):
 	cuName=""
 	phyName=""
     plcIocHlts =""
     for row in selection:
     	phyName=row[1]
     	cuName=row[0]
     	plcIocHlts=row[6];
     # change $(CU) substitution
     macroInput = DataUtil.createMacrosInput(True)
     macroInput.put("CU", cuName)
     macroInput.put("PHY_NAME", phyName)
     macroInput.put("FCT_NAME", fct_name)
     if plcIocHlts == "":
     	macroInput.put("SHOW_PLC_IOC", "false")
     else:
     	macroInput.put("SHOW_PLC_IOC", "true")
     # open OPI
     # see https://svnpub.iter.org/codac/iter/codac/dev/units/m-css-boy/trunk/org.csstudio.opibuilder/src/org/csstudio/opibuilder/scriptUtil/ScriptUtil.java
     ScriptUtil.openOPI(display.getWidget("Table"), fct_name+"-CtrlUnitDetails.opi", 1, macroInput)
コード例 #5
0
    def selectionChanged(self, selection):
        cuName = ""
        phyName = ""
        for row in selection:
            phyName = row[1]
            cuName = row[0]

    # change $(CU) substitution
        macroInput = DataUtil.createMacrosInput(True)
        macroInput.put("CU", cuName)
        macroInput.put("PHY_NAME", phyName)
        macroInput.put("FCT_NAME", fct_name)
        # open OPI
        # see https://svnpub.iter.org/codac/iter/codac/dev/units/m-css-boy/trunk/org.csstudio.opibuilder/src/org/csstudio/opibuilder/scriptUtil/ScriptUtil.java
        if cuName.startswith('P'):
            ScriptUtil.openOPI(display.getWidget("Table"),
                               fct_name + "-PLCDetails.opi", 1, macroInput)
        else:
            ScriptUtil.openOPI(display.getWidget("Table"),
                               fct_name + "-CubiclePLCDetails.opi", 0,
                               macroInput)
コード例 #6
0
    def selectionChanged(self, selection):
        cuName = ""
        phyName = ""
        plcIocHlts = ""
        for row in selection:
            phyName = row[1]
            cuName = row[0]
            plcIocHlts = row[6]
    # change $(CU) substitution
        macroInput = DataUtil.createMacrosInput(True)
        macroInput.put("CU", cuName)
        macroInput.put("PHY_NAME", phyName)
        macroInput.put("FCT_NAME", fct_name)
        if plcIocHlts == "":
            macroInput.put("SHOW_PLC_IOC", "false")
        else:
            macroInput.put("SHOW_PLC_IOC", "true")

    # open OPI
    # see https://svnpub.iter.org/codac/iter/codac/dev/units/m-css-boy/trunk/org.csstudio.opibuilder/src/org/csstudio/opibuilder/scriptUtil/ScriptUtil.java
        ScriptUtil.openOPI(display.getWidget("Table"),
                           fct_name + "-CtrlUnitDetails.opi", 1, macroInput)
コード例 #7
0
ファイル: detach_window.py プロジェクト: guduan/hla-1
from org.csstudio.opibuilder.scriptUtil import PVUtil, ScriptUtil, GUIUtil     
from org.eclipse.ui import PlatformUI

opi_container = display.getWidget("opi_container")
linking_container = opi_container.getChild("linking_container")

if linking_container is not None:
    opi_file = linking_container.getPropertyValue("opi_file")
    opi_container.removeAllChildren()
    GUIUtil.compactMode()
    ScriptUtil.openOPI(widget, str(opi_file), 2, None)
    widget.getPV().setValue(1)


    
コード例 #8
0
                line2 = line.replace('PV-NAME', v + '(0)')
                line2 = line2.replace('X_POS', str(xPos))
                line2 = line2.replace('Y_POS', str(yPos))
                line2 += '\n'
                hold.append(line2)
            yPos += 45
            if yPos >= yLimit:
                yPos = 25
                xPos += 300
        hold.append(lastLine)

        opiTest = ''.join(hold)

        for pv in testpvs:
            opiTest = opiTest.replace(pv, 'loc://' + pv)

        with open(testCtrlFin, 'w') as f:            \
                         f.write(opiTest)

    # wait five seconds before printing success message.
    # Gives workspace time to update and find new screens to open
    sleep(5)
    pvs[2].setValue('TEST SCREENS CREATED')

    # opens test screen and control screen
    ScriptUtil.openOPI(widget, testFin, 2, None)
    ScriptUtil.openOPI(widget, testCtrlFin, 2, None)

    pvs[2].setValue('')
    pvs[0].setValue(0)
コード例 #9
0
ファイル: open_error_window.py プロジェクト: lnls-fac/hla
from org.csstudio.opibuilder.scriptUtil import PVUtil, ScriptUtil, DataUtil
from org.eclipse.ui import PlatformUI

## Set OPI File
opi_file = "error/error_window.opi"

## Open OPI
if PVUtil.getDouble(pvArray[0]) != 0:
	ScriptUtil.openOPI(widget, opi_file, 2, None)