Skip to content
体验新版
项目
组织
正在加载...
登录
切换导航
打开侧边栏
gjl2004yn
jumpserver
提交
9ac7f26c
J
jumpserver
项目概览
gjl2004yn
/
jumpserver
与 Fork 源项目一致
从无法访问的项目Fork
通知
2
Star
0
Fork
0
代码
文件
提交
分支
Tags
贡献者
分支图
Diff
Issue
0
列表
看板
标记
里程碑
合并请求
0
Wiki
0
Wiki
分析
仓库
DevOps
项目成员
Pages
J
jumpserver
项目概览
项目概览
详情
发布
仓库
仓库
文件
提交
分支
标签
贡献者
分支图
比较
Issue
0
Issue
0
列表
看板
标记
里程碑
合并请求
0
合并请求
0
Pages
分析
分析
仓库分析
DevOps
Wiki
0
Wiki
成员
成员
收起侧边栏
关闭侧边栏
动态
分支图
创建新Issue
提交
Issue看板
体验新版 GitCode,发现更多精彩内容 >>
提交
9ac7f26c
编写于
4月 19, 2018
作者:
baltery
浏览文件
操作
浏览文件
下载
电子邮件补丁
差异文件
[Update] 修改用户详情,自己更改自己otp,提示小写
上级
f73fe1f3
变更
3
隐藏空白更改
内联
并排
Showing
3 changed file
with
40 addition
and
31 deletion
+40
-31
apps/i18n/zh/LC_MESSAGES/django.mo
apps/i18n/zh/LC_MESSAGES/django.mo
+0
-0
apps/i18n/zh/LC_MESSAGES/django.po
apps/i18n/zh/LC_MESSAGES/django.po
+34
-30
apps/users/templates/users/user_detail.html
apps/users/templates/users/user_detail.html
+6
-1
未找到文件。
apps/i18n/zh/LC_MESSAGES/django.mo
浏览文件 @
9ac7f26c
无法预览此类型文件
apps/i18n/zh/LC_MESSAGES/django.po
浏览文件 @
9ac7f26c
...
...
@@ -8,7 +8,7 @@ msgid ""
msgstr ""
"Project-Id-Version: Jumpserver 0.3.3\n"
"Report-Msgid-Bugs-To: \n"
"POT-Creation-Date: 2018-04-19 1
2:44
+0800\n"
"POT-Creation-Date: 2018-04-19 1
7:48
+0800\n"
"PO-Revision-Date: YEAR-MO-DA HO:MI+ZONE\n"
"Last-Translator: ibuler <ibuler@qq.com>\n"
"Language-Team: Jumpserver team<ibuler@qq.com>\n"
...
...
@@ -788,9 +788,9 @@ msgstr "选择节点"
#: assets/templates/assets/system_user_detail.html:183
#: assets/templates/assets/system_user_list.html:138 templates/_modal.html:22
#: terminal/templates/terminal/session_detail.html:108
#: users/templates/users/user_detail.html:3
57
#: users/templates/users/user_detail.html:38
2
#: users/templates/users/user_detail.html:4
05
#: users/templates/users/user_detail.html:3
62
#: users/templates/users/user_detail.html:38
7
#: users/templates/users/user_detail.html:4
10
#: users/templates/users/user_group_create_update.html:32
#: users/templates/users/user_group_list.html:86
#: users/templates/users/user_list.html:196
...
...
@@ -883,7 +883,7 @@ msgstr "刷新"
#: assets/templates/assets/asset_detail.html:300
#: users/templates/users/user_detail.html:282
#: users/templates/users/user_detail.html:30
4
#: users/templates/users/user_detail.html:30
9
msgid "Update successfully!"
msgstr "更新成功"
...
...
@@ -971,8 +971,8 @@ msgstr "存在资产,不能删除"
#: assets/templates/assets/asset_list.html:595
#: assets/templates/assets/system_user_list.html:133
#: users/templates/users/user_detail.html:35
2
#: users/templates/users/user_detail.html:3
77
#: users/templates/users/user_detail.html:35
7
#: users/templates/users/user_detail.html:3
82
#: users/templates/users/user_group_list.html:81
#: users/templates/users/user_list.html:191
msgid "Are you sure?"
...
...
@@ -2471,7 +2471,7 @@ msgid "Can't provide security? Please contact the administrator!"
msgstr "如果不能提供OTP验证码,请联系管理员!"
#: users/templates/users/reset_password.html:45
#: users/templates/users/user_detail.html:34
3 users/utils.py:72
#: users/templates/users/user_detail.html:34
8 users/utils.py:73
msgid "Reset password"
msgstr "重置密码"
...
...
@@ -2535,35 +2535,39 @@ msgstr "发送"
msgid "Send reset ssh key mail"
msgstr "发送重置密钥邮件"
#: users/templates/users/user_detail.html:342
#: users/templates/users/user_detail.html:291
msgid "Goto profile page enable otp"
msgstr "请去个人信息页面启用自己的OTP"
#: users/templates/users/user_detail.html:347
msgid "An e-mail has been sent to the user`s mailbox."
msgstr "已发送邮件到用户邮箱"
#: users/templates/users/user_detail.html:35
3
#: users/templates/users/user_detail.html:35
8
msgid "This will reset the user password and send a reset mail"
msgstr "将失效用户当前密码,并发送重设密码邮件到用户邮箱"
#: users/templates/users/user_detail.html:3
67
#: users/templates/users/user_detail.html:3
72
msgid ""
"The reset-ssh-public-key E-mail has been sent successfully. Please inform "
"the user to update his new ssh public key."
msgstr "重设密钥邮件将会发送到用户邮箱"
#: users/templates/users/user_detail.html:3
68
#: users/templates/users/user_detail.html:3
73
msgid "Reset SSH public key"
msgstr "重置SSH密钥"
#: users/templates/users/user_detail.html:3
78
#: users/templates/users/user_detail.html:3
83
msgid "This will reset the user public key and send a reset mail"
msgstr "将会失效用户当前密钥,并发送重置邮件到用户邮箱"
#: users/templates/users/user_detail.html:
395
#: users/templates/users/user_detail.html:
400
#: users/templates/users/user_profile.html:203
msgid "Successfully updated the SSH public key."
msgstr "更新ssh密钥成功"
#: users/templates/users/user_detail.html:
396
#: users/templates/users/user_detail.html:40
0
#: users/templates/users/user_detail.html:
401
#: users/templates/users/user_detail.html:40
5
#: users/templates/users/user_profile.html:204
#: users/templates/users/user_profile.html:209
msgid "User SSH public key update"
...
...
@@ -2670,11 +2674,11 @@ msgstr "或者重置并下载密钥"
msgid "Update user"
msgstr "更新用户"
#: users/utils.py:3
6
#: users/utils.py:3
7
msgid "Create account successfully"
msgstr "创建账户成功"
#: users/utils.py:3
8
#: users/utils.py:3
9
#, python-format
msgid ""
"\n"
...
...
@@ -2715,7 +2719,7 @@ msgstr ""
" </br>\n"
" "
#: users/utils.py:7
4
#: users/utils.py:7
5
#, python-format
msgid ""
"\n"
...
...
@@ -2759,11 +2763,11 @@ msgstr ""
" </br>\n"
" "
#: users/utils.py:10
5
#: users/utils.py:10
6
msgid "SSH Key Reset"
msgstr "重置ssh密钥"
#: users/utils.py:10
7
#: users/utils.py:10
8
#, python-format
msgid ""
"\n"
...
...
@@ -2788,15 +2792,15 @@ msgstr ""
" </br>\n"
" "
#: users/utils.py:14
0
#: users/utils.py:14
1
msgid "User not exist"
msgstr "用户不存在"
#: users/utils.py:14
2
#: users/utils.py:14
3
msgid "Disabled or expired"
msgstr "禁用或失效"
#: users/utils.py:15
5
#: users/utils.py:15
6
msgid "Password or SSH public key invalid"
msgstr "密码或密钥不合法"
...
...
@@ -2816,7 +2820,7 @@ msgstr "用户组授权资产"
msgid "Please enable cookies and try again."
msgstr "设置你的浏览器支持cookie"
#: users/views/login.py:107 users/views/user.py:4
79 users/views/user.py:507
#: users/views/login.py:107 users/views/user.py:4
64 users/views/user.py:489
msgid "Otp code invalid"
msgstr "otp码认证失败"
...
...
@@ -2889,23 +2893,23 @@ msgstr "密码更新"
msgid "Public key update"
msgstr "密钥更新"
#: users/views/user.py:4
30
#: users/views/user.py:4
21
msgid "Password invalid"
msgstr "用户名或密码无效"
#: users/views/user.py:5
3
5
#: users/views/user.py:5
1
5
msgid "OTP enable success"
msgstr "OTP 绑定成功"
#: users/views/user.py:5
3
6
#: users/views/user.py:5
1
6
msgid "OTP enable success, return login page"
msgstr "OTP 绑定成功,返回到登录页面"
#: users/views/user.py:5
3
8
#: users/views/user.py:5
1
8
msgid "OTP disable success"
msgstr "OTP 解绑成功"
#: users/views/user.py:5
3
9
#: users/views/user.py:5
1
9
msgid "OTP disable success, return login page"
msgstr "OTP 解绑成功,返回登录页面"
...
...
apps/users/templates/users/user_detail.html
浏览文件 @
9ac7f26c
...
...
@@ -152,7 +152,7 @@
<td><span
class=
"pull-right"
>
<div
class=
"switch"
>
<div
class=
"onoffswitch"
>
<input
type=
"checkbox"
class=
"onoffswitch-checkbox"
{%
if
user_object.otp_force_enabled
%}
checked
{%
endif
%}{%
if
request.user =
=
user_object
%}
disabl
ed
{%
endif
%}
<input
type=
"checkbox"
class=
"onoffswitch-checkbox"
{%
if
user_object.otp_force_enabled
%}
check
ed
{%
endif
%}
id=
"force_enable_otp"
>
<label
class=
"onoffswitch-label"
for=
"force_enable_otp"
>
<span
class=
"onoffswitch-inner"
></span>
...
...
@@ -287,6 +287,11 @@ $(document).ready(function() {
});
})
.
on
(
'
click
'
,
'
#force_enable_otp
'
,
function
()
{
{
%
if
request
.
user
==
user_object
%
}
toastr
.
error
(
"
{% trans 'Goto profile page enable otp' %}
"
);
return
{
%
endif
%
}
var
the_url
=
"
{% url 'api-users:user-detail' pk=user_object.id %}
"
;
var
checked
=
$
(
this
).
prop
(
'
checked
'
);
var
otp_level
;
...
...
编辑
预览
Markdown
is supported
0%
请重试
或
添加新附件
.
添加附件
取消
You are about to add
0
people
to the discussion. Proceed with caution.
先完成此消息的编辑!
取消
想要评论请
注册
或
登录