summaryrefslogtreecommitdiff
path: root/app/views/projects/variables
diff options
context:
space:
mode:
authorRobert Speicher <rspeicher@gmail.com>2016-04-04 21:25:38 -0400
committerRobert Speicher <rspeicher@gmail.com>2016-04-04 21:37:07 -0400
commit7a2370f74060b2f065e3602700fe1b33fda4685c (patch)
tree0c23a588515e857598d5e389cd55aa816d3cfe35 /app/views/projects/variables
parent2ed6cd9e469ffcdb60f21d1738de1eff8c258432 (diff)
downloadgitlab-ce-7a2370f74060b2f065e3602700fe1b33fda4685c.tar.gz
Standardize the way we check for and display form errorsrs-form_errors
- Some views had a "Close" button. We've removed this, because we don't want users accidentally hiding the validation errors and not knowing what needs to be fixed. - Some views used `li`, some used `p`, some used `span`. We've standardized on `li`. - Some views only showed the first error. We've standardized on showing all of them. - Some views added an `#error_explanation` div, which we've made standard.
Diffstat (limited to 'app/views/projects/variables')
-rw-r--r--app/views/projects/variables/show.html.haml8
1 files changed, 1 insertions, 7 deletions
diff --git a/app/views/projects/variables/show.html.haml b/app/views/projects/variables/show.html.haml
index efe1e6f24c2..ca284b84d39 100644
--- a/app/views/projects/variables/show.html.haml
+++ b/app/views/projects/variables/show.html.haml
@@ -13,13 +13,7 @@
= nested_form_for @project, url: url_for(controller: 'projects/variables', action: 'update'), html: { class: 'form-horizontal' } do |f|
- - if @project.errors.any?
- #error_explanation
- %p.lead= "#{pluralize(@project.errors.count, "error")} prohibited this project from being saved:"
- .alert.alert-error
- %ul
- - @project.errors.full_messages.each do |msg|
- %li= msg
+ = form_errors(@project)
= f.fields_for :variables do |variable_form|
.form-group