canvas-lms/app/messages/conversation_message.email.erb

39 lines
1.2 KiB
Plaintext

<% define_content :link do %>
<%= conversation_url(asset.conversation_id) %>
<% end %>
<% define_content :user_name do %>
<%= asset.author_short_name_with_shared_contexts(user) rescue t(:unknown_user, "Unknown User") %>
<% end %>
<% define_content :subject do %>
<%= t :subject, "%{user_name} just sent you a message in Canvas.", :user_name => content(:user_name) %>
<% end %>
<% define_content :footer_link do %>
<a href="<%= content :link %>">
<%= t :view_message, "View this message in Conversations" %>
</a>
<% end %>
<% if asset.conversation.subject.present? %>
Subject: <%= asset.conversation.subject %>
<% end %>
<%= asset.body %>
<% if asset.has_media_objects? %>
<%= t("This message includes media comments. To listen or reply, click this link: %{link}.", link: content(:link)) %>
<% else %>
<%= t("You can reply to this message in Canvas by replying directly to this email, or by clicking this link: %{link}.", link: content(:link)) %>
<% end %>
<% unless asset.attachments.empty? %>
<%= t :attached_files, "Attached Files:" %>
<% asset.attachments.each do |attachment| %>
<%= attachment.display_name %> - <%= attachment.readable_size %>
<%= file_download_url(attachment, verifier: attachment.uuid) %>
<% end %>
<% end %>