浏览代码

Merge pull request #912 from nabinhait/hotfix

Hotfix
version-14
Nabin Hait 10 年前
父节点
当前提交
1f994d31b8
共有 1 个文件被更改,包括 7 次插入9 次删除
  1. +7
    -9
      frappe/core/doctype/communication/communication.py

+ 7
- 9
frappe/core/doctype/communication/communication.py 查看文件

@@ -167,14 +167,12 @@ def set_portal_link(sent_via, comm):

footer = ""

if is_signup_enabled() and hasattr(sent_via, "get_portal_page"):
portal_page = sent_via.get_portal_page()
if portal_page:
is_valid_recipient = cstr(sent_via.get("email") or sent_via.get("email_id") or
sent_via.get("contact_email")) in comm.recipients
if is_valid_recipient:
url = "%s/%s?name=%s" % (get_url(), portal_page, urllib.quote(sent_via.name))
footer = """<!-- Portal Link -->
<p><a href="%s" target="_blank">View this on our website</a></p>""" % url
if is_signup_enabled():
is_valid_recipient = cstr(sent_via.get("email") or sent_via.get("email_id") or
sent_via.get("contact_email")) in comm.recipients
if is_valid_recipient:
url = "%s/%s/%s" % (get_url(), urllib.quote(sent_via.doctype), urllib.quote(sent_via.name))
footer = """<!-- Portal Link -->
<p><a href="%s" target="_blank">View this on our website</a></p>""" % url

return footer

正在加载...
取消
保存