<%= reservation.property&.property_number %> <% if local_assigns[:admin] && local_assigns[:conflicting_properties]&.include?(reservation.property_id) %> Conflict <% end %> <%= reservation.customer&.customer_name %> <%= reservation.created_by&.full_name %> <% case reservation.status %> <% when "pending" %> Pending <% when "approved" %> Approved <% when "expired" %> Expired <% when "cancelled" %> Cancelled <% when "sold" %> Sold <% end %> <%= reservation.expires_at.strftime("%d-%b-%Y %H:%M") %> <%= reservation.created_at.strftime("%d-%b-%Y %H:%M") %> <% if local_assigns[:admin] %> <%= link_to "View", admin_portal_reservation_path(reservation), class: "btn btn-sm btn-primary" %> <% elsif local_assigns[:agent] %> <%= link_to "View", agent_portal_reservation_path(reservation), class: "btn btn-sm btn-primary" %> <% elsif local_assigns[:client] %> <%= link_to "View", client_portal_reservation_path(reservation), class: "btn btn-sm btn-primary" %> <% end %>