mirror of
https://github.com/QingdaoU/OnlineJudge.git
synced 2025-01-01 10:02:01 +00:00
492e7446b1
增加 js 的压缩配置 修改设置,增加备案号 Squash from3dd19cf
tobfc4123
by virusdefender
16 lines
583 B
Python
16 lines
583 B
Python
# coding=utf-8
|
|
from envelopes import Envelope
|
|
|
|
from django.conf import settings
|
|
|
|
|
|
def send_email(from_name, to_email, to_name, subject, content):
|
|
envelope = Envelope(from_addr=(settings.SMTP_CONFIG["email"], from_name),
|
|
to_addr=(to_email, to_name),
|
|
subject=subject,
|
|
html_body=content)
|
|
envelope.send(settings.SMTP_CONFIG["smtp_server"],
|
|
login=settings.SMTP_CONFIG["email"],
|
|
password=settings.SMTP_CONFIG["password"],
|
|
tls=settings.SMTP_CONFIG["tls"])
|