bones73k/lib/bones73k_web/live/property_live/form_component.html.leex

22 lines
500 B
Text

<h2><%= @title %></h2>
<%= f = form_for @changeset, "#",
id: "property-form",
phx_target: @myself,
phx_change: "validate",
phx_submit: "save" %>
<%= label f, :name %>
<%= text_input f, :name %>
<%= error_tag f, :name %>
<%= label f, :price %>
<%= number_input f, :price, step: "any" %>
<%= error_tag f, :price %>
<%= label f, :description %>
<%= textarea f, :description %>
<%= error_tag f, :description %>
<%= submit "Save", phx_disable_with: "Saving..." %>
</form>