merge current enhancements from main branch to v2.2 (#1261)
This commit is contained in:
@@ -22,6 +22,14 @@
|
||||
<input class="form-control" type="text" name="2fa_code" id="2fa_code" value="" autocomplete="off" autofocus required/>
|
||||
</div>
|
||||
|
||||
<div class="mb-3">
|
||||
<div class="form-check form-switch">
|
||||
<input type="hidden" name="2fa_remember" value="0"/>
|
||||
<input class="form-check-input" type="checkbox" id="2fa_remember" name="2fa_remember" value="1">
|
||||
<label class="form-check-label" for="2fa_remember">{{ lng('login.2faremember') }}</label>
|
||||
</div>
|
||||
</div>
|
||||
|
||||
</div>
|
||||
|
||||
<div class="card-body d-grid gap-2">
|
||||
|
||||
@@ -29,6 +29,16 @@
|
||||
{% endif %}
|
||||
{% endmacro %}
|
||||
|
||||
{% macro type2fa(data) %}
|
||||
{% if (data == 1) %}
|
||||
<i class="fa-solid fa-envelope text-success"></i>
|
||||
{% elseif (data == 2) %}
|
||||
<i class="fa-solid fa-mobile text-success"></i>
|
||||
{% else %}
|
||||
<i class="fa-solid fa-lock-open text-warning"></i>
|
||||
{% endif %}
|
||||
{% endmacro %}
|
||||
|
||||
{% macro link(data) %}
|
||||
{% apply spaceless %}
|
||||
<a href="{{ data.href }}" {% if data.class is defined %} class="{{ data.class }}" {% endif %} {% if data.target is defined %} target="{{ data.target }}" {% endif %} {% if data.title is defined %} title="{{ data.title }}" {% endif %}>
|
||||
|
||||
@@ -47,6 +47,8 @@
|
||||
{{ macros.domainWithSan(td.data.data) }}
|
||||
{% elseif td.data.macro == 'actions' %}
|
||||
{{ macros.actions(td.data.data) }}
|
||||
{% elseif td.data.macro == 'type2fa' %}
|
||||
{{ macros.type2fa(td.data.data) }}
|
||||
{% else %}
|
||||
Table macro '{{ td.data.macro|json_encode }}' is not implemented!
|
||||
Unable to handle this data: {{ td.data|json_encode }}
|
||||
|
||||
Reference in New Issue
Block a user