mirror of
https://github.com/cwinfo/powerdns-admin.git
synced 2024-11-08 14:40:27 +00:00
Working on dashboard zone list action controls and styling.
This commit is contained in:
parent
4a5db674f4
commit
1cd5ce9ccc
@ -4,9 +4,15 @@
|
||||
|
||||
{% macro dnssec(domain) %}
|
||||
{% if domain.dnssec %}
|
||||
<td><span style="cursor:pointer" class="badge badge-success button_dnssec" id="{{ domain.name }}"><i class="fa-solid fa-lock"></i> Enabled</span></td>
|
||||
<td>
|
||||
<button class="btn badge btn-success button_dnssec" title="Edit DNSSEC" id="{{ domain.name }}"><i
|
||||
class="fa-solid fa-lock"></i></button>
|
||||
</td>
|
||||
{% else %}
|
||||
<td><span style="cursor:pointer" class="badge badge-danger button_dnssec" id="{{ domain.name }}"><i class="fa-solid fa-lock-open"></i> Disabled</span></td>
|
||||
<td>
|
||||
<button class="btn badge btn-danger button_dnssec" title="Enable DNSSEC" id="{{ domain.name }}"><i
|
||||
class="fa-solid fa-lock-open"></i></button>
|
||||
</td>
|
||||
{% endif %}
|
||||
{% endmacro %}
|
||||
|
||||
@ -19,7 +25,7 @@
|
||||
{% endmacro %}
|
||||
|
||||
{% macro master(domain) %}
|
||||
{% if domain.master == '[]'%}N/A{% else %}{{ domain.master | display_master_name }}{% endif %}
|
||||
{% if domain.master == '[]' %}N/A{% else %}{{ domain.master | display_master_name }}{% endif %}
|
||||
{% endmacro %}
|
||||
|
||||
{% macro account(domain) %}
|
||||
@ -29,51 +35,43 @@
|
||||
{% endmacro %}
|
||||
|
||||
{% macro actions(domain) %}
|
||||
<td width="6%">
|
||||
<td>
|
||||
<div class="dropdown">
|
||||
<button class="btn btn-primary dropdown-toggle" type="button" id="dropdownMenu" data-toggle="dropdown" aria-haspopup="true" aria-expanded="false">
|
||||
<button class="btn btn-primary dropdown-toggle" type="button" id="dropdownMenu" data-toggle="dropdown"
|
||||
aria-haspopup="true" aria-expanded="false">
|
||||
<i class="fa-solid fa-bars"></i>
|
||||
</button>
|
||||
<div class="dropdown-menu" aria-labelledby="dropdownMenu">
|
||||
<button class="dropdown-item btn-success" type="button"
|
||||
onclick="window.location.href='{{ url_for('domain.domain', domain_name=domain.name) }}'">
|
||||
<i class="fa-solid fa-pencil"></i> Edit Records
|
||||
</button>
|
||||
|
||||
{% if current_user.role.name in ['Administrator', 'Operator'] %}
|
||||
<button class="dropdown-item btn-danger" type="button"
|
||||
onclick="window.location.href='{{ url_for('domain.setting', domain_name=domain.name) }}'">
|
||||
<i class="fa-solid fa-cog"></i> Zone Settings
|
||||
</button>
|
||||
<button class="dropdown-item btn-success button_template" id="{{ domain.name }}" type="button">
|
||||
<i class="fa-solid fa-clone"></i> Clone to Template
|
||||
<i class="fa-solid fa-clone"></i> Create Template
|
||||
</button>
|
||||
<button class="dropdown-item btn-success" type="button" onclick="window.location.href='{{ url_for('domain.domain', domain_name=domain.name) }}'">
|
||||
<i class="fa-solid fa-cog"></i> Manage Domain
|
||||
</button>
|
||||
<button class="dropdown-item btn-danger" type="button" onclick="window.location.href='{{ url_for('domain.setting', domain_name=domain.name) }}'">
|
||||
<i class="fa-solid fa-cog"></i> Admin Settings
|
||||
</button>
|
||||
<button class="dropdown-item btn-primary" type="button" onclick="window.location.href='{{ url_for('domain.changelog', domain_name=domain.name) }}'">
|
||||
<i class="fa-solid fa-history" aria-hidden="true"></i> Domain Changelog
|
||||
{% endif %}
|
||||
|
||||
{% if current_user.role.name in ['Administrator', 'Operator'] or allow_user_view_history %}
|
||||
<button class="dropdown-item btn-primary" type="button"
|
||||
onclick="window.location.href='{{ url_for('domain.changelog', domain_name=domain.name) }}'">
|
||||
<i class="fa-solid fa-history" aria-hidden="true"></i> Zone Changelog
|
||||
</button>
|
||||
{% endif %}
|
||||
|
||||
{% if current_user.role.name in ['Administrator', 'Operator'] or allow_user_remove_domain %}
|
||||
<div class="dropdown-divider"></div>
|
||||
<button type="button"class="dropdown-item btn-secondary button_delete" onclick="window.location.href='{{ url_for('domain.remove') }}'">
|
||||
<font color="red">
|
||||
<i class="fa-solid fa-trash"></i> Remove Domain
|
||||
</font>
|
||||
<button type="button" class="dropdown-item btn-secondary button_delete"
|
||||
onclick="window.location.href='{{ url_for('domain.remove') }}'">
|
||||
<span style="color: red;"><i class="fa-solid fa-trash"></i> Remove Zone</span>
|
||||
</button>
|
||||
</div>
|
||||
{% else %}
|
||||
<button class="dropdown-item btn-success" type="button" onclick="window.location.href='{{ url_for('domain.domain', domain_name=domain.name) }}'">
|
||||
<i class="fa-solid fa-cog"></i> Manage Domain
|
||||
</button>
|
||||
{% if allow_user_view_history %}
|
||||
<button class="dropdown-item btn-primary" type="button" onclick="window.location.href='{{ url_for('domain.changelog', domain_name=domain.name) }}'">
|
||||
<i class="fa-solid fa-history" aria-hidden="true"></i> Domain Changelog
|
||||
</button>
|
||||
{% endif %}
|
||||
{% if allow_user_remove_domain %}
|
||||
<div class="dropdown-divider"></div>
|
||||
<button type="button"class="dropdown-item btn-secondary button_delete" onclick="window.location.href='{{ url_for('domain.remove') }}'">
|
||||
<font color="red">
|
||||
<i class="fa-solid fa-trash"></i> Remove Domain
|
||||
</font>
|
||||
</button>
|
||||
{% endif %}
|
||||
{% endif %}
|
||||
</div>
|
||||
</div>
|
||||
</td>
|
||||
</td>
|
||||
{% endmacro %}
|
||||
|
Loading…
Reference in New Issue
Block a user