{% import 'OroUIBundle::macros.html.twig' as UI %}

{% set exportConfigurableWidgetViewOptions = {
    view: {
        view: 'oroimportexport/js/app/views/export-configurable-widget-view',
        wid: app.request.get('_wid'),
        errorMessage: 'Errors occured during file export.'|trans
    }
} %}

<div class="widget-content import-widget-content">
    <div class="form-container" {{ UI.renderPageComponentAttributes(exportConfigurableWidgetViewOptions) }}>
        {{ form_start(form, {
            'action': path('oro_importexport_export_config', {entity: entityName, options: options, exportJob: exportJob}),
            'attr': {
                'id': form.vars.id,
                'data-nohash': 'true',
                'class': 'form-horizontal'
            }
        }) }}

            <fieldset class="form">
                <div>
                    {{ form_row(form.processorAlias) }}
                </div>
                {{ form_rest(form) }}
            </fieldset>

            <div class="widget-actions">
                <button class="btn" type="reset">{{ 'Cancel'|trans }}</button>
                <button class="btn btn-primary" type="submit">
                    {{ 'Export'|trans }}
                </button>
            </div>
        {{ form_end(form) }}
        {{ oro_form_js_validation(form) }}
    </div>
</div>
