Form uses button instead of input to display SVG

This commit is contained in:
2024-12-23 00:47:44 +01:00
parent 8f85432982
commit a9307ad455
6 changed files with 20 additions and 3 deletions

View File

@@ -20,7 +20,7 @@
</td>
<td class="actions">
<%= form.submit form: form_tag %>
<%= form.button form: form_tag %>
<%= image_link_to t(:cancel), "close-outline", units_path, class: 'dangerous',
name: :cancel, onclick: render_turbo_stream('form_close', {row: row}) %>
</td>

View File

@@ -4,7 +4,7 @@
form_tag: dom_id(@unit, :edit, :form)} %>
<%= turbo_stream.append :unit_form do %>
<%- form_with model: @unit, html: {id: ids[:form_tag]} do %>
<%- tabular_form_with model: @unit, html: {id: ids[:form_tag]} do %>
<% end %>
<% end %>

View File

@@ -7,7 +7,7 @@
<%= turbo_stream.disable ids[:link] -%>
<%= turbo_stream.append :unit_form do %>
<%- form_with model: @unit, html: {id: ids[:form_tag]} do %>
<%- tabular_form_with model: @unit, html: {id: ids[:form_tag]} do %>
<% end %>
<% end %>