Skip to content

Commit

Permalink
allow passing name and/or id to form in form macro
Browse files Browse the repository at this point in the history
refs #177
  • Loading branch information
guruofgentoo committed Dec 5, 2022
1 parent 90e2d88 commit fe1ac26
Showing 1 changed file with 5 additions and 1 deletion.
6 changes: 5 additions & 1 deletion keg_elements/templates/keg_elements/forms/horizontal_b4.html
Expand Up @@ -276,13 +276,17 @@
cancel_url='',
form_upload=false,
dirty_check=false,
start_tab_index=1
start_tab_index=1,
form_id=None,
form_name=None
) -%}

<form method="POST"
action="{{ action_url }}"
role="form"
class="{{ class_ }} {{ 'was-validated needs-validation' if form.errors else 'needs-validation' }}"
{% if form_id %}id="{{ form_id }}"{% endif %}
{% if form_name %}name="{{ form_name }}"{% endif %}
{% if form_upload %}enctype="multipart/form-data"{% endif %}
{% if dirty_check %}data-dirty-check="on"{% endif %}
novalidate
Expand Down

0 comments on commit fe1ac26

Please sign in to comment.