feat(reports): allow reports to hold multiple events

Signed-off-by: Thomas Citharel <tcit@tcit.fr>
This commit is contained in:
Thomas Citharel
2023-06-05 18:32:29 +02:00
parent 538139eefa
commit f2ac3e2e5d
21 changed files with 185 additions and 104 deletions

View File

@@ -7,9 +7,11 @@
<%= gettext "Profile %{profile} was reported", profile: Mobilizon.Actors.Actor.display_name_and_username(@report.reported) %>
<% end %>
<% end %>
<%= if Map.has_key?(@report, :event) and @report.event do %>
<%= gettext "Event" %>
<%= @report.event.title %>
<%= if Map.has_key?(@report, :event) && length(@report.events) > 0 do %>
<%= gettext "Events" %>
<%= for event <- @report.events do %>
<%= event.title %>
<% end %>
<% end %>
<%= if Map.has_key?(@report, :comments) && length(@report.comments) > 0 do %>
<%= gettext "Comments" %>