【问题标题】:django-notification not sending email by defaultdjango-notification 默认不发送电子邮件
【发布时间】:2011-08-05 08:34:34
【问题描述】:

问题,

我已经创建了我的新通知,我的新通知模板。 一旦用户执行特定操作,它就会创建新记录,但不会发送电子邮件。

django-notification 是否假设自动向用户发送电子邮件?

def new(request, template_name='wall/new.html', user=None):
    if request.method == 'POST':
        form = PostForm(request.POST)
        if form.is_valid():
            form.save()
            if request.POST.get('from_user') != request.POST.get('user'):
                if notification:
                    notification.send([request.user], "new_wall_post", {"user": request.user, "post": request.POST.get('text')})

【问题讨论】:

    标签: django django-apps django-notification


    【解决方案1】:

    是的,它应该自动发送。

    尝试检查:

    1) 该“new_wall_post”的通知设置已启用 对于该用户
    2) 电子邮件对该用户有效
    3) 用户 处于活动状态
    4) 电子邮件后端配置正确

    另外,您的意思是向墙的所有者而不是墙的海报发送通知吗?

    【讨论】:

      猜你喜欢
      • 2021-08-09
      • 2018-10-19
      • 2016-05-18
      • 2019-07-10
      • 2021-03-15
      • 1970-01-01
      • 2012-04-04
      • 2013-07-20
      • 2010-10-23
      相关资源
      最近更新 更多