Sha256: 6a3859c94592ed733834cbc1c8eb8e4fcd6471dcfc96667aabfe7ed1e6ced22f

Contents?: true

Size: 1.14 KB

Versions: 14

Compression:

Stored size: 1.14 KB

Contents

<%= form_with(model: [form, formula], scope: :formula, local: true) do |f| %>
  <% if formula.errors.any? %>
    <article class="message is-danger">
      <div class="message-header">
        <p>
          <%= pluralize(formula.errors.count, "error") %> prohibited this form from being saved:
        </p>
      </div>
      <div class="message-body content">
        <ul>
          <% formula.errors.full_messages.each do |message| %>
            <li><%= message %></li>
          <% end %>
        </ul>
      </div>
    </article>
  <% end %>

  <div class="field">
    <%= f.label :name, class: "label" %>
    <div class="control">
      <%= f.text_field :name, class: "input", placeholder: "Name" %>
    </div>
  </div>

  <div class="field">
    <%= f.label :body, class: "label" %>
    <div class="control">
      <%= f.text_area :body, class: "textarea", placeholder: "# Ruby script here" %>
    </div>
  </div>

  <div class="field is-grouped">
    <div class="control">
      <%= f.submit class: "button is-primary" %>
    </div>
    <div class="control">
      <%= link_to "Back", url_for(:back), class: "button is-link" %>
    </div>
  </div>
<% end %>

Version data entries

14 entries across 14 versions & 1 rubygems

Version Path
script_core-0.3.2 spec/dummy/app/views/forms/formulas/_form.html.erb
script_core-0.3.0 spec/dummy/app/views/forms/formulas/_form.html.erb
script_core-0.2.7 spec/dummy/app/views/forms/formulas/_form.html.erb
script_core-0.2.6 spec/dummy/app/views/forms/formulas/_form.html.erb
script_core-0.2.5 spec/dummy/app/views/forms/formulas/_form.html.erb
script_core-0.2.4 spec/dummy/app/views/forms/formulas/_form.html.erb
script_core-0.2.3 spec/dummy/app/views/forms/formulas/_form.html.erb
script_core-0.2.2 spec/dummy/app/views/forms/formulas/_form.html.erb
script_core-0.2.1 spec/dummy/app/views/forms/formulas/_form.html.erb
script_core-0.2.0 spec/dummy/app/views/forms/formulas/_form.html.erb
script_core-0.1.1 spec/dummy/app/views/forms/formulas/_form.html.erb
script_core-0.1.0 spec/dummy/app/views/forms/formulas/_form.html.erb
script_core-0.0.6 spec/dummy/app/views/forms/formulas/_form.html.erb
script_core-0.0.5 spec/dummy/app/views/forms/formulas/_form.html.erb