@ -4,7 +4,7 @@ import logging
import os
import os
#DEFINITIONS
#DEFINITIONS
lProcessName = " OpenRPA_RobotScreenActive.exe "
lProcessName = " OpenRPA_RobotScreenActive.exe "
lStartFilePath = os . path . join ( os . getcwd ( ) , " ..\\ Utils \\ RobotScreenActive\\ pyOpenRPA.Tools.RobotScreenActive_x64.cmd " )
lStartFilePath = os . path . join ( os . getcwd ( ) , " RobotScreenActive\\ pyOpenRPA.Tools.RobotScreenActive_x64.cmd " )
def RenderRobotScreenActive ( inGlobalConfiguration ) :
def RenderRobotScreenActive ( inGlobalConfiguration ) :
#Subheader Variants
#Subheader Variants
lSubheaderRunTrueText = " State: <span style= \" color:green \" >Turned on</span> "
lSubheaderRunTrueText = " State: <span style= \" color:green \" >Turned on</span> "
@ -14,6 +14,11 @@ def RenderRobotScreenActive(inGlobalConfiguration):
import os
import os
lRobotScreenActivePath = lStartFilePath
lRobotScreenActivePath = lStartFilePath
lOnClickRunButton = f " mGlobal.Controller.CMDRunText( ' start cmd /K { lRobotScreenActivePath } ' ); "
lOnClickRunButton = f " mGlobal.Controller.CMDRunText( ' start cmd /K { lRobotScreenActivePath } ' ); "
# Activity update orchestrator
lActivityOrchestratorBuildPath = os . getcwd ( )
lActivityOrchestratorBuildPathEscaped = lActivityOrchestratorBuildPath . replace ( " \\ " , " \\ \\ " )
lActivityOrchestratorUpdateStr = f " mGlobal.Controller.CMDRunText( \" taskkill /f /im OpenRPA_Orchestrator.exe & timeout 2 & cd { lActivityOrchestratorBuildPathEscaped } & git reset --hard & git pull origin master & pyOpenRPA.Orchestrator_x64_administrator_startup.cmd \" ); " . replace ( " \" " , " " " )
lActivityOrchestratorUpdateHTMLStr = f ' <a onclick= \" { lActivityOrchestratorUpdateStr } \" style= \" color:orange \" >Обновить orchestrator из GIT и перезапустить</a> '
#Force close button
#Force close button
lOnClickForceCloseButton = f " mGlobal.Controller.CMDRunText( ' taskkill /F /im { lProcessName } ' ); "
lOnClickForceCloseButton = f " mGlobal.Controller.CMDRunText( ' taskkill /F /im { lProcessName } ' ); "
#Result template
#Result template
@ -23,6 +28,7 @@ def RenderRobotScreenActive(inGlobalConfiguration):
" DataStorageKey " : " RobotScreenActive " , #Use key for set current dict in mGlobal.DataStorage["DtaaStorageKey"] on client side
" DataStorageKey " : " RobotScreenActive " , #Use key for set current dict in mGlobal.DataStorage["DtaaStorageKey"] on client side
" SubheaderText " : lSubheaderRunFalseText ,
" SubheaderText " : lSubheaderRunFalseText ,
" BodyKeyValueList " : [
" BodyKeyValueList " : [
{ " Key " : " Репозиторий " , " Value " : lActivityOrchestratorUpdateHTMLStr }
] ,
] ,
" FooterText " : " Last update: 9:38:00 09.10.2019 " ,
" FooterText " : " Last update: 9:38:00 09.10.2019 " ,
" FooterButtonX2List " : [
" FooterButtonX2List " : [