scinote-web/app/views/steps/_new.html.erb

17 lines
864 B
Text
Raw Normal View History

2016-02-12 23:52:43 +08:00
<div class="well">
2016-07-21 19:11:15 +08:00
<%= bootstrap_form_for(@step, url: protocol_steps_path(@protocol, format: :json), remote: true, authenticity_token: true, multipart: true, data: { role: "new-step-form", type: :json }) do |f| %>
<h4><%= t("protocols.steps.new.add_step_title") %></h4>
2016-02-12 23:52:43 +08:00
<hr>
<%= render partial: "empty_step.html.erb", locals: {step: @step, f: f} %>
<hr>
<% if direct_upload %>
2016-07-21 19:11:15 +08:00
<%= f.submit t("protocols.steps.new.add_step"), class: 'btn btn-primary', onclick: 'animateSpinner(); startFileUpload(event, this);' %>
2016-02-12 23:52:43 +08:00
<% else %>
2016-07-21 19:11:15 +08:00
<%= f.submit t("protocols.steps.new.add_step"), id: "create-step", class: 'btn btn-primary', onclick: 'animateSpinner(); stepValidator(event);' %>
2016-02-12 23:52:43 +08:00
<% end %>
2016-07-21 19:11:15 +08:00
<button type="button" data-action="cancel-new" class="btn btn-default">
2016-02-12 23:52:43 +08:00
<%= t("general.cancel")%>
</button>
<% end %>
</div>