0
0
Fork 0
mirror of https://github.com/kevinpapst/kimai2.git synced 2025-01-25 17:38:31 +00:00
kevinpapst_kimai2/templates/default/_form_modal.html.twig
2024-12-22 22:50:42 +01:00

43 lines
2.4 KiB
Twig

<div class="modal {% block modal_class %}{% endblock %}" id="{% block modal_id %}form_modal{% endblock %}" tabindex="-1" role="dialog" aria-labelledby="{{ block('modal_id') }}_label">
<div class="modal-dialog {% block modal_size %}modal-lg{% endblock %}" role="document">
<div class="modal-content">
{% block form_before %}{% endblock %}
{% block modal_before %}{{ form_start(form, formStartOptions|default({})) }}{% endblock %}
<div class="modal-header">
<h5 class="modal-title" id="{{ block('modal_id') }}_label">
{% block modal_title %}
{{ title }}
{% if form.vars.docu_chapter is defined and form.vars.docu_chapter is not empty %}
<a class="form-help" href="{{ form.vars.docu_chapter|docu_link }}" target="_blank">?</a>
{% endif %}
{% endblock %}
</h5>
<button type="button" class="btn-close" data-bs-dismiss="modal" aria-label="{{ 'action.close'|trans }}"></button>
</div>
<div class="modal-body">
{% block modal_body %}
{% block form_body_outer %}
{% block form_body_pre %}
{{ form_errors(form) }}
{% endblock %}
{% block form_body %}
{{ form_rest(form) }}
{% endblock %}
{% block form_body_post %}
{% endblock %}
{% endblock %}
{% endblock %}
</div>
<div class="modal-footer">
{% block modal_footer %}
{% block submit_button %}
<button type="submit" class="btn btn-primary pull-left modal-form-save" data-loading-text="{{ (submit_button|default('action.save'))|trans }}…" id="{{ block('modal_id') }}_save" data-hotkey="ctrl+Enter">{{ (submit_button|default('action.save'))|trans }}</button>
{% endblock %}
<button type="button" class="btn btn-cancel" data-bs-dismiss="modal">{{ 'action.close'|trans }}</button>
{% endblock %}
</div>
{% block modal_end %}{{ form_end(form) }}{% endblock %}
{% block form_after %}{% endblock %}
</div>
</div>
</div>