diff --git a/.gitignore b/.gitignore index 2cdd8826..62bf0afd 100755 --- a/.gitignore +++ b/.gitignore @@ -17,6 +17,9 @@ /**/OpenRPA_Orchestrator.exe /**/OpenRPAOrchestrator.exe /**/OpenRPARobotGUIx32.exe +/**/orpa-std.exe +/**/orpa-rbt.exe +/**/orpa-agt.exe /**/orpa-orc.exe /**/orpa-agent.exe /**/OpenRPARobotGUIx64.exe diff --git a/Resources/WPy32-3720/python-3.7.2/OpenRPAUIDesktopX32.exe b/Resources/WPy32-3720/python-3.7.2/OpenRPAUIDesktopX32.exe new file mode 100644 index 00000000..4053ac88 Binary files /dev/null and b/Resources/WPy32-3720/python-3.7.2/OpenRPAUIDesktopX32.exe differ diff --git a/Sources/pyOpenRPA/Resources/Web/orpa/footer.xhtml b/Sources/pyOpenRPA/Resources/Web/orpa/footer.xhtml index 6acb2114..52d682df 100755 --- a/Sources/pyOpenRPA/Resources/Web/orpa/footer.xhtml +++ b/Sources/pyOpenRPA/Resources/Web/orpa/footer.xhtml @@ -14,6 +14,7 @@

Интересный факт

Портал pyOpenRPA сделан на оркестраторе pyOpenRPA за 7 дней - присоединяйся к сильной стороне!

+

pyOpenRPA - роботы помогут!

Контактная информация

diff --git a/Sources/pyOpenRPA/Resources/Web/orpa/studio.xhtml b/Sources/pyOpenRPA/Resources/Web/orpa/studio.xhtml new file mode 100644 index 00000000..73f54490 --- /dev/null +++ b/Sources/pyOpenRPA/Resources/Web/orpa/studio.xhtml @@ -0,0 +1,987 @@ + + + + + Студия pyOpenRPA + + + + + + + + + + + + {% include 'header.xhtml' %} + + +
+

+ +
+ Шаг 1. Обнаружить UIO +
+

+ +
+
+ +
+
+

Выбрать UI элемент слева в дереве

+
+
+ +
+
+
+
+
+ +
+ Протокол: win32 или uia + +
+
+ +
+
+
+ +
+ +

+ +
+ Шаг 2. Редактировать UIO селектор +
+

+ +
+
+
Редактировать UIO селектор
+ [{"depth_start": 1, "depth_end": 1, "index"|"ctrl_index": 0, "title": "", "title_re": ".*", "rich_text": "", "rich_text_re": ".*", "class_name": "", "class_name_re": ".*", "friendly_class_name": "", "friendly_class_name_re": ".*", "control_type": "", "control_type_re": ".*", "is_enabled": true, "is_visible": true}] + + + +
Список подходящих UIO
+
+
+
+
Выбрать действие
+ + +
Установить аргументы
+
+ +
+

+ +
Результат
+
+
+
+ +
+ {% include 'footer.xhtml' %} + + + + + + + + diff --git a/Sources/pyOpenRPA/Studio/Studio.py b/Sources/pyOpenRPA/Studio/Studio.py index f15961f8..7a2426d5 100755 --- a/Sources/pyOpenRPA/Studio/Studio.py +++ b/Sources/pyOpenRPA/Studio/Studio.py @@ -30,6 +30,13 @@ RobotConnector.mGlobalDict = gSettingsDict #Init the robot RobotConnector.UIDesktop.Utils.ProcessBitness.SettingsInit(gSettingsDict["ProcessBitness"]) +from pyOpenRPA.Utils.Render import Render +from pyOpenRPA.Tools import CrossOS # https://schedule.readthedocs.io/en/stable/examples.html +lFileStr = CrossOS.PathJoinList(CrossOS.PathSplitList(__file__)[:-2] + ["Resources","Web","orpa","studio.xhtml"]) +gRender = Render(inTemplatePathStr=lFileStr,inTemplateRefreshBool=True) +from pyOpenRPA import __version__ + + # HTTP Studio web server class class testHTTPServer_RequestHandler(BaseHTTPRequestHandler): #ResponseContentTypeFile @@ -49,7 +56,16 @@ class testHTTPServer_RequestHandler(BaseHTTPRequestHandler): lStudioFolder = "\\".join(__file__.split("\\")[:-1]) #Мост между файлом и http запросом (новый формат) if self.path == "/": - self.SendResponseContentTypeFile('text/html', os.path.join(lStudioFolder, "Web\\Index.xhtml")) + # Пример использования + global gRender + lStr = gRender.Generate(inDataDict={"title":"СТУДИЯ PYOPENRPA", "subtitle":"ПОИСК UIO СЕЛЕКТОРА", "version":__version__}) + # Send response status code + self.send_response(200) + # Send headers + self.send_header('Content-type','text/html') + self.end_headers() + # Write content as utf-8 data + self.wfile.write(bytes(lStr, "utf8")) #Мост между файлом и http запросом (новый формат) if self.path == '/3rdParty/Semantic-UI-CSS-master/semantic.min.css': self.SendResponseContentTypeFile('text/css', os.path.join(lStudioFolder, "..\\Resources\\Web\\Semantic-UI-CSS-master\\semantic.min.css")) @@ -67,10 +83,55 @@ class testHTTPServer_RequestHandler(BaseHTTPRequestHandler): self.SendResponseContentTypeFile('font/woff2', os.path.join(lStudioFolder, "..\\Resources\\Web\\Semantic-UI-CSS-master\\themes\\default\\assets\\fonts\\icons.woff2")) #Мост между файлом и http запросом (новый формат) if self.path == '/favicon.ico': - self.SendResponseContentTypeFile('image/x-icon', os.path.join(lStudioFolder, "Web\\favicon.ico")) + self.SendResponseContentTypeFile('image/x-icon', os.path.join(lStudioFolder, "..\\Resources\\Web\\orpa\\favicon.ico")) + #Мост между файлом и http запросом (новый формат) + if self.path == '/pyOpenRPA_logo.png' or self.path == '/orpa/resources/Web/orpa/logo.png': + self.SendResponseContentTypeFile('image/png', os.path.join(lStudioFolder, "..\\Resources\\Web\\orpa\\logo.png")) #Мост между файлом и http запросом (новый формат) - if self.path == '/pyOpenRPA_logo.png': - self.SendResponseContentTypeFile('image/png', os.path.join(lStudioFolder, "..\\Resources\\Web\\pyOpenRPA_logo.png")) + if self.path == '/pyOpenRPA_logo.png' or self.path == '/orpa/resources/Web/orpa/logo.png': + self.SendResponseContentTypeFile('image/png', os.path.join(lStudioFolder, "..\\Resources\\Web\\orpa\\logo.png")) + if self.path == '/orpa/resources/Web/orpa/styleset/home.css': self.SendResponseContentTypeFile('text/css', os.path.join(lStudioFolder, "..\\Resources\\Web\\orpa\\styleset\\home.css")) + if self.path == '/orpa/resources/Web/orpa/styleset/home.js': self.SendResponseContentTypeFile('application/javascript', os.path.join(lStudioFolder, "..\\Resources\\Web\\orpa\\styleset\\home.js")) + if self.path == '/orpa/resources/Web/orpa/styleset/bg1.jpg': self.SendResponseContentTypeFile('image/png', os.path.join(lStudioFolder, "..\\Resources\\Web\\orpa\\styleset\\bg1.jpg")) + if self.path == '/orpa/resources/Web/orpa/styleset/bg2.jpg': self.SendResponseContentTypeFile('image/png', os.path.join(lStudioFolder, "..\\Resources\\Web\\orpa\\styleset\\bg2.jpg")) + if self.path == '/orpa/resources/Web/orpa/styleset/bg3.jpg': self.SendResponseContentTypeFile('image/png', os.path.join(lStudioFolder, "..\\Resources\\Web\\orpa\\styleset\\bg3.jpg")) + if self.path == '/orpa/resources/Web/orpa/styleset/bg4.jpg': self.SendResponseContentTypeFile('image/png', os.path.join(lStudioFolder, "..\\Resources\\Web\\orpa\\styleset\\bg4.jpg")) + if self.path == '/orpa/resources/Web/orpa/styleset/bg5.jpg': self.SendResponseContentTypeFile('image/png', os.path.join(lStudioFolder, "..\\Resources\\Web\\orpa\\styleset\\bg5.jpg")) + if self.path == '/orpa/resources/Web/orpa/styleset/bg6.jpg': self.SendResponseContentTypeFile('image/png', os.path.join(lStudioFolder, "..\\Resources\\Web\\orpa\\styleset\\bg6.jpg")) + if self.path == '/orpa/resources/Web/orpa/styleset/bg7.jpg': self.SendResponseContentTypeFile('image/png', os.path.join(lStudioFolder, "..\\Resources\\Web\\orpa\\styleset\\bg7.jpg")) + if self.path == '/orpa/resources/Web/orpa/styleset/bg8.jpg': self.SendResponseContentTypeFile('image/png', os.path.join(lStudioFolder, "..\\Resources\\Web\\orpa\\styleset\\bg8.jpg")) + if self.path == '/orpa/resources/Web/orpa/styleset/bg9.jpg': self.SendResponseContentTypeFile('image/png', os.path.join(lStudioFolder, "..\\Resources\\Web\\orpa\\styleset\\bg9.jpg")) + if self.path == '/orpa/resources/Web/orpa/styleset/bg10.jpg': self.SendResponseContentTypeFile('image/png', os.path.join(lStudioFolder, "..\\Resources\\Web\\orpa\\styleset\\bg10.jpg")) + if self.path == '/orpa/resources/Web/Semantic-UI-CSS-master/components/site.css': self.SendResponseContentTypeFile('text/css', os.path.join(lStudioFolder, "..\\Resources\\Web\\Semantic-UI-CSS-master\\components\\site.css")) + if self.path == '/orpa/resources/Web/Semantic-UI-CSS-master/components/reset.css': self.SendResponseContentTypeFile('text/css', os.path.join(lStudioFolder, "..\\Resources\\Web\\Semantic-UI-CSS-master\\components\\reset.css")) + if self.path == '/orpa/resources/Web/Semantic-UI-CSS-master/components/container.css': self.SendResponseContentTypeFile('text/css', os.path.join(lStudioFolder, "..\\Resources\\Web\\Semantic-UI-CSS-master\\components\\container.css")) + if self.path == '/orpa/resources/Web/Semantic-UI-CSS-master/components/grid.css': self.SendResponseContentTypeFile('text/css', os.path.join(lStudioFolder, "..\\Resources\\Web\\Semantic-UI-CSS-master\\components\\grid.css")) + if self.path == '/orpa/resources/Web/Semantic-UI-CSS-master/components/header.css': self.SendResponseContentTypeFile('text/css', os.path.join(lStudioFolder, "..\\Resources\\Web\\Semantic-UI-CSS-master\\components\\header.css")) + if self.path == '/orpa/resources/Web/Semantic-UI-CSS-master/components/image.css': self.SendResponseContentTypeFile('text/css', os.path.join(lStudioFolder, "..\\Resources\\Web\\Semantic-UI-CSS-master\\components\\image.css")) + if self.path == '/orpa/resources/Web/Semantic-UI-CSS-master/components/divider.css': self.SendResponseContentTypeFile('text/css', os.path.join(lStudioFolder, "..\\Resources\\Web\\Semantic-UI-CSS-master\\components\\divider.css")) + if self.path == '/orpa/resources/Web/Semantic-UI-CSS-master/components/menu.css': self.SendResponseContentTypeFile('text/css', os.path.join(lStudioFolder, "..\\Resources\\Web\\Semantic-UI-CSS-master\\components\\menu.css")) + if self.path == '/orpa/resources/Web/Semantic-UI-CSS-master/components/dropdown.css': self.SendResponseContentTypeFile('text/css', os.path.join(lStudioFolder, "..\\Resources\\Web\\Semantic-UI-CSS-master\\components\\dropdown.css")) + if self.path == '/orpa/resources/Web/Semantic-UI-CSS-master/components/segment.css': self.SendResponseContentTypeFile('text/css', os.path.join(lStudioFolder, "..\\Resources\\Web\\Semantic-UI-CSS-master\\components\\segment.css")) + if self.path == '/orpa/resources/Web/Semantic-UI-CSS-master/components/button.css': self.SendResponseContentTypeFile('text/css', os.path.join(lStudioFolder, "..\\Resources\\Web\\Semantic-UI-CSS-master\\components\\button.css")) + if self.path == '/orpa/resources/Web/Semantic-UI-CSS-master/components/list.css': self.SendResponseContentTypeFile('text/css', os.path.join(lStudioFolder, "..\\Resources\\Web\\Semantic-UI-CSS-master\\components\\list.css")) + if self.path == '/orpa/resources/Web/Semantic-UI-CSS-master/components/sidebar.css': self.SendResponseContentTypeFile('text/css', os.path.join(lStudioFolder, "..\\Resources\\Web\\Semantic-UI-CSS-master\\components\\sidebar.css")) + if self.path == '/orpa/resources/Web/Semantic-UI-CSS-master/components/icon.css': self.SendResponseContentTypeFile('text/css', os.path.join(lStudioFolder, "..\\Resources\\Web\\Semantic-UI-CSS-master\\components\\icon.css")) + if self.path == '/orpa/resources/Web/Semantic-UI-CSS-master/components/transition.css': self.SendResponseContentTypeFile('text/css', os.path.join(lStudioFolder, "..\\Resources\\Web\\Semantic-UI-CSS-master\\components\\transition.css")) + if self.path == '/orpa/resources/Web/orpa/styleset/sidebar.js': self.SendResponseContentTypeFile('application/javascript', os.path.join(lStudioFolder, "..\\Resources\\Web\\orpa\\styleset\\sidebar.js")) + if self.path == '/orpa/resources/Web/orpa/styleset/transition.js': self.SendResponseContentTypeFile('application/javascript', os.path.join(lStudioFolder, "..\\Resources\\Web\\orpa\\styleset\\transition.js")) + if self.path == '/orpa/resources/Web/orpa/styleset/docs.js': self.SendResponseContentTypeFile('application/javascript', os.path.join(lStudioFolder, "..\\Resources\\Web\\orpa\\styleset\\docs.js")) + if self.path == '/orpa/resources/Web/orpa/styleset/visibility.js': self.SendResponseContentTypeFile('application/javascript', os.path.join(lStudioFolder, "..\\Resources\\Web\\orpa\\styleset\\visibility.js")) + if self.path == '/orpa/resources/Web/orpa/styleset/highlight.min.js': self.SendResponseContentTypeFile('application/javascript', os.path.join(lStudioFolder, "..\\Resources\\Web\\orpa\\styleset\\highlight.min.js")) + if self.path == '/orpa/resources/Web/orpa/styleset/less.min.js': self.SendResponseContentTypeFile('application/javascript', os.path.join(lStudioFolder, "..\\Resources\\Web\\orpa\\styleset\\less.min.js")) + if self.path == '/orpa/resources/Web/orpa/styleset/easing.min.js': self.SendResponseContentTypeFile('application/javascript', os.path.join(lStudioFolder, "..\\Resources\\Web\\orpa\\styleset\\easing.min.js")) + if self.path == '/metadata.json': self.SendResponseContentTypeFile('application/json', os.path.join(lStudioFolder, "..\\Resources\\Web\\orpa\\\styleset\\metadata.json")) + if self.path == '/orpa/resources/Web/Semantic-UI-CSS-master/themes/default/assets/fonts/icons.woff2': self.SendResponseContentTypeFile('font/woff2', os.path.join(lStudioFolder, "..\\Resources\\Web\\Semantic-UI-CSS-master\\themes\\default\\assets\\fonts\\icons.woff2")) + if self.path == '/orpa/resources/Web/Semantic-UI-CSS-master/themes/default/assets/fonts/icons.woff': self.SendResponseContentTypeFile('font/woff', os.path.join(lStudioFolder, "..\\Resources\\Web\\Semantic-UI-CSS-master\\themes\\default\\assets\\fonts\\icons.woff")) + if self.path == '/orpa/resources/Web/Semantic-UI-CSS-master/themes/default/assets/fonts/icons.ttf': self.SendResponseContentTypeFile('font/ttf', os.path.join(lStudioFolder, "..\\Resources\\Web\\Semantic-UI-CSS-master\\themes\\default\\assets\\fonts\\icons.ttf")) + if self.path == '/orpa/resources/Web/Semantic-UI-CSS-master/semantic.min.css': self.SendResponseContentTypeFile('text/css', os.path.join(lStudioFolder, "..\\Resources\\Web\\Semantic-UI-CSS-master\\semantic.min.css")) + + + # POST def do_POST(self): #Restart studio diff --git a/Studio/SettingsStudioExample.py b/Studio/config.py old mode 100755 new mode 100644 similarity index 100% rename from Studio/SettingsStudioExample.py rename to Studio/config.py diff --git a/Studio/pyOpenRPA.Studio_x64.cmd b/Studio/pyOpenRPA.Studio_x64.cmd deleted file mode 100755 index 39948a1d..00000000 --- a/Studio/pyOpenRPA.Studio_x64.cmd +++ /dev/null @@ -1,5 +0,0 @@ -chcp 65001 -cd /d "%~dp0\..\Sources" -copy /Y ..\Resources\WPy64-3720\python-3.7.2.amd64\python.exe ..\Resources\WPy64-3720\python-3.7.2.amd64\OpenRPA_Studio.exe -.\..\Resources\WPy64-3720\python-3.7.2.amd64\OpenRPA_Studio.exe -m pyOpenRPA.Studio "..\Studio\SettingsStudioExample.py" -pause >nul \ No newline at end of file diff --git a/Studio/start.cmd b/Studio/start.cmd new file mode 100644 index 00000000..c53e695a --- /dev/null +++ b/Studio/start.cmd @@ -0,0 +1,5 @@ +chcp 65001 +cd /d "%~dp0\..\Sources" +copy /Y ..\Resources\WPy64-3720\python-3.7.2.amd64\python.exe ..\Resources\WPy64-3720\python-3.7.2.amd64\orpa_std.exe +.\..\Resources\WPy64-3720\python-3.7.2.amd64\orpa_std.exe -m pyOpenRPA.Studio "..\Studio\config.py" +pause >nul \ No newline at end of file diff --git a/Utils/Jupyter-notebooks/start.cmd b/Utils/Jupyter-notebooks/start.cmd index 3c5665a3..ea6c7445 100755 --- a/Utils/Jupyter-notebooks/start.cmd +++ b/Utils/Jupyter-notebooks/start.cmd @@ -1,3 +1,4 @@ -cd %~dp0..\..\Resources\WPy64-3720\python-3.7.2.amd64 +chcp 65001 +cd /d "%~dp0..\..\Resources\WPy64-3720\python-3.7.2.amd64" copy /Y python.exe jupyter-notebook.exe -jupyter-notebook.exe -m notebook --notebook-dir=%~dp0 \ No newline at end of file +jupyter-notebook.exe -m notebook --notebook-dir="%~dp0" \ No newline at end of file diff --git a/changelog.md b/changelog.md index 7de2bbd9..badba5f4 100755 --- a/changelog.md +++ b/changelog.md @@ -4,14 +4,24 @@ STD - STUDIO RBT - ROBOT AGT - AGENT +[1.3.1] +- ОРКЕСТРАТОР +- минорные правки в дизайн +- СТУДИЯ +- - UI переведен на русский язык +- - обновлен дизайн по аналогии с порталом и Оркестратором +- - новое наименование процесса "orpa-std.exe" +- ОБЩЕЕ +- - Jupyter: запуск из других дисков, отличных от C:// [1.3.0] -- ПОРТИРОВАНО НА LINUX (Ubuntu, Debian, Astra), адаптация всех функций +- ПОРТИРОВАНО НА LINUX (Ubuntu, Debian, Astra), адаптация функций - ОРКЕСТРАТОР - - Manager.ControlPanel: Поддерживает установку пути по формата Linux и Windows -- Обновление дизайна в соответствии с порталом (шапка + подвал) +- - Обновление дизайна в соответствии с порталом (шапка + подвал) +- - новое наименование процесса "orpa-orc.exe" - СТУДИЯ -- Обновление дизайна в соответствии с порталом (шапка + подвал) +- - Обновление дизайна в соответствии с порталом (шапка + подвал) - ДОПОЛНИТЕЛЬНО - - Jinja2: Создание класса быстрой инициализации pyopenRPA.Tools.Template - - Клавиша Alt фиксирует координаты мыши при поиске объекта, что позволяет поработать с определением объекта не при наведенной мыши