1
0
mirror of https://github.com/haiwen/seahub.git synced 2025-09-05 17:02:47 +00:00

i18n for org and seahub mails

This commit is contained in:
zhengxie
2012-11-06 17:22:46 +08:00
parent 78579659ff
commit 24e0f4c907
8 changed files with 167 additions and 82 deletions

View File

@@ -7,7 +7,7 @@ msgid ""
msgstr "" msgstr ""
"Project-Id-Version: PACKAGE VERSION\n" "Project-Id-Version: PACKAGE VERSION\n"
"Report-Msgid-Bugs-To: \n" "Report-Msgid-Bugs-To: \n"
"POT-Creation-Date: 2012-11-06 13:38+0800\n" "POT-Creation-Date: 2012-11-06 17:07+0800\n"
"PO-Revision-Date: YEAR-MO-DA HO:MI+ZONE\n" "PO-Revision-Date: YEAR-MO-DA HO:MI+ZONE\n"
"Last-Translator: FULL NAME <EMAIL@ADDRESS>\n" "Last-Translator: FULL NAME <EMAIL@ADDRESS>\n"
"Language-Team: LANGUAGE <LL@li.org>\n" "Language-Team: LANGUAGE <LL@li.org>\n"
@@ -136,6 +136,10 @@ msgstr ""
msgid "简体中文" msgid "简体中文"
msgstr "" msgstr ""
#: views.py:419
msgid "Unable to view recycle page"
msgstr "无法查看文件回收站"
#: views.py:442 views.py:478 #: views.py:442 views.py:478
msgid "Can not access library" msgid "Can not access library"
msgstr "无法访问该资料库" msgstr "无法访问该资料库"
@@ -156,7 +160,7 @@ msgstr "上传的文件名包含非法字符"
msgid "Duplicated filename" msgid "Duplicated filename"
msgstr "已存在同名的文件" msgstr "已存在同名的文件"
#: views.py:505 views.py:2417 #: views.py:505 views.py:1211 views.py:1560 views.py:2423
msgid "File not exists" msgid "File not exists"
msgstr "文件不存在" msgstr "文件不存在"
@@ -188,12 +192,12 @@ msgstr "你没有权限进行还原操作"
msgid "Please specify history ID" msgid "Please specify history ID"
msgstr "请指定历史记录ID" msgstr "请指定历史记录ID"
#: views.py:725 views.py:1490 views.py:1494 views.py:2292 views.py:2327 #: views.py:725 views.py:1495 views.py:1499 views.py:2298 views.py:2333
#: views.py:2648 #: views.py:2654
msgid "Invalid arguments" msgid "Invalid arguments"
msgstr "非法参数" msgstr "非法参数"
#: views.py:727 views.py:822 views.py:2240 #: views.py:727 views.py:822 views.py:2246
msgid "Library not exists" msgid "Library not exists"
msgstr "资料库不存在" msgstr "资料库不存在"
@@ -210,140 +214,152 @@ msgid ""
"Failed to remove library. Only staff or owner can perform this operation." "Failed to remove library. Only staff or owner can perform this operation."
msgstr "删除资料库失败, 只有团体管理员或资料库创建者有权删除资料库。" msgstr "删除资料库失败, 只有团体管理员或资料库创建者有权删除资料库。"
#: views.py:1108 #: views.py:1113
msgid "Failed to create repo" msgid "Failed to create repo"
msgstr "创建失败" msgstr "创建失败"
#: views.py:1126 #: views.py:1131
msgid "Operation successful" msgid "Operation successful"
msgstr "操作成功" msgstr "操作成功"
#: views.py:1128 #: views.py:1133
msgid "Operation failed" msgid "Operation failed"
msgstr "操作失败" msgstr "操作失败"
#: views.py:1159 #: views.py:1164
msgid "Failed to delete file." msgid "Failed to delete file."
msgstr "删除文件出错。" msgstr "删除文件出错。"
#: views.py:1166 #: views.py:1171
#, python-format #, python-format
msgid "%s successfully deleted." msgid "%s successfully deleted."
msgstr "%s 删除成功。" msgstr "%s 删除成功。"
#: views.py:1168 #: views.py:1173
#, python-format #, python-format
msgid "Internal error. Failed to delete %s." msgid "Internal error. Failed to delete %s."
msgstr "内部错误。删除 %s 失败。" msgstr "内部错误。删除 %s 失败。"
#: views.py:1426 #: views.py:1231 views.py:1566
msgid "Unable to view file"
msgstr "无法查看该文件"
#: views.py:1431
msgid "File size surpasses 10M, can not be previewed online." msgid "File size surpasses 10M, can not be previewed online."
msgstr "文件超过10M无法在线查看。" msgstr "文件超过10M无法在线查看。"
#: views.py:1431 #: views.py:1436
msgid "HTTPError: failed to open file online" msgid "HTTPError: failed to open file online"
msgstr "HTTPError: 无法在线打开该文件" msgstr "HTTPError: 无法在线打开该文件"
#: views.py:1434 #: views.py:1439
msgid "URLError: failed to open file online" msgid "URLError: failed to open file online"
msgstr "URLError: 无法在线打开该文件" msgstr "URLError: 无法在线打开该文件"
#: views.py:1446 #: views.py:1451
msgid "Unknown file encoding" msgid "Unknown file encoding"
msgstr "文件编码无法识别" msgstr "文件编码无法识别"
#: views.py:1475 #: views.py:1480
msgid "Internal Error" msgid "Internal Error"
msgstr "内部错误" msgstr "内部错误"
#: views.py:1644 #: views.py:1541
msgid "Unable to edit file"
msgstr "无法编辑该文件"
#: views.py:1629
msgid "Unable to access file"
msgstr "无法访问文件"
#: views.py:1649
msgid "Failed to download library, unable to find servre" msgid "Failed to download library, unable to find servre"
msgstr "下载失败:找不到服务器" msgstr "下载失败:找不到服务器"
#: views.py:1656 #: views.py:1661
msgid "Invalid server setting" msgid "Invalid server setting"
msgstr "服务器设置错误" msgstr "服务器设置错误"
#: views.py:1692 #: views.py:1697
#, python-format #, python-format
msgid "Can not %(op)s directory %(src)s to its subdirectory %(des)s" msgid "Can not %(op)s directory %(src)s to its subdirectory %(des)s"
msgstr "不能把目录 %(src)s %(op)s到它的子目录 %(des)s中" msgstr "不能把目录 %(src)s %(op)s到它的子目录 %(des)s中"
#: views.py:1693 #: views.py:1698
msgid "copy" msgid "copy"
msgstr "复制" msgstr "复制"
#: views.py:1693 #: views.py:1698
msgid "move" msgid "move"
msgstr "移动" msgstr "移动"
#: views.py:1709 #: views.py:1714
#, python-format #, python-format
msgid "Successfully copying %(name)s<a href=\"%(url)s\">view</a>" msgid "Successfully copying %(name)s<a href=\"%(url)s\">view</a>"
msgstr "复制 %(name)s 成功:<a href=\"%(url)s\">查看</a>" msgstr "复制 %(name)s 成功:<a href=\"%(url)s\">查看</a>"
#: views.py:1715 #: views.py:1720
#, python-format #, python-format
msgid "Successfully moving %(name)s <a href=\"%(url)s\">view</a>" msgid "Successfully moving %(name)s <a href=\"%(url)s\">view</a>"
msgstr "移动 %(name)s 成功:<a href=\"%(url)s\">查看</a>" msgstr "移动 %(name)s 成功:<a href=\"%(url)s\">查看</a>"
#: views.py:1828 #: views.py:1833
msgid "Failed to set quota: internal error" msgid "Failed to set quota: internal error"
msgstr "内部错误,设置失败" msgstr "内部错误,设置失败"
#: views.py:1901 templates/sys_useradmin.html:31 #: views.py:1907 templates/sys_useradmin.html:31
#: templates/registration/password_reset_confirm.html:4 #: templates/registration/password_reset_confirm.html:4
#: templates/registration/password_reset_form.html:4 #: templates/registration/password_reset_form.html:4
#: templates/registration/password_reset_form.html:7 #: templates/registration/password_reset_form.html:7
msgid "Password Reset" msgid "Password Reset"
msgstr "密码重置" msgstr "密码重置"
#: views.py:1903 views.py:1944 #: views.py:1909 views.py:1950
msgid "Successfully sending mail" msgid "Successfully sending mail"
msgstr "邮件发送成功" msgstr "邮件发送成功"
#: views.py:1905 views.py:1946 #: views.py:1911 views.py:1952
msgid "Failed to send mail" msgid "Failed to send mail"
msgstr "邮件发送失败" msgstr "邮件发送失败"
#: views.py:1916 #: views.py:1922
msgid "Successfully resetting password" msgid "Successfully resetting password"
msgstr "密码重置成功" msgstr "密码重置成功"
#: views.py:1921 #: views.py:1927
msgid "Failed to reset password: user does not exist" msgid "Failed to reset password: user does not exist"
msgstr "密码重置失败:用户不存在" msgstr "密码重置失败:用户不存在"
#: views.py:1942 #: views.py:1948
msgid "Seafile Registration Information" msgid "Seafile Registration Information"
msgstr "Seafile注册信息" msgstr "Seafile注册信息"
#: views.py:2158 #: views.py:2164
#, python-format #, python-format
msgid "Successfully rename %(old)s to %(new)s。" msgid "Successfully rename %(old)s to %(new)s。"
msgstr "%(old)s 已重命名为 %(new)s" msgstr "%(old)s 已重命名为 %(new)s"
#: views.py:2214 #: views.py:2220
msgid "Failed to create library" msgid "Failed to create library"
msgstr "创建资料库失败" msgstr "创建资料库失败"
#: views.py:2313 #: views.py:2319
#, python-format #, python-format
msgid "" msgid ""
"Successfully revert %(path)s to <a href=\"%(root)s\">root directory.</a>" "Successfully revert %(path)s to <a href=\"%(root)s\">root directory.</a>"
msgstr "成功还原 %(path)s 到<a href=\"%(root)s\">根目录。</a>" msgstr "成功还原 %(path)s 到<a href=\"%(root)s\">根目录。</a>"
#: views.py:2317 views.py:2343 #: views.py:2323 views.py:2349
#, python-format #, python-format
msgid "Successfully revert <a href=\"%(url)s\">%(path)s</a>" msgid "Successfully revert <a href=\"%(url)s\">%(path)s</a>"
msgstr "成功还原 <a href=\"%(url)s\">%(path)s</a>" msgstr "成功还原 <a href=\"%(url)s\">%(path)s</a>"
#: views.py:2339 #: views.py:2345
#, python-format #, python-format
msgid "Successfully revert %(path)s to <a href=\"%(url)s\">root directory.</a>" msgid "Successfully revert %(path)s to <a href=\"%(url)s\">root directory.</a>"
msgstr "成功还原 %(path)s 到<a href=\"%(url)s\">根目录。</a>" msgstr "成功还原 %(path)s 到<a href=\"%(url)s\">根目录。</a>"
#: views.py:2477 #: views.py:2483
msgid "Internal error" msgid "Internal error"
msgstr "内部错误" msgstr "内部错误"
@@ -1213,6 +1229,30 @@ msgstr "你的 Seafile 客户端版本太旧,请升级到最新版本。"
msgid "Click to download." msgid "Click to download."
msgstr "点此下载" msgstr "点此下载"
#: templates/shared_link_email.html:2
#, python-format
msgid ""
"You're receiving this e-mail because %(email)s is sharing a file to you on "
"%(site_name)s."
msgstr "你收到这封邮件是因为 %(email)s 在 %(site_name)s 上共享了一个文件给你。"
#: templates/shared_link_email.html:4
msgid "Please go to the following page and view the file:"
msgstr "请点击以下链接查看:"
#: templates/shared_link_email.html:7 templates/user_add_email.html:14
#: templates/user_reset_email.html:6
#: templates/registration/password_reset_email.html:10
msgid "Thanks for using our site!"
msgstr "感谢使用!"
#: templates/shared_link_email.html:9 templates/user_add_email.html:16
#: templates/user_reset_email.html:8
#: templates/registration/password_reset_email.html:12
#, python-format
msgid "The %(site_name)s team"
msgstr "%(site_name)s 团队"
#: templates/sys_group_admin.html:7 #: templates/sys_group_admin.html:7
msgid "All Groups" msgid "All Groups"
msgstr "所有群组" msgstr "所有群组"
@@ -1305,6 +1345,51 @@ msgstr "上传文件"
msgid "to" msgid "to"
msgstr "到" msgstr "到"
#: templates/user_add_email.html:3
#, python-format
msgid ""
"You're receiving this e-mail because %(user)s added you to organization "
"\"%(org.org_name)s\" on %(site_name)s."
msgstr "你收到这封邮件是因为 %(user)s 在 %(site_name)s 上将你加入到“%(org.org_name)s”团体。"
#: templates/user_add_email.html:5
#, python-format
msgid ""
"You're receiving this e-mail because %(user)s added you to %(site_name)s."
msgstr "你收到这封邮件是因为 %(user)s 将你加入到 %(site_name)s。"
#: templates/user_add_email.html:7
msgid "Following is your account information:"
msgstr "以下是您的登录信息:"
#: templates/user_add_email.html:8
#, python-format
msgid "Email: %(email)s"
msgstr "邮箱:%(email)s"
#: templates/user_add_email.html:9
#, python-format
msgid "Password: %(password)s"
msgstr "密码:%(password)s"
#: templates/user_add_email.html:11
msgid "Please go to the following page and log in:"
msgstr "请点击以下链接登录:"
#: templates/user_reset_email.html:2
#, python-format
msgid ""
"You're receiving this e-mail because staff has reset your password at "
"%(site_name)s. "
msgstr "你收到这封邮件是因为你在 %(site_name)s 的账号密码已经被管理员重置。"
#: templates/user_reset_email.html:4
#, python-format
msgid ""
"Your new password is %(password)s, please modify your password as soon as "
"possible."
msgstr "你的新密码是 %(password)s, 请尽快修改。"
#: templates/userinfo.html:13 #: templates/userinfo.html:13
msgid "Profile" msgid "Profile"
msgstr "设置" msgstr "设置"
@@ -1415,15 +1500,6 @@ msgstr "请点击以下链接更新密码:"
msgid "Your username, in case you've forgotten:" msgid "Your username, in case you've forgotten:"
msgstr "你的用户名:" msgstr "你的用户名:"
#: templates/registration/password_reset_email.html:10
msgid "Thanks for using our site!"
msgstr "感谢使用!"
#: templates/registration/password_reset_email.html:12
#, python-format
msgid "The %(site_name)s team"
msgstr "%(site_name)s 团队"
#: templates/registration/password_reset_form.html:9 #: templates/registration/password_reset_form.html:9
msgid "Your email used in login: " msgid "Your email used in login: "
msgstr "你注册的邮箱账号:" msgstr "你注册的邮箱账号:"

View File

@@ -7,7 +7,7 @@ msgid ""
msgstr "" msgstr ""
"Project-Id-Version: PACKAGE VERSION\n" "Project-Id-Version: PACKAGE VERSION\n"
"Report-Msgid-Bugs-To: \n" "Report-Msgid-Bugs-To: \n"
"POT-Creation-Date: 2012-10-31 16:17+0800\n" "POT-Creation-Date: 2012-11-06 17:20+0800\n"
"PO-Revision-Date: YEAR-MO-DA HO:MI+ZONE\n" "PO-Revision-Date: YEAR-MO-DA HO:MI+ZONE\n"
"Last-Translator: FULL NAME <EMAIL@ADDRESS>\n" "Last-Translator: FULL NAME <EMAIL@ADDRESS>\n"
"Language-Team: LANGUAGE <LL@li.org>\n" "Language-Team: LANGUAGE <LL@li.org>\n"
@@ -335,19 +335,19 @@ msgstr ""
msgid "" msgid ""
"\n" "\n"
"and reset your password later.\n" "and reset your password later.\n"
"Thank you!\n" "Thanks for using our site!\n"
"\n" "\n"
"The %(site_name)s team\n" "The %(site_name)s team\n"
msgstr "" msgstr ""
"\n" "\n"
"随后请重置你的密码。\n" "随后请重置你的密码。\n"
"谢谢\n" "感谢使用\n"
"\n" "\n"
"%(site_name)s 团队\n" "%(site_name)s 团队\n"
#: templates/organizations/personal.html:14 #: templates/organizations/personal.html:14
msgid "Profile" msgid "Account"
msgstr "个人基本信息" msgstr "我的基本信息"
#: templates/organizations/personal.html:20 #: templates/organizations/personal.html:20
msgid "No Nickname" msgid "No Nickname"
@@ -357,6 +357,9 @@ msgstr "暂无昵称"
msgid "Edit" msgid "Edit"
msgstr "编辑" msgstr "编辑"
#~ msgid "Profile"
#~ msgstr "个人基本信息"
#~ msgid "Total Org Space Used" #~ msgid "Total Org Space Used"
#~ msgstr "团体已用总空间" #~ msgstr "团体已用总空间"
@@ -372,9 +375,6 @@ msgstr "编辑"
#~ msgid "Last Update" #~ msgid "Last Update"
#~ msgstr "更新时间" #~ msgstr "更新时间"
#~ msgid "Account"
#~ msgstr "我的基本信息"
#~ msgid "Nickname is empty" #~ msgid "Nickname is empty"
#~ msgstr "暂无昵称" #~ msgstr "暂无昵称"

View File

@@ -10,7 +10,7 @@ Please click the link to log in:
{{ protocol }}://{{ domain }}{% url auth_login %} {{ protocol }}://{{ domain }}{% url auth_login %}
{% blocktrans %} {% blocktrans %}
and reset your password later. and reset your password later.
Thank you! Thanks for using our site!
The {{ site_name }} team The {{ site_name }} team
{% endblocktrans%} {% endblocktrans%}

View File

@@ -443,6 +443,8 @@ def send_shared_link(request):
result = {} result = {}
content_type = 'application/json; charset=utf-8' content_type = 'application/json; charset=utf-8'
from seahub.settings import SITE_NAME
form = FileLinkShareForm(request.POST) form = FileLinkShareForm(request.POST)
if form.is_valid(): if form.is_valid():
email = form.cleaned_data['email'] email = form.cleaned_data['email']
@@ -459,6 +461,7 @@ def send_shared_link(request):
'email': request.user.username, 'email': request.user.username,
'to_email': to_email, 'to_email': to_email,
'file_shared_link': file_shared_link, 'file_shared_link': file_shared_link,
'site_name': SITE_NAME,
} }
try: try:

View File

@@ -1,12 +1,11 @@
{% autoescape off %} {% load i18n %}{% autoescape off %}
亲爱的 {{ to_email }} {% blocktrans %}You're receiving this e-mail because {{ email }} is sharing a file to you on {{ site_name }}.{% endblocktrans%}
{{ email }} 在SeaCloud上共享了一个文件给你请点击以下链接查看
{% trans "Please go to the following page and view the file:" %}
{{ file_shared_link }} {{ file_shared_link }}
感谢使用我们的网站! {% trans "Thanks for using our site!" %}
Seafile团队 {% blocktrans %}The {{ site_name }} team{% endblocktrans %}
{% endautoescape %} {% endautoescape %}

View File

@@ -1,19 +1,18 @@
{% autoescape off %} {% load i18n %}{% autoescape off %}
亲爱的 {{ email }}
{% if org %} {% if org %}
{{ user }} 在 SeaCloud 云存储上将您加入到企业 {{ org.org_name }} {% blocktrans %}You're receiving this e-mail because {{ user }} added you to organization "{{ org.org_name }}" on {{ site_name }}.{% endblocktrans%}
{% else %} {% else %}
{{ user }} 将您加入 SeaCloud 云存储! {% blocktrans %}You're receiving this e-mail because {{ user }} added you to {{ site_name }}.{% endblocktrans%}
{% endif %} {% endif %}
以下是您的登录信息: {% trans "Following is your account information:" %}
用户名: {{ email }} {% blocktrans %}Email: {{ email }}{% endblocktrans %}
密码: {{ password }} {% blocktrans %}Password: {{ password }}{% endblocktrans %}
请点击以下链接登录: {% trans "Please go to the following page and log in:" %}
{{ protocol }}://{{ domain }}{% url auth_login %} {{ protocol }}://{{ domain }}{% url auth_login %}
感谢使用我们的网站! {% trans "Thanks for using our site!" %}
Seafile团队 {% blocktrans %}The {{ site_name }} team{% endblocktrans %}
{% endautoescape %} {% endautoescape %}

View File

@@ -1,9 +1,10 @@
{% autoescape off %} {% load i18n %}{% autoescape off %}
亲爱的 {{ email }} {% blocktrans %}You're receiving this e-mail because staff has reset your password at {{ site_name }}. {% endblocktrans %}
管理员已经将您的密码重置为{{ password }},登录后,请尽快修改您的密码!
感谢使用我们的网站! {% blocktrans %}Your new password is {{ password }}, please modify your password as soon as possible.{% endblocktrans %}
Seafile团队 {% trans "Thanks for using our site!" %}
{% blocktrans %}The {{ site_name }} team{% endblocktrans %}
{% endautoescape %} {% endautoescape %}

View File

@@ -416,7 +416,7 @@ def render_recycle_dir(request, repo_id, commit_id):
@ctx_switch_required @ctx_switch_required
def repo_recycle_view(request, repo_id): def repo_recycle_view(request, repo_id):
if get_user_permission(request, repo_id) != 'rw': if get_user_permission(request, repo_id) != 'rw':
return render_permission_error(request, '无法查看文件回收站') return render_permission_error(request, _(u'Unable to view recycle page'))
commit_id = request.GET.get('commit_id', '') commit_id = request.GET.get('commit_id', '')
if not commit_id: if not commit_id:
@@ -915,6 +915,11 @@ def myhome(request):
if is_registered_user(c.contact_email) ] if is_registered_user(c.contact_email) ]
else: else:
allow_public_share = True allow_public_share = True
# Clear org messages just in case. Should never happen in production
# environment.
orgmsg_list = []
# List all personal groups and all registered users for autocompletion. # List all personal groups and all registered users for autocompletion.
autocomp_groups = get_personal_groups(-1, -1) autocomp_groups = get_personal_groups(-1, -1)
contacts = [] contacts = []
@@ -1203,7 +1208,7 @@ def repo_view_file(request, repo_id):
obj_id = None obj_id = None
if not obj_id: if not obj_id:
return render_error(request, '文件不存在') return render_error(request, _(u'File not exists'))
repo = get_repo(repo_id) repo = get_repo(repo_id)
if not repo: if not repo:
@@ -1223,7 +1228,7 @@ def repo_view_file(request, repo_id):
'view', 'view',
request.user.username) request.user.username)
else: else:
return render_permission_error(request, '无法查看该文件') return render_permission_error(request, _(u'Unable to view file'))
read_only = True if permission == 'r' else False read_only = True if permission == 'r' else False
@@ -1533,7 +1538,7 @@ def repo_file_edit(request, repo_id):
return update_file_after_edit(request, repo_id) return update_file_after_edit(request, repo_id)
if get_user_permission(request, repo_id) != 'rw': if get_user_permission(request, repo_id) != 'rw':
return render_permission_error(request, '无法编辑该文件') return render_permission_error(request, _(u'Unable to edit file'))
path = request.GET.get('p', '/') path = request.GET.get('p', '/')
if path[-1] == '/': if path[-1] == '/':
@@ -1552,13 +1557,13 @@ def repo_file_edit(request, repo_id):
except: except:
obj_id = None obj_id = None
if not obj_id: if not obj_id:
return render_error(request, '文件不存在') return render_error(request, _(u'File not exists'))
if access_to_repo(request, repo_id, ''): if access_to_repo(request, repo_id, ''):
token = seafserv_rpc.web_get_access_token(repo_id, obj_id, token = seafserv_rpc.web_get_access_token(repo_id, obj_id,
'view', request.user.username) 'view', request.user.username)
else: else:
return render_permission_error(request, '无法查看该文件') return render_permission_error(request, _(u'Unable to view file'))
# generate path and link # generate path and link
zipped = gen_path_link(path, repo.name) zipped = gen_path_link(path, repo.name)
@@ -1621,7 +1626,7 @@ def repo_access_file(request, repo_id, obj_id):
token = seafserv_rpc.web_get_access_token(repo_id, obj_id, token = seafserv_rpc.web_get_access_token(repo_id, obj_id,
op, request.user.username) op, request.user.username)
else: else:
return render_permission_error(request, '无法访问文件') return render_permission_error(request, _(u'Unable to access file'))
redirect_url = gen_file_get_url(token, file_name) redirect_url = gen_file_get_url(token, file_name)
return HttpResponseRedirect(redirect_url) return HttpResponseRedirect(redirect_url)
@@ -1896,6 +1901,7 @@ def send_user_reset_email(request, email, password):
c = { c = {
'email': email, 'email': email,
'password': password, 'password': password,
'site_name': settings.SITE_NAME,
} }
try: try:
send_mail(_(u'Password Reset'), t.render(Context(c)), send_mail(_(u'Password Reset'), t.render(Context(c)),
@@ -1937,6 +1943,7 @@ def send_user_add_mail(request, email, password):
'password': password, 'password': password,
'domain': domain, 'domain': domain,
'protocol': use_https and 'https' or 'http', 'protocol': use_https and 'https' or 'http',
'site_name': settings.SITE_NAME,
} }
try: try:
send_mail(_(u'Seafile Registration Information'), t.render(Context(c)), send_mail(_(u'Seafile Registration Information'), t.render(Context(c)),