mirror of https://git.48k.eu/ogcp
56 lines
2.2 KiB
HTML
56 lines
2.2 KiB
HTML
{% extends 'base.html' %}
|
|
|
|
{% macro print_scopes_tree(scopes) -%}
|
|
|
|
<ul class="list-group">
|
|
{% for scope in scopes %}
|
|
<li class="list-group-item">
|
|
<input class="form-check-input" type="checkbox"
|
|
value="{{ " ".join(scope["ip"]) }}"
|
|
name="{{ scope["name"] }}_{{ scope["id"] }}">
|
|
{{ scope["name"] }}
|
|
{% if "state" in scope %}
|
|
-- STATE: {{ scope["state"] }}
|
|
{% endif %}
|
|
{{ print_scopes_tree(scope["scope"]) }}
|
|
</li>
|
|
{% endfor %}
|
|
</ul>
|
|
|
|
{% endmacro %}
|
|
|
|
{% block content %}
|
|
|
|
<form>
|
|
<input type="hidden" name="csrf_token" value="{{ csrf_token() }}"/>
|
|
{{ print_scopes_tree(scopes["scope"]) }}
|
|
|
|
<div class="dropdown">
|
|
<button class="btn btn-primary dropdown-toggle" type="button"
|
|
id="dropdownMenuButton" data-toggle="dropdown" aria-haspopup="true"
|
|
aria-expanded="false">
|
|
{{ _('Actions') }}
|
|
</button>
|
|
<div class="dropdown-menu" aria-labelledby="dropdownMenuButton">
|
|
<input class="dropdown-item" type="submit" value="{{ _('Run') }}"
|
|
formaction="{{ url_for('action_wol') }}" formmethod="get">
|
|
<input class="dropdown-item" type="submit" value="{{ _('Poweroff') }}"
|
|
formaction="{{ url_for('action_poweroff') }}" formmethod="post">
|
|
<input class="dropdown-item" type="submit" value="{{ _('Reboot') }}"
|
|
formaction="{{ url_for('action_reboot') }}" formmethod="post">
|
|
<input class="dropdown-item" type="submit" value="{{ _('Refresh') }}"
|
|
formaction="{{ url_for('action_refresh') }}" formmethod="post">
|
|
<input class="dropdown-item" type="submit" value="{{ _('Hardware') }}"
|
|
formaction="{{ url_for('action_hardware') }}" formmethod="get">
|
|
<input class="dropdown-item" type="submit" value="{{ _('Setup') }}"
|
|
formaction="{{ url_for('action_setup_show') }}" formmethod="get">
|
|
<input class="dropdown-item" type="submit" value="{{ _('Details') }}"
|
|
formaction="{{ url_for('action_client_info') }}" formmethod="get">
|
|
<input class="dropdown-item" type="submit" value="{{ _('Add client') }}"
|
|
formaction="{{ url_for('action_client_add') }}" formmethod="get">
|
|
</div>
|
|
</div>
|
|
</form>
|
|
|
|
{% endblock %}
|