From dce6ef0c19bff37bb412133feb4eedfb3d08dd2d Mon Sep 17 00:00:00 2001 From: Ivan Maslov Date: Sun, 1 Dec 2019 10:19:53 +0300 Subject: [PATCH] - Orchestrator.Client: Minor fix in rendering table of the modal window --- Sources/pyOpenRPA/Orchestrator/Server.py | 58 +++++++++++------- .../pyOpenRPA/Orchestrator/Web/Index.xhtml | 3 + .../pyOpenRPA/Orchestrator/Web/favicon.ico | Bin 5430 -> 5430 bytes 3 files changed, 39 insertions(+), 22 deletions(-) diff --git a/Sources/pyOpenRPA/Orchestrator/Server.py b/Sources/pyOpenRPA/Orchestrator/Server.py index a133913b..0b490fb4 100644 --- a/Sources/pyOpenRPA/Orchestrator/Server.py +++ b/Sources/pyOpenRPA/Orchestrator/Server.py @@ -1,4 +1,6 @@ from http.server import BaseHTTPRequestHandler, HTTPServer +from socketserver import ThreadingMixIn +import threading import json from threading import Thread from . import Processor @@ -11,27 +13,6 @@ import os #for path operations from http import cookies global mGlobalDict from . import ServerSettings -#inGlobalDict -# "JSONConfigurationDict": -class RobotDaemonServer(Thread): - def __init__(self,name,inGlobalDict): - Thread.__init__(self) - self.name = name - # Update the global dict - ServerSettings.SettingsUpdate(mGlobalDict) - def run(self): - inServerAddress=""; - inPort = mGlobalDict["Server"]["ListenPort"]; - # Server settings - # Choose port 8080, for port 80, which is normally used for a http server, you need root access - server_address = (inServerAddress, inPort) - httpd = HTTPServer(server_address, testHTTPServer_RequestHandler) - # Logging - mGlobalDict["Logger"].info(f"Server init. Listen URL: {inServerAddress}, Listen port: {inPort}") - # Запуск адреса в браузере - os.system("explorer http://127.0.0.1:8081") - httpd.serve_forever() - #Authenticate function () # return dict # { @@ -416,4 +397,37 @@ class testHTTPServer_RequestHandler(BaseHTTPRequestHandler): self.send_response(403) # Send headers self.end_headers() - return \ No newline at end of file + return + #Logging + #!Turn it on to stop print in console + #def log_message(self, format, *args): + # return +class ThreadedHTTPServer(ThreadingMixIn, HTTPServer): + """Handle requests in a separate thread.""" + def finish_request(self, request, client_address): + request.settimeout(30) + # "super" can not be used because BaseServer is not created from object + HTTPServer.finish_request(self, request, client_address) +#inGlobalDict +# "JSONConfigurationDict": +class RobotDaemonServer(Thread): + def __init__(self,name,inGlobalDict): + Thread.__init__(self) + self.name = name + # Update the global dict + ServerSettings.SettingsUpdate(mGlobalDict) + def run(self): + inServerAddress=""; + inPort = mGlobalDict["Server"]["ListenPort"]; + # Server settings + # Choose port 8080, for port 80, which is normally used for a http server, you need root access + server_address = (inServerAddress, inPort) + #httpd = HTTPServer(server_address, testHTTPServer_RequestHandler) + # Logging + mGlobalDict["Logger"].info(f"Server init. Listen URL: {inServerAddress}, Listen port: {inPort}") + # Запуск адреса в браузере + os.system("explorer http://127.0.0.1:8081") + #httpd.serve_forever() + httpd = ThreadedHTTPServer(server_address, testHTTPServer_RequestHandler) + #print('Starting server, use to stop') + httpd.serve_forever() diff --git a/Sources/pyOpenRPA/Orchestrator/Web/Index.xhtml b/Sources/pyOpenRPA/Orchestrator/Web/Index.xhtml index ea1e2b18..f2efeae6 100644 --- a/Sources/pyOpenRPA/Orchestrator/Web/Index.xhtml +++ b/Sources/pyOpenRPA/Orchestrator/Web/Index.xhtml @@ -443,6 +443,9 @@ ///Установить HTML код $('.ui.modal.basic .content').html(lHTMLCode); $('.ui.modal.basic').modal('show'); + //DO widest modal for table with scroll x + $("div.ui.basic.modal.transition.visible.active.scrolling")[0].style["width"]="1300px" + $("div.ui.basic.modal.transition.visible.active.scrolling")[0].style["overflow"]="scroll" } //Service function mGlobal.Modal.TableFilter.FilterUpdate=function(inFilterValue) { diff --git a/Sources/pyOpenRPA/Orchestrator/Web/favicon.ico b/Sources/pyOpenRPA/Orchestrator/Web/favicon.ico index 27dd469630f8aa57a617634bd564672777cbf8e5..79e3b24aa2799582bd97e2e6b645f0e00bbef35c 100644 GIT binary patch literal 5430 zcmchXv2GJl5JeZn2jml6AwGeE!b+JkO_VN4g+M|P1qwnaR#Jp2KY)@{k!jMbaB+Ye%3V4o2D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