mirror of
https://github.com/HamzaSha1/zod-backend.git
synced 2025-07-14 09:37:20 +00:00
added optional user as name
This commit is contained in:
@ -37,6 +37,27 @@ def send_email_otp(email, verification_code):
|
||||
return True
|
||||
|
||||
|
||||
@shared_task
|
||||
def send_mail(recipient_list, template, context: dict = None):
|
||||
"""
|
||||
used to send otp on email
|
||||
:param context:
|
||||
:param recipient_list: e-mail list
|
||||
:param template: email template
|
||||
"""
|
||||
if context is None:
|
||||
context = {}
|
||||
from_email = settings.EMAIL_FROM_ADDRESS
|
||||
recipient_list = recipient_list
|
||||
send_templated_mail(
|
||||
template_name=template,
|
||||
from_email=from_email,
|
||||
recipient_list=recipient_list,
|
||||
context=context
|
||||
)
|
||||
return True
|
||||
|
||||
|
||||
@shared_task()
|
||||
def notify_task_expiry():
|
||||
"""
|
||||
|
Reference in New Issue
Block a user