<%= property.name %> |
<%= property.price %> |
<%= property.description %> |
<%= if Roles.can?(@current_user, property, :show) do %>
<%= live_redirect "Show", to: Routes.property_show_path(@socket, :show, property) %>
<% end %>
<%= if Roles.can?(@current_user, property, :edit) do %>
<%= live_patch "Edit", to: Routes.property_index_path(@socket, :edit, property) %>
<% end %>
<%= if Roles.can?(@current_user, property, :delete) do %>
<%= link "Delete", to: "#", phx_click: "delete", phx_value_id: property.id, data: [confirm: "Are you sure?"] %>
<% end %>
|
<% end %>