From 8185939b2629581dd9264dbbc37f859e19436f31 Mon Sep 17 00:00:00 2001 From: Matthew Lemon Date: Mon, 18 Dec 2023 19:38:44 +0000 Subject: wip: stuck on notnull error... --- app/views/organisations/_form.html.erb | 22 ++++++++++++++++++++++ 1 file changed, 22 insertions(+) create mode 100644 app/views/organisations/_form.html.erb (limited to 'app/views/organisations/_form.html.erb') diff --git a/app/views/organisations/_form.html.erb b/app/views/organisations/_form.html.erb new file mode 100644 index 0000000..ebe8ea3 --- /dev/null +++ b/app/views/organisations/_form.html.erb @@ -0,0 +1,22 @@ +<%= form_with(model: organisation) do |form| %> + <% if organisation.errors.any? %> +
+

<%= pluralize(organisation.errors.count, "error") %> prohibited this organisation from being saved:

+ + +
+ <% end %> + +
+ <%= form.label :name, style: "display: block" %> + <%= form.text_field :name %> +
+ +
+ <%= form.submit %> +
+<% end %> -- cgit v1.2.3