diff --git a/app/views/appointments/_appointment.html.erb b/app/views/appointments/_appointment.html.erb index 69b8797..f0eb703 100644 --- a/app/views/appointments/_appointment.html.erb +++ b/app/views/appointments/_appointment.html.erb @@ -19,7 +19,9 @@
Actions - <%= link_to "Edit", edit_appointment_path(appointment), class: "text-xs text-indigo-500 hover:text-indigo-400", data: { turbo: false } %> + <% if appointment.created_by?(Current.user) %> + <%= link_to "Edit", edit_appointment_path(appointment), class: "text-xs text-indigo-500 hover:text-indigo-400", data: { turbo: false } %> + <% end %>
diff --git a/app/views/appointments/index.html.erb b/app/views/appointments/index.html.erb index 6bc3c9e..fd9cb4f 100644 --- a/app/views/appointments/index.html.erb +++ b/app/views/appointments/index.html.erb @@ -1,3 +1,5 @@ +<%= turbo_stream_from "appointments_list" %> +

Appointments