Ejemplo n.º 1
0
def send_email(organisation, recipients):
    sender = config.ADMINS[0]
    subject = 'Results have been generated for ' + organisation
    text_body = \
    """
    Greetings from Zense,

    We have completed your task in regards to %s
    Please visit us back

    Regards,
    Team Stalker, Zense """ % str(organisation)
    msg = Message(subject, sender = sender, recipients = recipients)
    msg.body = text_body
    with app.app_context():
        mail.send(msg)
Ejemplo n.º 2
0
def send_email(organisation, recipients):
    sender = config.ADMINS[0]
    subject = 'Results have been generated for ' + organisation
    text_body = \
    """
    Greetings from Zense,

    We have completed your task in regards to %s
    Please visit us back

    Regards,
    Team Stalker, Zense """ % str(organisation)
    msg = Message(subject, sender=sender, recipients=recipients)
    msg.body = text_body
    with app.app_context():
        mail.send(msg)
Ejemplo n.º 3
0
def send_email(subject, sender, recipients):
	msg.body = """
		From: %s <%s>
		%s
		""" % (form.name.data, form.email.data, form.message.data)
		mail.send(msg)
Ejemplo n.º 4
0
def send_asyc_email(msg):
	mail.send(msg)
Ejemplo n.º 5
0
from flaskext.mail import Message

def send_awaiting_confirm_mail(user):
  
    subject = "We're waiting for your confirmation!!"
    mail_to_be_sent = Message(subject=subject, recipients=[user['Members_Email']])
    confirmation_url = url_for('activate_user', user_id=user['_id'],
_external=True)
    mail_to_be_sent.body = "Dear %s, click here to confirm: %s" %
(user['Members_Email'], confirmation_url)
    
    from routes import mail
    mail.send(mail_to_be_sent)