{# def form #}
{# Modal dialog - Support Request #}
{# Use a typeahead component to let the user select a corresponding resources. #}
<form method="post" action="{{ url_for('dashboard', 'request-support') }}">
  <Modal id="modal-request-support" title={{ _("Ask for help") }} submit={{ _("Send request") }}>
  <p>{% trans %}Fill out the form below to submit your support request.{% endtrans %}</p>
  <div class="mb-2 form-field ">
    <Typeahead id="request-support-resource" name="search" source={{ form.get_sources() }} display={{ ["name"] }} placeholder={{ _("Search & select resource…") }} search_on_focus={{ True }} min_length={{ 0 }} must_select_item={{ True }} submit_button={{ False }} max_item={{ 1000 }} max_item_per_group={{ 1000 }} group={{ True }} data-name-target="#request-support-resource-name" data-service-target="#request-support-resource-service" />
  </div>
  <Field id="request-support-resource-name" field={{ form.resource }} floating={{ True }} placeholder="." />
  <Field id="request-support-resource-service" field={{ form.resource_service }} floating={{ True }} placeholder="." />
  <Field field={{ form.message }} />
  <p>{% trans %}Once submitted, a ticket will be created in the ticketing system.{% endtrans %}</p>
  </Modal>
</form>
