new settins page
This commit is contained in:
parent
5593425c60
commit
a3a8f377f0
|
@ -18,26 +18,22 @@
|
||||||
<div class="card-body">
|
<div class="card-body">
|
||||||
|
|
||||||
<div class="pt-6 pb-2">
|
<div class="pt-6 pb-2">
|
||||||
<h5 class="card-title text-center pb-0 fs-4">Download your settings for Workbench</h5>
|
<h5 class="card-title text-center pb-0 fs-4">Workbench 2022</h5>
|
||||||
<p class="text-center small">Please select one of this options</p>
|
|
||||||
<div class="row pt-3">
|
<div class="row pt-3">
|
||||||
<div class="col-5">
|
<div class="col-5">
|
||||||
<a href="{{ url_for('workbench.settings') }}?opt=register" class="btn btn-primary">Register devices</a>
|
<a href="{{ url_for('workbench.settings') }}?opt=register" class="btn btn-primary">Get settings for register devices</a>
|
||||||
</div>
|
</div>
|
||||||
<div class="col">
|
<div class="col">
|
||||||
<p class="small">Download the settings only for register devices.</p>
|
|
||||||
</div>
|
</div>
|
||||||
</div>
|
</div>
|
||||||
{% if iso %}
|
{% if 2022_iso %}
|
||||||
<div class="row pt-3">
|
<div class="row pt-3">
|
||||||
<div class="col-5">
|
<div class="col-5">
|
||||||
<a href="/static/iso/{{ iso }}" class="btn btn-primary">{{ iso }}</a>
|
<a href="/static/iso/2022/{{ 2022_iso }}" class="btn btn-primary">Get {{ 2022_iso }}</a>
|
||||||
</div>
|
</div>
|
||||||
<div class="col">
|
<div class="col">
|
||||||
<p class="small">Download ISO workbench and burn it one one usb stick.</p>
|
|
||||||
<p class="small">
|
<p class="small">
|
||||||
Download Checksum: <a style="color: #993365;" href="/static/iso/SHA512SUMS">SHA512SUMS</a> |
|
Download Checksum: <a style="color: #993365;" href="/static/iso/2022/SHA512SUMS">SHA512SUMS</a> |
|
||||||
<a style="color: #993365;" href="/static/iso/SHA512SUMS.sign">Signature</a>
|
|
||||||
</p>
|
</p>
|
||||||
</div>
|
</div>
|
||||||
</div>
|
</div>
|
||||||
|
|
|
@ -20,7 +20,7 @@ workbench = Blueprint('workbench', __name__, url_prefix='/workbench')
|
||||||
class SettingsView(GenericMixin):
|
class SettingsView(GenericMixin):
|
||||||
decorators = [login_required]
|
decorators = [login_required]
|
||||||
template_name = 'workbench/settings.html'
|
template_name = 'workbench/settings.html'
|
||||||
page_title = "Workbench Settings"
|
page_title = "Workbench"
|
||||||
|
|
||||||
def dispatch_request(self):
|
def dispatch_request(self):
|
||||||
self.get_context()
|
self.get_context()
|
||||||
|
@ -43,8 +43,8 @@ class SettingsView(GenericMixin):
|
||||||
f for f in os.listdir(f'{path}/static/iso/') if f[-3:].lower() == 'iso'
|
f for f in os.listdir(f'{path}/static/iso/') if f[-3:].lower() == 'iso'
|
||||||
]
|
]
|
||||||
|
|
||||||
self.context['iso'] = ''
|
self.context['2022_iso'] = ''
|
||||||
self.context['iso_sha'] = ''
|
self.context['2022_iso_sha'] = ''
|
||||||
|
|
||||||
if files:
|
if files:
|
||||||
self.context['iso'] = files[0]
|
self.context['iso'] = files[0]
|
||||||
|
@ -89,4 +89,4 @@ class SettingsView(GenericMixin):
|
||||||
return token
|
return token
|
||||||
|
|
||||||
|
|
||||||
workbench.add_url_rule('/settings/', view_func=SettingsView.as_view('settings'))
|
workbench.add_url_rule('/', view_func=SettingsView.as_view('settings'))
|
||||||
|
|
Reference in New Issue