Files
dunlop-ember/spec/dummy/app/views/comments/_form.html.slim
T
2017-12-21 11:36:52 +01:00

19 lines
468 B
Plaintext

= form_for @comment do |f|
- if @comment.errors.any?
#error_explanation
h2 = "#{pluralize(@comment.errors.count, "error")} prohibited this comment from being saved:"
ul
- @comment.errors.full_messages.each do |message|
li = message
.field
= f.label :user_id
= f.number_field :user_id
.field
= f.label :post_id
= f.number_field :post_id
.field
= f.label :body
= f.text_area :body
.actions = f.submit