Improve uploader button

This commit is contained in:
Taylor Helsper 2019-07-26 21:13:40 -05:00
parent f4821fabbc
commit 44abb69eea
3 changed files with 36 additions and 5 deletions

View File

@ -90,15 +90,19 @@ def index():
# Show uploader page if we are marked as an uploader
if is_uploader():
status = subprocess.check_output(["mynode-get-quicksync-status"])
settings_button="<a class='ui-button ui-widget ui-corner-all mynode_button' href='/settings'>Settings</a>"
status = Markup("<center>"+settings_button+"</center><div style='text-align: left; font-size: 12px; width: 800px;'><pre>"+status+"</pre></div>")
status=""
try:
status = subprocess.check_output(["mynode-get-quicksync-status"])
except:
status = "Waiting on quicksync to start..."
status = Markup("<div style='text-align: left; font-size: 12px; width: 800px;'><pre>"+status+"</pre></div>")
templateData = {
"title": "myNode Uploader",
"header_text": "Uploader Device",
"subheader_text": status
"quicksync_status": status
}
return render_template('state.html', **templateData)
return render_template('uploader.html', **templateData)
# Show product key page if key not set
if not has_product_key() and not skipped_product_key():

View File

@ -3,9 +3,11 @@
<title>{{ title }}</title>
<link rel="shortcut icon" href="{{ url_for('static', filename='images/favicon.ico') }}">
<link rel="stylesheet" href="{{ url_for('static', filename="css/mynode.css")}}">
<link href="{{ url_for('static', filename="jquery_ui/jquery-ui.css")}}" rel="stylesheet">
<meta http-equiv="Content-Language" content="en">
<meta name="google" content="notranslate">
<script src="{{ url_for('static', filename="js/jquery-3.3.1.min.js")}}"></script>
<script src="{{ url_for('static', filename="jquery_ui/jquery-ui.js")}}"></script>
<script src="{{ url_for('static', filename="js/mynode.js")}}"></script>
<meta http-equiv="refresh" content="30">
</head>

View File

@ -0,0 +1,25 @@
<!DOCTYPE html lang="en">
<head>
<title>{{ title }}</title>
<link rel="shortcut icon" href="{{ url_for('static', filename='images/favicon.ico') }}">
<link rel="stylesheet" href="{{ url_for('static', filename="css/mynode.css")}}">
<link href="{{ url_for('static', filename="jquery_ui/jquery-ui.css")}}" rel="stylesheet">
<meta http-equiv="Content-Language" content="en">
<meta name="google" content="notranslate">
<script src="{{ url_for('static', filename="js/jquery-3.3.1.min.js")}}"></script>
<script src="{{ url_for('static', filename="jquery_ui/jquery-ui.js")}}"></script>
<script src="{{ url_for('static', filename="js/mynode.js")}}"></script>
<meta http-equiv="refresh" content="30">
</head>
<body>
<div class="logo_header"><a href="/"><img class="logo_image" src="{{ url_for('static', filename="images/logo.png")}}"/></a></div>
<div class="state_header">{{ header_text }}</div>
<div style="width: 150px; margin: auto;"><a class='ui-button ui-widget ui-corner-all mynode_button' href='/settings'>Settings</a></div>
<br/>
<div class="state_subheader">{{ quicksync_status }}</div>
</body>
</html>