Slide 16
Slide 16 text
send_mail()
関数は何をしているか
# django.core.mail.__init__.py
def send_mail(subject, message, from_email, recipient_list,
fail_silently=False, auth_user=None, auth_password=None,
connection=None, html_message=None):
# EmailBackend
オブジェクトを取得
connection = connection or get_connection()
# EmailMessage
系オブジェクトを生成
mail = EmailMultiAlternatives(
subject, message, from_email, recipient_list, connection=connection)
# EmailMessage
系オブジェクトで送信
return mail.send()