Skip to content

Commit

Permalink
resorting to setting the step to validate in the form
Browse files Browse the repository at this point in the history
  • Loading branch information
ColinW520 committed Feb 6, 2019
1 parent 439ba2e commit c4791f0
Show file tree
Hide file tree
Showing 2 changed files with 2 additions and 1 deletion.
1 change: 1 addition & 0 deletions app/views/registrations/_form.html.haml
Original file line number Diff line number Diff line change
@@ -1,6 +1,7 @@
-# frozen_string_literal: true
= simple_form_for([@event, @registration], validate: true) do |f|
= f.input :started_at, as: :hidden, input_html: { value: @registration.started_at }
= f.input :step_to_validate, as: :hidden, input_html: { value: "start" }
= f.error_notification
- if f.object.errors[:base].present?
= f.error_notification message: f.object.errors[:base].to_sentence
Expand Down
2 changes: 1 addition & 1 deletion app/views/shared/sections/_events_grid.html.haml
Original file line number Diff line number Diff line change
Expand Up @@ -7,4 +7,4 @@
%p.mt-3 Register today before we fill up!
- @events.each do |event|
.col-md-4.mb-4
= render "events/card", event: event.decorate, context_classes: ""
= render "events/card", event: event.decorate, context_classes: "", show_footer: false

0 comments on commit c4791f0

Please sign in to comment.