myaac/system/templates/install.admin.html.twig

33 lines
1.0 KiB
Twig

{% if errors is not empty %}
<div class="alert alert-danger">
{% for error in errors %}
<span>{{ error }}</span>
{% endfor %}
</div>
{% endif %}
<form action="{{ constant('BASE_URL') }}install/" method="post" autocomplete="off">
<input type="hidden" name="step" id="step" value="finish" />
{% set values = ['email', account, 'password', 'password_confirm'] %}
{% if hasTablePlayers %}
{% set values = values|merge(['player_name']) %}
{% endif %}
{% for value in values %}
<div class="form-group mb-2">
<label for="vars_{{ value }}">{{ locale['step_admin_' ~ value] }}</label>
<input class="form-control" type="{% if value in ['password', 'password_confirm'] %}password{% else %}text{% endif %}" name="vars[{{ value }}]" id="vars_{{ value }}"{% if session['var_' ~ value] is not null %} value="{{ session['var_' ~ value] }}"{% endif %}/>
<small class="form-text text-muted">{{ locale['step_admin_' ~ value ~ '_desc']|raw }}</small>
</div>
{% endfor %}
<div class="text-center m-3">
{{ buttons|raw }}
</div>
</form>