mirror of
https://github.com/discourse/discourse.git
synced 2025-05-21 18:12:32 +08:00
UX: display text & html parts alongside raw email in incoming email modal
This commit is contained in:
@ -78,7 +78,8 @@ class Admin::EmailController < Admin::AdminController
|
||||
def raw_email
|
||||
params.require(:id)
|
||||
incoming_email = IncomingEmail.find(params[:id].to_i)
|
||||
render json: { raw_email: incoming_email.raw }
|
||||
text, html = Email.extract_parts(incoming_email.raw)
|
||||
render json: { raw_email: incoming_email.raw, text_part: text, html_part: html }
|
||||
end
|
||||
|
||||
def incoming
|
||||
|
Reference in New Issue
Block a user