2021-03-19 16:38:52 -04:00
|
|
|
<div class="modal-body">
|
|
|
|
|
|
|
|
<p>Are you sure you want to delete all assigned shifts from the selected days?</p>
|
|
|
|
|
|
|
|
<%= for {y, data} <- @date_map do %>
|
|
|
|
<dt><%= y %></dt>
|
|
|
|
<% months = Map.keys(data) %>
|
|
|
|
<dd>
|
|
|
|
<%= for {m, i} <- Enum.with_index(months, 1) do %>
|
2021-03-21 10:47:53 -04:00
|
|
|
<%= data |> Map.get(m) |> hd() |> Calendar.strftime("%b") %>:
|
2021-03-19 16:38:52 -04:00
|
|
|
<% days = Map.get(data, m) %>
|
|
|
|
<%= for {d, i} <- Enum.with_index(days, 1) do %>
|
|
|
|
<%= d.day %><%= if i < length(days) do %>,<% end %>
|
|
|
|
<% end %>
|
|
|
|
|
|
|
|
<%= if i < length(months) do %><br /><% end %>
|
|
|
|
<% end %>
|
|
|
|
</dd>
|
|
|
|
<% end %>
|
|
|
|
|
|
|
|
</div>
|
|
|
|
<div class="modal-footer">
|
|
|
|
|
|
|
|
<%= link "Cancel", to: "#", class: "btn btn-outline-dark", phx_click: "hide", phx_target: "##{@modal_id}" %>
|
|
|
|
<%= link "Confirm Delete", to: "#",
|
|
|
|
class: "btn btn-danger",
|
|
|
|
phx_click: "confirm-delete-days-shifts",
|
|
|
|
phx_target: @myself
|
|
|
|
%>
|
|
|
|
|
|
|
|
</div>
|