perf: 删除管理用户错误提醒 (#11596)

Co-authored-by: feng <1304903146@qq.com>
pull/11602/head
fit2bot 2023-09-18 18:42:02 +08:00 committed by GitHub
parent 24ed57b98a
commit 018f1a0e8d
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23
5 changed files with 114 additions and 95 deletions

View File

@ -1,3 +1,3 @@
version https://git-lfs.github.com/spec/v1 version https://git-lfs.github.com/spec/v1
oid sha256:dabad720cb4047f55b1adcf56d312ed299bd1399d7d3db8a1645b97c893311da oid sha256:7c946abbc1980a2ab6066a26076e1fd0692c56e076673865ef0583a6c72f3b1b
size 159634 size 159755

View File

@ -8,7 +8,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: 2023-09-18 11:09+0800\n" "POT-Creation-Date: 2023-09-18 18:39+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"
@ -71,7 +71,7 @@ msgstr "動的コード"
msgid "Anonymous account" msgid "Anonymous account"
msgstr "匿名ユーザー" msgstr "匿名ユーザー"
#: accounts/const/account.py:25 users/models/user.py:743 #: accounts/const/account.py:25 users/models/user.py:744
msgid "Local" msgid "Local"
msgstr "ローカル" msgstr "ローカル"
@ -251,7 +251,7 @@ msgid "Version"
msgstr "バージョン" msgstr "バージョン"
#: accounts/models/account.py:56 accounts/serializers/account/account.py:204 #: accounts/models/account.py:56 accounts/serializers/account/account.py:204
#: users/models/user.py:845 #: users/models/user.py:846
msgid "Source" msgid "Source"
msgstr "ソース" msgstr "ソース"
@ -474,7 +474,7 @@ msgstr "最終ログイン日"
#: authentication/templates/authentication/_msg_different_city.html:9 #: authentication/templates/authentication/_msg_different_city.html:9
#: authentication/templates/authentication/_msg_oauth_bind.html:9 #: authentication/templates/authentication/_msg_oauth_bind.html:9
#: users/forms/profile.py:32 users/forms/profile.py:115 #: users/forms/profile.py:32 users/forms/profile.py:115
#: users/models/user.py:795 users/templates/users/_msg_user_created.html:12 #: users/models/user.py:796 users/templates/users/_msg_user_created.html:12
#: xpack/plugins/cloud/serializers/account_attrs.py:26 #: xpack/plugins/cloud/serializers/account_attrs.py:26
msgid "Username" msgid "Username"
msgstr "ユーザー名" msgstr "ユーザー名"
@ -536,7 +536,7 @@ msgstr "アカウントの確認"
#: terminal/models/component/storage.py:26 terminal/models/component/task.py:13 #: terminal/models/component/storage.py:26 terminal/models/component/task.py:13
#: terminal/models/component/terminal.py:84 users/forms/profile.py:33 #: terminal/models/component/terminal.py:84 users/forms/profile.py:33
#: users/models/group.py:13 users/models/preference.py:11 #: users/models/group.py:13 users/models/preference.py:11
#: users/models/user.py:797 xpack/plugins/cloud/models.py:32 #: users/models/user.py:798 xpack/plugins/cloud/models.py:32
#: xpack/plugins/cloud/models.py:273 xpack/plugins/cloud/serializers/task.py:68 #: xpack/plugins/cloud/models.py:273 xpack/plugins/cloud/serializers/task.py:68
msgid "Name" msgid "Name"
msgstr "名前" msgstr "名前"
@ -747,8 +747,8 @@ msgstr "ID"
#: terminal/notifications.py:205 terminal/serializers/command.py:16 #: terminal/notifications.py:205 terminal/serializers/command.py:16
#: terminal/templates/terminal/_msg_command_warning.html:6 #: terminal/templates/terminal/_msg_command_warning.html:6
#: terminal/templates/terminal/_msg_session_sharing.html:6 #: terminal/templates/terminal/_msg_session_sharing.html:6
#: tickets/models/comment.py:21 users/const.py:14 users/models/user.py:995 #: tickets/models/comment.py:21 users/const.py:14 users/models/user.py:996
#: users/models/user.py:1031 users/serializers/group.py:18 #: users/models/user.py:1032 users/serializers/group.py:18
msgid "User" msgid "User"
msgstr "ユーザー" msgstr "ユーザー"
@ -819,7 +819,7 @@ msgstr "关联平台,可以配置推送参数,如果不关联,则使用默
#: terminal/models/component/endpoint.py:24 #: terminal/models/component/endpoint.py:24
#: terminal/models/component/endpoint.py:104 #: terminal/models/component/endpoint.py:104
#: terminal/models/session/session.py:46 tickets/models/comment.py:32 #: terminal/models/session/session.py:46 tickets/models/comment.py:32
#: tickets/models/ticket/general.py:297 users/models/user.py:833 #: tickets/models/ticket/general.py:297 users/models/user.py:834
#: xpack/plugins/cloud/models.py:39 xpack/plugins/cloud/models.py:109 #: xpack/plugins/cloud/models.py:39 xpack/plugins/cloud/models.py:109
msgid "Comment" msgid "Comment"
msgstr "コメント" msgstr "コメント"
@ -1432,18 +1432,18 @@ msgstr "SSHパブリックキー"
#: assets/models/_user.py:28 assets/models/automations/base.py:114 #: assets/models/_user.py:28 assets/models/automations/base.py:114
#: assets/models/cmd_filter.py:41 assets/models/group.py:19 #: assets/models/cmd_filter.py:41 assets/models/group.py:19
#: audits/models.py:259 common/db/models.py:34 ops/models/base.py:54 #: audits/models.py:259 common/db/models.py:34 ops/models/base.py:54
#: ops/models/job.py:227 users/models/user.py:1032 #: ops/models/job.py:227 users/models/user.py:1033
msgid "Date created" msgid "Date created"
msgstr "作成された日付" msgstr "作成された日付"
#: assets/models/_user.py:29 assets/models/cmd_filter.py:42 #: assets/models/_user.py:29 assets/models/cmd_filter.py:42
#: common/db/models.py:35 users/models/user.py:854 #: common/db/models.py:35 users/models/user.py:855
msgid "Date updated" msgid "Date updated"
msgstr "更新日" msgstr "更新日"
#: assets/models/_user.py:30 assets/models/cmd_filter.py:44 #: assets/models/_user.py:30 assets/models/cmd_filter.py:44
#: assets/models/cmd_filter.py:91 assets/models/group.py:18 #: assets/models/cmd_filter.py:91 assets/models/group.py:18
#: common/db/models.py:32 users/models/user.py:840 #: common/db/models.py:32 users/models/user.py:841
#: users/serializers/group.py:29 #: users/serializers/group.py:29
msgid "Created by" msgid "Created by"
msgstr "によって作成された" msgstr "によって作成された"
@ -1637,7 +1637,7 @@ msgstr "確認済みの日付"
#: assets/models/cmd_filter.py:28 perms/models/asset_permission.py:61 #: assets/models/cmd_filter.py:28 perms/models/asset_permission.py:61
#: perms/serializers/permission.py:32 users/models/group.py:25 #: perms/serializers/permission.py:32 users/models/group.py:25
#: users/models/user.py:803 #: users/models/user.py:804
msgid "User group" msgid "User group"
msgstr "ユーザーグループ" msgstr "ユーザーグループ"
@ -1687,7 +1687,7 @@ msgstr "デフォルト"
msgid "Default asset group" msgid "Default asset group"
msgstr "デフォルトアセットグループ" msgstr "デフォルトアセットグループ"
#: assets/models/label.py:15 rbac/const.py:6 users/models/user.py:1017 #: assets/models/label.py:15 rbac/const.py:6 users/models/user.py:1018
msgid "System" msgid "System"
msgstr "システム" msgstr "システム"
@ -2332,7 +2332,7 @@ msgstr "ユーザーエージェント"
#: audits/models.py:192 audits/serializers.py:49 #: audits/models.py:192 audits/serializers.py:49
#: authentication/templates/authentication/_mfa_confirm_modal.html:14 #: authentication/templates/authentication/_mfa_confirm_modal.html:14
#: users/forms/profile.py:65 users/models/user.py:820 #: users/forms/profile.py:65 users/models/user.py:821
#: users/serializers/profile.py:102 #: users/serializers/profile.py:102
msgid "MFA" msgid "MFA"
msgstr "MFA" msgstr "MFA"
@ -2357,7 +2357,7 @@ msgstr "セッションID"
#: audits/models.py:260 authentication/models/connection_token.py:47 #: audits/models.py:260 authentication/models/connection_token.py:47
#: authentication/models/temp_token.py:13 perms/models/asset_permission.py:74 #: authentication/models/temp_token.py:13 perms/models/asset_permission.py:74
#: tickets/models/ticket/apply_application.py:31 #: tickets/models/ticket/apply_application.py:31
#: tickets/models/ticket/apply_asset.py:20 users/models/user.py:838 #: tickets/models/ticket/apply_asset.py:20 users/models/user.py:839
msgid "Date expired" msgid "Date expired"
msgstr "期限切れの日付" msgstr "期限切れの日付"
@ -2408,22 +2408,22 @@ msgstr "認証トークン"
#: audits/signal_handlers/login_log.py:38 authentication/notifications.py:73 #: audits/signal_handlers/login_log.py:38 authentication/notifications.py:73
#: authentication/views/login.py:77 authentication/views/wecom.py:159 #: authentication/views/login.py:77 authentication/views/wecom.py:159
#: notifications/backends/__init__.py:11 settings/serializers/auth/wecom.py:10 #: notifications/backends/__init__.py:11 settings/serializers/auth/wecom.py:10
#: users/models/user.py:750 users/models/user.py:855 #: users/models/user.py:751 users/models/user.py:856
msgid "WeCom" msgid "WeCom"
msgstr "企業微信" msgstr "企業微信"
#: audits/signal_handlers/login_log.py:39 authentication/views/feishu.py:122 #: audits/signal_handlers/login_log.py:39 authentication/views/feishu.py:122
#: authentication/views/login.py:89 notifications/backends/__init__.py:14 #: authentication/views/login.py:89 notifications/backends/__init__.py:14
#: settings/serializers/auth/feishu.py:10 #: settings/serializers/auth/feishu.py:10
#: settings/serializers/auth/feishu.py:13 users/models/user.py:752 #: settings/serializers/auth/feishu.py:13 users/models/user.py:753
#: users/models/user.py:857 #: users/models/user.py:858
msgid "FeiShu" msgid "FeiShu"
msgstr "本を飛ばす" msgstr "本を飛ばす"
#: audits/signal_handlers/login_log.py:40 authentication/views/dingtalk.py:159 #: audits/signal_handlers/login_log.py:40 authentication/views/dingtalk.py:159
#: authentication/views/login.py:83 notifications/backends/__init__.py:12 #: authentication/views/login.py:83 notifications/backends/__init__.py:12
#: settings/serializers/auth/dingtalk.py:10 users/models/user.py:751 #: settings/serializers/auth/dingtalk.py:10 users/models/user.py:752
#: users/models/user.py:856 #: users/models/user.py:857
msgid "DingTalk" msgid "DingTalk"
msgstr "DingTalk" msgstr "DingTalk"
@ -3013,7 +3013,7 @@ msgstr "期限切れです"
#: authentication/serializers/password_mfa.py:24 #: authentication/serializers/password_mfa.py:24
#: notifications/backends/__init__.py:10 settings/serializers/msg.py:22 #: notifications/backends/__init__.py:10 settings/serializers/msg.py:22
#: settings/serializers/msg.py:57 users/forms/profile.py:102 #: settings/serializers/msg.py:57 users/forms/profile.py:102
#: users/forms/profile.py:109 users/models/user.py:799 #: users/forms/profile.py:109 users/models/user.py:800
#: users/templates/users/forgot_password.html:117 #: users/templates/users/forgot_password.html:117
#: users/views/profile/reset.py:73 #: users/views/profile/reset.py:73
msgid "Email" msgid "Email"
@ -3051,13 +3051,13 @@ msgid "Show"
msgstr "表示" msgstr "表示"
#: authentication/templates/authentication/_access_key_modal.html:66 #: authentication/templates/authentication/_access_key_modal.html:66
#: users/models/user.py:645 users/serializers/profile.py:92 #: users/models/user.py:646 users/serializers/profile.py:92
#: users/templates/users/user_verify_mfa.html:36 #: users/templates/users/user_verify_mfa.html:36
msgid "Disable" msgid "Disable"
msgstr "無効化" msgstr "無効化"
#: authentication/templates/authentication/_access_key_modal.html:67 #: authentication/templates/authentication/_access_key_modal.html:67
#: users/models/user.py:646 users/serializers/profile.py:93 #: users/models/user.py:647 users/serializers/profile.py:93
#: users/templates/users/mfa_setting.html:26 #: users/templates/users/mfa_setting.html:26
#: users/templates/users/mfa_setting.html:68 #: users/templates/users/mfa_setting.html:68
msgid "Enable" msgid "Enable"
@ -3519,7 +3519,7 @@ msgstr "は破棄されます"
msgid "discard time" msgid "discard time"
msgstr "時間を捨てる" msgstr "時間を捨てる"
#: common/db/models.py:33 users/models/user.py:841 #: common/db/models.py:33 users/models/user.py:842
msgid "Updated by" msgid "Updated by"
msgstr "によって更新" msgstr "によって更新"
@ -4383,7 +4383,7 @@ msgid "Scope"
msgstr "スコープ" msgstr "スコープ"
#: rbac/models/role.py:46 rbac/models/rolebinding.py:52 #: rbac/models/role.py:46 rbac/models/rolebinding.py:52
#: users/models/user.py:807 #: users/models/user.py:808
msgid "Role" msgid "Role"
msgstr "ロール" msgstr "ロール"
@ -6142,9 +6142,11 @@ msgstr "一括作成非サポート"
msgid "Storage is invalid" msgid "Storage is invalid"
msgstr "ストレージが無効です" msgstr "ストレージが無効です"
#: terminal/models/applet/applet.py:30 xpack/plugins/license/models.py:88 #: terminal/models/applet/applet.py:30
msgid "Community edition" #, fuzzy
msgstr "コミュニティ版" #| msgid "Comment"
msgid "Community"
msgstr "コメント"
#: terminal/models/applet/applet.py:31 #: terminal/models/applet/applet.py:31
msgid "Enterprise" msgid "Enterprise"
@ -7259,7 +7261,7 @@ msgstr "公開鍵は古いものと同じであってはなりません。"
msgid "Not a valid ssh public key" msgid "Not a valid ssh public key"
msgstr "有効なssh公開鍵ではありません" msgstr "有効なssh公開鍵ではありません"
#: users/forms/profile.py:173 users/models/user.py:830 #: users/forms/profile.py:173 users/models/user.py:831
#: xpack/plugins/cloud/serializers/account_attrs.py:203 #: xpack/plugins/cloud/serializers/account_attrs.py:203
msgid "Public key" msgid "Public key"
msgstr "公開キー" msgstr "公開キー"
@ -7268,69 +7270,72 @@ msgstr "公開キー"
msgid "Preference" msgid "Preference"
msgstr "のようにふるまう" msgstr "のようにふるまう"
#: users/models/user.py:647 users/serializers/profile.py:94 #: users/models/user.py:648 users/serializers/profile.py:94
msgid "Force enable" msgid "Force enable"
msgstr "強制有効" msgstr "強制有効"
#: users/models/user.py:809 users/serializers/user.py:172 #: users/models/user.py:810 users/serializers/user.py:172
msgid "Is service account" msgid "Is service account"
msgstr "サービスアカウントです" msgstr "サービスアカウントです"
#: users/models/user.py:811 #: users/models/user.py:812
msgid "Avatar" msgid "Avatar"
msgstr "アバター" msgstr "アバター"
#: users/models/user.py:814 #: users/models/user.py:815
msgid "Wechat" msgid "Wechat"
msgstr "微信" msgstr "微信"
#: users/models/user.py:817 users/serializers/user.py:109 #: users/models/user.py:818 users/serializers/user.py:109
msgid "Phone" msgid "Phone"
msgstr "電話" msgstr "電話"
#: users/models/user.py:823 #: users/models/user.py:824
msgid "OTP secret key" msgid "OTP secret key"
msgstr "OTP 秘密" msgstr "OTP 秘密"
#: users/models/user.py:827 #: users/models/user.py:828
#: xpack/plugins/cloud/serializers/account_attrs.py:206 #: xpack/plugins/cloud/serializers/account_attrs.py:206
msgid "Private key" msgid "Private key"
msgstr "ssh秘密鍵" msgstr "ssh秘密鍵"
#: users/models/user.py:835 users/serializers/profile.py:125 #: users/models/user.py:836 users/serializers/profile.py:125
#: users/serializers/user.py:169 #: users/serializers/user.py:169
msgid "Is first login" msgid "Is first login"
msgstr "最初のログインです" msgstr "最初のログインです"
#: users/models/user.py:849 #: users/models/user.py:850
msgid "Date password last updated" msgid "Date password last updated"
msgstr "最終更新日パスワード" msgstr "最終更新日パスワード"
#: users/models/user.py:852 #: users/models/user.py:853
msgid "Need update password" msgid "Need update password"
msgstr "更新パスワードが必要" msgstr "更新パスワードが必要"
#: users/models/user.py:1002 msgid "Can not delete admin user"
msgstr "管理者ユーザーを削除できませんでした"
#: users/models/user.py:1003
msgid "Can invite user" msgid "Can invite user"
msgstr "ユーザーを招待できます" msgstr "ユーザーを招待できます"
#: users/models/user.py:1003 #: users/models/user.py:1004
msgid "Can remove user" msgid "Can remove user"
msgstr "ユーザーを削除できます" msgstr "ユーザーを削除できます"
#: users/models/user.py:1004 #: users/models/user.py:1005
msgid "Can match user" msgid "Can match user"
msgstr "ユーザーに一致できます" msgstr "ユーザーに一致できます"
#: users/models/user.py:1013 #: users/models/user.py:1014
msgid "Administrator" msgid "Administrator"
msgstr "管理者" msgstr "管理者"
#: users/models/user.py:1016 #: users/models/user.py:1017
msgid "Administrator is the super user of system" msgid "Administrator is the super user of system"
msgstr "管理者はシステムのスーパーユーザーです" msgstr "管理者はシステムのスーパーユーザーです"
#: users/models/user.py:1041 #: users/models/user.py:1042
msgid "User password history" msgid "User password history"
msgstr "ユーザーパスワード履歴" msgstr "ユーザーパスワード履歴"
@ -8430,5 +8435,9 @@ msgstr "エンタープライズプロフェッショナル版"
msgid "Ultimate edition" msgid "Ultimate edition"
msgstr "エンタープライズ・フラッグシップ・エディション" msgstr "エンタープライズ・フラッグシップ・エディション"
#: xpack/plugins/license/models.py:88
msgid "Community edition"
msgstr "コミュニティ版"
#~ msgid "Enterprise edition" #~ msgid "Enterprise edition"
#~ msgstr "エンタープライズ基本版" #~ msgstr "エンタープライズ基本版"

View File

@ -1,3 +1,3 @@
version https://git-lfs.github.com/spec/v1 version https://git-lfs.github.com/spec/v1
oid sha256:eb3a2ba311fb282955641818231c0d54f1484c38a923dc5734ab38318c850e0c oid sha256:65c1a53a660bde080fd5b4fa9f21a038365fc5d10492d9c017ba3a5a414c4196
size 130384 size 130454

View File

@ -7,7 +7,7 @@ msgid ""
msgstr "" msgstr ""
"Project-Id-Version: JumpServer 0.3.3\n" "Project-Id-Version: JumpServer 0.3.3\n"
"Report-Msgid-Bugs-To: \n" "Report-Msgid-Bugs-To: \n"
"POT-Creation-Date: 2023-09-18 11:09+0800\n" "POT-Creation-Date: 2023-09-18 18:39+0800\n"
"PO-Revision-Date: 2021-05-20 10:54+0800\n" "PO-Revision-Date: 2021-05-20 10:54+0800\n"
"Last-Translator: ibuler <ibuler@qq.com>\n" "Last-Translator: ibuler <ibuler@qq.com>\n"
"Language-Team: JumpServer team<ibuler@qq.com>\n" "Language-Team: JumpServer team<ibuler@qq.com>\n"
@ -70,7 +70,7 @@ msgstr "同名账号"
msgid "Anonymous account" msgid "Anonymous account"
msgstr "匿名账号" msgstr "匿名账号"
#: accounts/const/account.py:25 users/models/user.py:743 #: accounts/const/account.py:25 users/models/user.py:744
msgid "Local" msgid "Local"
msgstr "数据库" msgstr "数据库"
@ -250,7 +250,7 @@ msgid "Version"
msgstr "版本" msgstr "版本"
#: accounts/models/account.py:56 accounts/serializers/account/account.py:204 #: accounts/models/account.py:56 accounts/serializers/account/account.py:204
#: users/models/user.py:845 #: users/models/user.py:846
msgid "Source" msgid "Source"
msgstr "来源" msgstr "来源"
@ -473,7 +473,7 @@ msgstr "最后登录日期"
#: authentication/templates/authentication/_msg_different_city.html:9 #: authentication/templates/authentication/_msg_different_city.html:9
#: authentication/templates/authentication/_msg_oauth_bind.html:9 #: authentication/templates/authentication/_msg_oauth_bind.html:9
#: users/forms/profile.py:32 users/forms/profile.py:115 #: users/forms/profile.py:32 users/forms/profile.py:115
#: users/models/user.py:795 users/templates/users/_msg_user_created.html:12 #: users/models/user.py:796 users/templates/users/_msg_user_created.html:12
#: xpack/plugins/cloud/serializers/account_attrs.py:26 #: xpack/plugins/cloud/serializers/account_attrs.py:26
msgid "Username" msgid "Username"
msgstr "用户名" msgstr "用户名"
@ -535,7 +535,7 @@ msgstr "账号验证"
#: terminal/models/component/storage.py:26 terminal/models/component/task.py:13 #: terminal/models/component/storage.py:26 terminal/models/component/task.py:13
#: terminal/models/component/terminal.py:84 users/forms/profile.py:33 #: terminal/models/component/terminal.py:84 users/forms/profile.py:33
#: users/models/group.py:13 users/models/preference.py:11 #: users/models/group.py:13 users/models/preference.py:11
#: users/models/user.py:797 xpack/plugins/cloud/models.py:32 #: users/models/user.py:798 xpack/plugins/cloud/models.py:32
#: xpack/plugins/cloud/models.py:273 xpack/plugins/cloud/serializers/task.py:68 #: xpack/plugins/cloud/models.py:273 xpack/plugins/cloud/serializers/task.py:68
msgid "Name" msgid "Name"
msgstr "名称" msgstr "名称"
@ -745,8 +745,8 @@ msgstr "ID"
#: terminal/notifications.py:205 terminal/serializers/command.py:16 #: terminal/notifications.py:205 terminal/serializers/command.py:16
#: terminal/templates/terminal/_msg_command_warning.html:6 #: terminal/templates/terminal/_msg_command_warning.html:6
#: terminal/templates/terminal/_msg_session_sharing.html:6 #: terminal/templates/terminal/_msg_session_sharing.html:6
#: tickets/models/comment.py:21 users/const.py:14 users/models/user.py:995 #: tickets/models/comment.py:21 users/const.py:14 users/models/user.py:996
#: users/models/user.py:1031 users/serializers/group.py:18 #: users/models/user.py:1032 users/serializers/group.py:18
msgid "User" msgid "User"
msgstr "用户" msgstr "用户"
@ -817,7 +817,7 @@ msgstr "关联平台,可配置推送参数,如果不关联,将使用默认
#: terminal/models/component/endpoint.py:24 #: terminal/models/component/endpoint.py:24
#: terminal/models/component/endpoint.py:104 #: terminal/models/component/endpoint.py:104
#: terminal/models/session/session.py:46 tickets/models/comment.py:32 #: terminal/models/session/session.py:46 tickets/models/comment.py:32
#: tickets/models/ticket/general.py:297 users/models/user.py:833 #: tickets/models/ticket/general.py:297 users/models/user.py:834
#: xpack/plugins/cloud/models.py:39 xpack/plugins/cloud/models.py:109 #: xpack/plugins/cloud/models.py:39 xpack/plugins/cloud/models.py:109
msgid "Comment" msgid "Comment"
msgstr "备注" msgstr "备注"
@ -1429,18 +1429,18 @@ msgstr "SSH公钥"
#: assets/models/_user.py:28 assets/models/automations/base.py:114 #: assets/models/_user.py:28 assets/models/automations/base.py:114
#: assets/models/cmd_filter.py:41 assets/models/group.py:19 #: assets/models/cmd_filter.py:41 assets/models/group.py:19
#: audits/models.py:259 common/db/models.py:34 ops/models/base.py:54 #: audits/models.py:259 common/db/models.py:34 ops/models/base.py:54
#: ops/models/job.py:227 users/models/user.py:1032 #: ops/models/job.py:227 users/models/user.py:1033
msgid "Date created" msgid "Date created"
msgstr "创建日期" msgstr "创建日期"
#: assets/models/_user.py:29 assets/models/cmd_filter.py:42 #: assets/models/_user.py:29 assets/models/cmd_filter.py:42
#: common/db/models.py:35 users/models/user.py:854 #: common/db/models.py:35 users/models/user.py:855
msgid "Date updated" msgid "Date updated"
msgstr "更新日期" msgstr "更新日期"
#: assets/models/_user.py:30 assets/models/cmd_filter.py:44 #: assets/models/_user.py:30 assets/models/cmd_filter.py:44
#: assets/models/cmd_filter.py:91 assets/models/group.py:18 #: assets/models/cmd_filter.py:91 assets/models/group.py:18
#: common/db/models.py:32 users/models/user.py:840 #: common/db/models.py:32 users/models/user.py:841
#: users/serializers/group.py:29 #: users/serializers/group.py:29
msgid "Created by" msgid "Created by"
msgstr "创建者" msgstr "创建者"
@ -1634,7 +1634,7 @@ msgstr "校验日期"
#: assets/models/cmd_filter.py:28 perms/models/asset_permission.py:61 #: assets/models/cmd_filter.py:28 perms/models/asset_permission.py:61
#: perms/serializers/permission.py:32 users/models/group.py:25 #: perms/serializers/permission.py:32 users/models/group.py:25
#: users/models/user.py:803 #: users/models/user.py:804
msgid "User group" msgid "User group"
msgstr "用户组" msgstr "用户组"
@ -1684,7 +1684,7 @@ msgstr "默认"
msgid "Default asset group" msgid "Default asset group"
msgstr "默认资产组" msgstr "默认资产组"
#: assets/models/label.py:15 rbac/const.py:6 users/models/user.py:1017 #: assets/models/label.py:15 rbac/const.py:6 users/models/user.py:1018
msgid "System" msgid "System"
msgstr "系统" msgstr "系统"
@ -2320,7 +2320,7 @@ msgstr "用户代理"
#: audits/models.py:192 audits/serializers.py:49 #: audits/models.py:192 audits/serializers.py:49
#: authentication/templates/authentication/_mfa_confirm_modal.html:14 #: authentication/templates/authentication/_mfa_confirm_modal.html:14
#: users/forms/profile.py:65 users/models/user.py:820 #: users/forms/profile.py:65 users/models/user.py:821
#: users/serializers/profile.py:102 #: users/serializers/profile.py:102
msgid "MFA" msgid "MFA"
msgstr "MFA" msgstr "MFA"
@ -2345,7 +2345,7 @@ msgstr "会话标识"
#: audits/models.py:260 authentication/models/connection_token.py:47 #: audits/models.py:260 authentication/models/connection_token.py:47
#: authentication/models/temp_token.py:13 perms/models/asset_permission.py:74 #: authentication/models/temp_token.py:13 perms/models/asset_permission.py:74
#: tickets/models/ticket/apply_application.py:31 #: tickets/models/ticket/apply_application.py:31
#: tickets/models/ticket/apply_asset.py:20 users/models/user.py:838 #: tickets/models/ticket/apply_asset.py:20 users/models/user.py:839
msgid "Date expired" msgid "Date expired"
msgstr "失效日期" msgstr "失效日期"
@ -2396,22 +2396,22 @@ msgstr "认证令牌"
#: audits/signal_handlers/login_log.py:38 authentication/notifications.py:73 #: audits/signal_handlers/login_log.py:38 authentication/notifications.py:73
#: authentication/views/login.py:77 authentication/views/wecom.py:159 #: authentication/views/login.py:77 authentication/views/wecom.py:159
#: notifications/backends/__init__.py:11 settings/serializers/auth/wecom.py:10 #: notifications/backends/__init__.py:11 settings/serializers/auth/wecom.py:10
#: users/models/user.py:750 users/models/user.py:855 #: users/models/user.py:751 users/models/user.py:856
msgid "WeCom" msgid "WeCom"
msgstr "企业微信" msgstr "企业微信"
#: audits/signal_handlers/login_log.py:39 authentication/views/feishu.py:122 #: audits/signal_handlers/login_log.py:39 authentication/views/feishu.py:122
#: authentication/views/login.py:89 notifications/backends/__init__.py:14 #: authentication/views/login.py:89 notifications/backends/__init__.py:14
#: settings/serializers/auth/feishu.py:10 #: settings/serializers/auth/feishu.py:10
#: settings/serializers/auth/feishu.py:13 users/models/user.py:752 #: settings/serializers/auth/feishu.py:13 users/models/user.py:753
#: users/models/user.py:857 #: users/models/user.py:858
msgid "FeiShu" msgid "FeiShu"
msgstr "飞书" msgstr "飞书"
#: audits/signal_handlers/login_log.py:40 authentication/views/dingtalk.py:159 #: audits/signal_handlers/login_log.py:40 authentication/views/dingtalk.py:159
#: authentication/views/login.py:83 notifications/backends/__init__.py:12 #: authentication/views/login.py:83 notifications/backends/__init__.py:12
#: settings/serializers/auth/dingtalk.py:10 users/models/user.py:751 #: settings/serializers/auth/dingtalk.py:10 users/models/user.py:752
#: users/models/user.py:856 #: users/models/user.py:857
msgid "DingTalk" msgid "DingTalk"
msgstr "钉钉" msgstr "钉钉"
@ -2985,7 +2985,7 @@ msgstr "已过期"
#: authentication/serializers/password_mfa.py:24 #: authentication/serializers/password_mfa.py:24
#: notifications/backends/__init__.py:10 settings/serializers/msg.py:22 #: notifications/backends/__init__.py:10 settings/serializers/msg.py:22
#: settings/serializers/msg.py:57 users/forms/profile.py:102 #: settings/serializers/msg.py:57 users/forms/profile.py:102
#: users/forms/profile.py:109 users/models/user.py:799 #: users/forms/profile.py:109 users/models/user.py:800
#: users/templates/users/forgot_password.html:117 #: users/templates/users/forgot_password.html:117
#: users/views/profile/reset.py:73 #: users/views/profile/reset.py:73
msgid "Email" msgid "Email"
@ -3023,13 +3023,13 @@ msgid "Show"
msgstr "显示" msgstr "显示"
#: authentication/templates/authentication/_access_key_modal.html:66 #: authentication/templates/authentication/_access_key_modal.html:66
#: users/models/user.py:645 users/serializers/profile.py:92 #: users/models/user.py:646 users/serializers/profile.py:92
#: users/templates/users/user_verify_mfa.html:36 #: users/templates/users/user_verify_mfa.html:36
msgid "Disable" msgid "Disable"
msgstr "禁用" msgstr "禁用"
#: authentication/templates/authentication/_access_key_modal.html:67 #: authentication/templates/authentication/_access_key_modal.html:67
#: users/models/user.py:646 users/serializers/profile.py:93 #: users/models/user.py:647 users/serializers/profile.py:93
#: users/templates/users/mfa_setting.html:26 #: users/templates/users/mfa_setting.html:26
#: users/templates/users/mfa_setting.html:68 #: users/templates/users/mfa_setting.html:68
msgid "Enable" msgid "Enable"
@ -3479,7 +3479,7 @@ msgstr "忽略的"
msgid "discard time" msgid "discard time"
msgstr "忽略时间" msgstr "忽略时间"
#: common/db/models.py:33 users/models/user.py:841 #: common/db/models.py:33 users/models/user.py:842
msgid "Updated by" msgid "Updated by"
msgstr "最后更新者" msgstr "最后更新者"
@ -4335,7 +4335,7 @@ msgid "Scope"
msgstr "范围" msgstr "范围"
#: rbac/models/role.py:46 rbac/models/rolebinding.py:52 #: rbac/models/role.py:46 rbac/models/rolebinding.py:52
#: users/models/user.py:807 #: users/models/user.py:808
msgid "Role" msgid "Role"
msgstr "角色" msgstr "角色"
@ -6055,9 +6055,11 @@ msgstr "不支持批量创建"
msgid "Storage is invalid" msgid "Storage is invalid"
msgstr "存储无效" msgstr "存储无效"
#: terminal/models/applet/applet.py:30 xpack/plugins/license/models.py:88 #: terminal/models/applet/applet.py:30
msgid "Community edition" #, fuzzy
msgstr "社区版" #| msgid "Comment"
msgid "Community"
msgstr "备注"
#: terminal/models/applet/applet.py:31 #: terminal/models/applet/applet.py:31
msgid "Enterprise" msgid "Enterprise"
@ -7160,7 +7162,7 @@ msgstr "不能和原来的密钥相同"
msgid "Not a valid ssh public key" msgid "Not a valid ssh public key"
msgstr "SSH密钥不合法" msgstr "SSH密钥不合法"
#: users/forms/profile.py:173 users/models/user.py:830 #: users/forms/profile.py:173 users/models/user.py:831
#: xpack/plugins/cloud/serializers/account_attrs.py:203 #: xpack/plugins/cloud/serializers/account_attrs.py:203
msgid "Public key" msgid "Public key"
msgstr "SSH公钥" msgstr "SSH公钥"
@ -7169,69 +7171,72 @@ msgstr "SSH公钥"
msgid "Preference" msgid "Preference"
msgstr "爱好" msgstr "爱好"
#: users/models/user.py:647 users/serializers/profile.py:94 #: users/models/user.py:648 users/serializers/profile.py:94
msgid "Force enable" msgid "Force enable"
msgstr "强制启用" msgstr "强制启用"
#: users/models/user.py:809 users/serializers/user.py:172 #: users/models/user.py:810 users/serializers/user.py:172
msgid "Is service account" msgid "Is service account"
msgstr "服务账号" msgstr "服务账号"
#: users/models/user.py:811 #: users/models/user.py:812
msgid "Avatar" msgid "Avatar"
msgstr "头像" msgstr "头像"
#: users/models/user.py:814 #: users/models/user.py:815
msgid "Wechat" msgid "Wechat"
msgstr "微信" msgstr "微信"
#: users/models/user.py:817 users/serializers/user.py:109 #: users/models/user.py:818 users/serializers/user.py:109
msgid "Phone" msgid "Phone"
msgstr "手机" msgstr "手机"
#: users/models/user.py:823 #: users/models/user.py:824
msgid "OTP secret key" msgid "OTP secret key"
msgstr "OTP 密钥" msgstr "OTP 密钥"
#: users/models/user.py:827 #: users/models/user.py:828
#: xpack/plugins/cloud/serializers/account_attrs.py:206 #: xpack/plugins/cloud/serializers/account_attrs.py:206
msgid "Private key" msgid "Private key"
msgstr "ssh私钥" msgstr "ssh私钥"
#: users/models/user.py:835 users/serializers/profile.py:125 #: users/models/user.py:836 users/serializers/profile.py:125
#: users/serializers/user.py:169 #: users/serializers/user.py:169
msgid "Is first login" msgid "Is first login"
msgstr "首次登录" msgstr "首次登录"
#: users/models/user.py:849 #: users/models/user.py:850
msgid "Date password last updated" msgid "Date password last updated"
msgstr "最后更新密码日期" msgstr "最后更新密码日期"
#: users/models/user.py:852 #: users/models/user.py:853
msgid "Need update password" msgid "Need update password"
msgstr "需要更新密码" msgstr "需要更新密码"
#: users/models/user.py:1002 msgid "Can not delete admin user"
msgstr "无法删除管理员用户"
#: users/models/user.py:1003
msgid "Can invite user" msgid "Can invite user"
msgstr "可以邀请用户" msgstr "可以邀请用户"
#: users/models/user.py:1003 #: users/models/user.py:1004
msgid "Can remove user" msgid "Can remove user"
msgstr "可以移除用户" msgstr "可以移除用户"
#: users/models/user.py:1004 #: users/models/user.py:1005
msgid "Can match user" msgid "Can match user"
msgstr "可以匹配用户" msgstr "可以匹配用户"
#: users/models/user.py:1013 #: users/models/user.py:1014
msgid "Administrator" msgid "Administrator"
msgstr "管理员" msgstr "管理员"
#: users/models/user.py:1016 #: users/models/user.py:1017
msgid "Administrator is the super user of system" msgid "Administrator is the super user of system"
msgstr "Administrator是初始的超级管理员" msgstr "Administrator是初始的超级管理员"
#: users/models/user.py:1041 #: users/models/user.py:1042
msgid "User password history" msgid "User password history"
msgstr "用户密码历史" msgstr "用户密码历史"
@ -8314,3 +8319,7 @@ msgstr "企业专业版"
#: xpack/plugins/license/models.py:86 #: xpack/plugins/license/models.py:86
msgid "Ultimate edition" msgid "Ultimate edition"
msgstr "企业旗舰版" msgstr "企业旗舰版"
#: xpack/plugins/license/models.py:88
msgid "Community edition"
msgstr "社区版"

View File

@ -18,6 +18,7 @@ from django.shortcuts import reverse
from django.utils import timezone from django.utils import timezone
from django.utils.module_loading import import_string from django.utils.module_loading import import_string
from django.utils.translation import gettext_lazy as _ from django.utils.translation import gettext_lazy as _
from rest_framework.exceptions import PermissionDenied
from common.db import fields, models as jms_models from common.db import fields, models as jms_models
from common.utils import ( from common.utils import (
@ -973,7 +974,7 @@ class User(AuthMixin, TokenMixin, RoleMixin, MFAMixin, JSONFilterMixin, Abstract
def delete(self, using=None, keep_parents=False): def delete(self, using=None, keep_parents=False):
if self.pk == 1 or self.username == 'admin': if self.pk == 1 or self.username == 'admin':
return raise PermissionDenied(_('Can not delete admin user'))
return super(User, self).delete(using=using, keep_parents=keep_parents) return super(User, self).delete(using=using, keep_parents=keep_parents)
@classmethod @classmethod