Skip to content

Commit

Permalink
fix: renderEditForm() should display errors
Browse files Browse the repository at this point in the history
  • Loading branch information
phorward committed Sep 6, 2024
1 parent f83b704 commit a20c85c
Show file tree
Hide file tree
Showing 2 changed files with 6 additions and 1 deletion.
2 changes: 1 addition & 1 deletion deploy/html/editform/editform_bone_bone.html
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
<input
class="switch-input ignt-input--boolean ignt-input--{{ boneName }}
class="ignt-input ignt-input--{{ boneName }}
{{ "is-required" if boneParams.required }}
{{ "is-readonly" if boneParams.readOnly }}
{{ "is-invalid" if boneErrors else "is-valid" }}"
Expand Down
5 changes: 5 additions & 0 deletions deploy/html/editform/editform_row.html
Original file line number Diff line number Diff line change
Expand Up @@ -11,6 +11,11 @@
</label>

{{ editWidget }}

{% if boneErrors %}
<span>{{ boneErrors[0].errorMessage if boneErrors and (boneErrors[0].severity.value == 3 or boneParams.required) }}</span>
{% endif %}

</div>
{% else %}
{{ editWidget }}
Expand Down

0 comments on commit a20c85c

Please sign in to comment.