diff options
author | Vasilii Chernov <vchernov@inr.ru> | 2016-03-03 15:38:32 +0100 |
---|---|---|
committer | Vasilii Chernov <vchernov@inr.ru> | 2016-03-03 15:38:32 +0100 |
commit | c79d43273769d88f7129a3d53c80b85a6dc1946c (patch) | |
tree | 0b8071b6261d74ef8bdf50a029525546250369ed /pyserver/html_server.py | |
parent | ee16e47966afe180d3c32e2b1d93301052894fac (diff) | |
download | pcitool-c79d43273769d88f7129a3d53c80b85a6dc1946c.tar.gz pcitool-c79d43273769d88f7129a3d53c80b85a6dc1946c.tar.bz2 pcitool-c79d43273769d88f7129a3d53c80b85a6dc1946c.tar.xz pcitool-c79d43273769d88f7129a3d53c80b85a6dc1946c.zip |
1. Pcipywrap: add persistent locking wrappings
2. html-server:
- add scripts tab
- change tab view to jQuery tabs
Diffstat (limited to 'pyserver/html_server.py')
-rw-r--r-- | pyserver/html_server.py | 24 |
1 files changed, 22 insertions, 2 deletions
diff --git a/pyserver/html_server.py b/pyserver/html_server.py index 22194cd..571dc4e 100644 --- a/pyserver/html_server.py +++ b/pyserver/html_server.py @@ -160,8 +160,28 @@ def get_property_list(): return render_template('property_info.html', value = value, branch = branch, - properties = prop_info, - json = json + properties = prop_info + ) + +@app.route("/scripts_info") +def get_scripts_list(): + #get properties info + prop_info = 0 + try: + r = requests.get(url_for('process_json_command', + command = 'get_scripts_list', + _external = True)) + + if(r.json().get('status') == 'error'): + return 'Error: ' + r.json()['description'] + + scripts_info = r.json()['scripts'] + + except Exception as e: + return str(e) + + return render_template('scripts_info.html', + scripts = scripts_info ) @app.route("/") |