Fix links to group page in group membership emails and participation

card

Closes #1077

Signed-off-by: Thomas Citharel <tcit@tcit.fr>
chapril
Thomas Citharel 5 months ago
parent 46236dbe1d
commit 123eee675a
No known key found for this signature in database
GPG Key ID: A061B9DDE0CA0773
  1. 4
      lib/web/templates/email/group_membership_approval.html.heex
  2. 2
      lib/web/templates/email/group_membership_approval.text.eex
  3. 2
      lib/web/templates/email/group_membership_rejection.html.heex
  4. 2
      lib/web/templates/email/group_membership_rejection.text.eex
  5. 2
      lib/web/templates/email/participation/card/_title.html.heex
  6. 2
      lib/web/templates/email/participation/card/_title.text.eex

@ -48,7 +48,7 @@
"Your membership request for group %{link_start}<b>%{group}</b>%{link_end} has been approved.",
group: Mobilizon.Actors.Actor.display_name(@group),
link_start:
"<a href=\"#{Routes.page_url(Mobilizon.Web.Endpoint, :actor, Mobilizon.Actors.Actor.preferred_username_and_domain(@group))}\">",
"<a href=\"#{Routes.page_url(Mobilizon.Web.Endpoint, :actor, Mobilizon.Actors.Actor.preferred_username_and_domain(@group)) |> URI.decode()}\">",
link_end: "</a>"
)
|> raw %>
@ -66,7 +66,7 @@
<td align="center" style="border-radius: 3px;" bgcolor="#3C376E">
<a
href={
"#{Routes.page_url(Mobilizon.Web.Endpoint, :actor, Mobilizon.Actors.Actor.preferred_username_and_domain(@group))}"
"#{Routes.page_url(Mobilizon.Web.Endpoint, :actor, Mobilizon.Actors.Actor.preferred_username_and_domain(@group)) |> URI.decode()}"
}
target="_blank"
style="font-size: 20px; font-family: Helvetica, Arial, sans-serif; color: #ffffff; text-decoration: none; padding: 15px 25px; border-radius: 2px; border: 1px solid #3C376E; display: inline-block;"

@ -2,4 +2,4 @@
==
<%= gettext "Your membership request for group %{group} has been approved.", group: Mobilizon.Actors.Actor.display_name(@group) %>
<%= Routes.page_url(Mobilizon.Web.Endpoint, :actor, Mobilizon.Actors.Actor.preferred_username_and_domain(@group)) %>
<%= Routes.page_url(Mobilizon.Web.Endpoint, :actor, Mobilizon.Actors.Actor.preferred_username_and_domain(@group)) |> URI.decode() %>

@ -48,7 +48,7 @@
"Your membership request for group %{link_start}<b>%{group}</b>%{link_end} has been rejected.",
group: Mobilizon.Actors.Actor.display_name(@group),
link_start:
"<a href=\"#{Routes.page_url(Mobilizon.Web.Endpoint, :actor, Mobilizon.Actors.Actor.preferred_username_and_domain(@group))}\">",
"<a href=\"#{Routes.page_url(Mobilizon.Web.Endpoint, :actor, Mobilizon.Actors.Actor.preferred_username_and_domain(@group)) |> URI.decode()}\">",
link_end: "</a>"
)
|> raw %>

@ -2,4 +2,4 @@
==
<%= gettext "Your membership request for group %{group} has been rejected.", group: Mobilizon.Actors.Actor.display_name(@group) %>
<%= Routes.page_url(Mobilizon.Web.Endpoint, :actor, Mobilizon.Actors.Actor.preferred_username_and_domain(@group)) %>
<%= Routes.page_url(Mobilizon.Web.Endpoint, :actor, Mobilizon.Actors.Actor.preferred_username_and_domain(@group)) |> URI.decode() %>

@ -40,7 +40,7 @@
:actor,
Mobilizon.Actors.Actor.preferred_username_and_domain(@event.attributed_to)
)
|> raw
|> URI.decode()
}
style="color: rgb(254,56,89); font-family: Helvetica,Arial,sans-serif; font-weight: normal; text-align: left; line-height: 1.3; text-decoration: none; vertical-align: baseline; margin: 0; padding: 0; border: 0;"
target="_blank"

@ -1,3 +1,3 @@
<%= gettext("Title: %{title}", title: @event.title) %>
<%= if @event.attributed_to do %><%= gettext("Organizer: %{organizer}", organizer: @event.attributed_to.name || @event.attributed_to.preferred_username) %> <%= Routes.page_url(Mobilizon.Web.Endpoint, :actor, Mobilizon.Actors.Actor.preferred_username_and_domain(@event.attributed_to)) %><% else %><%= gettext("Organizer: %{organizer}", organizer: @event.organizer_actor.name || @event.organizer_actor.preferred_username) %><% end %>
<%= if @event.attributed_to do %><%= gettext("Organizer: %{organizer}", organizer: @event.attributed_to.name || @event.attributed_to.preferred_username) %> <%= Routes.page_url(Mobilizon.Web.Endpoint, :actor, Mobilizon.Actors.Actor.preferred_username_and_domain(@event.attributed_to)) |> URI.decode() %><% else %><%= gettext("Organizer: %{organizer}", organizer: @event.organizer_actor.name || @event.organizer_actor.preferred_username) %><% end %>
Loading…
Cancel
Save