{# Leave this template at bootstrap 4 for now, as it otherwise destroys our layout #}
{% form_theme form.orderdetails with ['parts/edit/edit_form_styles.html.twig', "bootstrap_5_layout.html.twig"] %}
{% import 'components/collection_type.macro.html.twig' as collection %}

<div {{ collection.controller(form.orderdetails, 'orderdetails.edit.delete.confirm') }}>
    <table class="table table-striped table-sm table-responsive-md" id="orderdetails_table" {{ collection.target() }}>
        <tbody>
        {% for detail in form.orderdetails %}
            {{ form_widget(detail) }}
        {% endfor %}
        </tbody>
    </table>

    <button type="button" class="btn btn-success" {{ collection.create_btn() }}>
        <i class="fas fa-plus-square fa-fw"></i>
        {% trans %}orderdetail.create{% endtrans %}
    </button>
</div>
