<% content_for :title, "Visits" %>
<%= link_to 'Visits', visits_path(status: :confirmed), role: 'tab', class: "tab font-bold text-xl #{active_visit_places_tab?('visits')}" %> <%= link_to 'Places', places_path, role: 'tab', class: "tab font-bold text-xl #{active_visit_places_tab?('places')}" %>
<%= link_to 'Confirmed', visits_path(status: :confirmed), role: 'tab', class: "tab #{active_tab?(visits_path(status: :confirmed))}" %> <%= link_to visits_path(status: :suggested), role: 'tab', class: "tab #{active_tab?(visits_path(status: :suggested))}" do %> Suggested <% if @suggested_visits_count.positive? %> <%= @suggested_visits_count %> <% end %> <% end %> <%= link_to 'Declined', visits_path(status: :declined), role: 'tab', class: "tab #{active_tab?(visits_path(status: :declined))}" %>
Order by: <%= link_to 'Newest', visits_path(order_by: :desc, status: params[:status]), class: 'btn btn-xs btn-primary mx-1' %> <%= link_to 'Oldest', visits_path(order_by: :asc, status: params[:status]), class: 'btn btn-xs btn-primary mx-1' %>
<% if @visits.empty? %>

Hello there!

Here you'll find your <%= params[:status] %> visits, but now there are none. Create some areas on your map and pretty soon you'll see visit suggestions on this page!

<% else %>
<%= paginate @visits %>
<% end %>