# Path: emailcongress/utils.py
# def bool_eval(v):
# def ordinal(n):
# def construct_link(protocol, hostname, path, get_param_dict=None):


from django.conf import settings
from django.template.loader import render_to_string
from django.core.urlresolvers import reverse
from postmark import PMMail
from raven.contrib.django.raven_compat.models import client
from emailcongress import utils




class NoReply(PMMail):

    HTML_BODY_TEMPLATE_DIR = 'emails/html_body/'
    TEXT_BODY_TEMPLATE_DIR = 'emails/text_body/'

    def __init__(self, django_user, **kwargs):
        super().__init__(**kwargs)
        self.user = django_user.user
        self.to = django_user.email
        self.ctx = {'user': self.user,
                    'verification_link': self.user.verification_link,

# Path: emailcongress/utils.py
# def bool_eval(v):
# def ordinal(n):
# def construct_link(protocol, hostname, path, get_param_dict=None):


# Path: emailcongress/emailer.py
from django.conf import settings
from django.template.loader import render_to_string
from django.core.urlresolvers import reverse
from postmark import PMMail
from raven.contrib.django.raven_compat.models import client
from emailcongress import utils





class NoReply(PMMail):

    HTML_BODY_TEMPLATE_DIR = 'emails/html_body/'
    TEXT_BODY_TEMPLATE_DIR = 'emails/text_body/'

    def __init__(self, django_user, **kwargs):
        super().__init__(**kwargs)
        self.user = django_user.user
        self.to = django_user.email
        self.ctx = {'user': self.user,
                    'verification_link': self.user.verification_link,

                    'faq_link': utils.construct_link(settings.PROTOCOL, settings.HOSTNAME, reverse('faq'))}