diff options
author | Matthew Lemon <y@yulqen.org> | 2023-12-17 16:32:09 +0000 |
---|---|---|
committer | Matthew Lemon <y@yulqen.org> | 2023-12-17 16:32:09 +0000 |
commit | 86916794341f20b26b9a321f1e15f9521f94a618 (patch) | |
tree | 71c9dbdcabb4312d502f2411ea0e90ae1042fe5c /app/views | |
parent | c84b94a647fb4c068e8be9d0495ff7284f41f168 (diff) |
Tidied up the basic event index and form
Diffstat (limited to 'app/views')
-rw-r--r-- | app/views/events/_form.html.erb | 10 | ||||
-rw-r--r-- | app/views/events/index.html.erb | 2 |
2 files changed, 7 insertions, 5 deletions
diff --git a/app/views/events/_form.html.erb b/app/views/events/_form.html.erb index db05a72..da7f932 100644 --- a/app/views/events/_form.html.erb +++ b/app/views/events/_form.html.erb @@ -12,16 +12,16 @@ <% end %> <div> - <%= form.label :date, style: "display: block" %> - <%= form.date_field :date %> + <%= form.label :date, style: "display: block", class: "form-label" %> + <%= form.date_field :date, class: "form-control" %> </div> <div> - <%= form.label :name, style: "display: block" %> - <%= form.text_field :name %> + <%= form.label :name, style: "display: block", class: "form-label" %> + <%= form.text_field :name, class: "form-control" %> </div> <div> - <%= form.submit %> + <%= form.submit class: "btn btn-primary mt-2"%> </div> <% end %> diff --git a/app/views/events/index.html.erb b/app/views/events/index.html.erb index 654d317..16c656b 100644 --- a/app/views/events/index.html.erb +++ b/app/views/events/index.html.erb @@ -2,6 +2,8 @@ <h1>Events</h1> +<%= render partial: "events/form", locals: { event: Event.new } %> + <%= link_to "New event", new_event_path %> <table class="table table-success table-striped table-bordered mt-2"> |