From 2950613b69e369e08c92920b451c268867ee8657 Mon Sep 17 00:00:00 2001 From: wojiushixiaobai <296015668@qq.com> Date: Wed, 20 Jun 2018 15:58:01 +0800 Subject: [PATCH] =?UTF-8?q?=E4=BF=AE=E6=94=B9=E6=8F=90=E7=A4=BA=E6=96=87?= =?UTF-8?q?=E5=AD=97?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- apps/assets/templates/assets/admin_user_list.html | 5 +---- apps/assets/templates/assets/domain_list.html | 11 ++++++++--- apps/static/js/jumpserver.js | 9 +++++---- 3 files changed, 14 insertions(+), 11 deletions(-) diff --git a/apps/assets/templates/assets/admin_user_list.html b/apps/assets/templates/assets/admin_user_list.html index bcb40fb29..15a870800 100644 --- a/apps/assets/templates/assets/admin_user_list.html +++ b/apps/assets/templates/assets/admin_user_list.html @@ -5,7 +5,7 @@ {% block help_message %}
- 管理用户是服务器的root,或拥有 NOPASSWD: ALL sudo权限的用户,Jumpserver使用该用户来 `推送系统用户`、`获取资产硬件信息`等。 + 管理用户是资产(被控服务器)上的root,或拥有 NOPASSWD: ALL sudo权限的用户,Jumpserver使用该用户来 `推送系统用户`、`获取资产硬件信息`等。 Windows或其它硬件可以随意设置一个
{% endblock %} @@ -107,6 +107,3 @@ $(document).ready(function(){ }); {% endblock %} - - - diff --git a/apps/assets/templates/assets/domain_list.html b/apps/assets/templates/assets/domain_list.html index 926c4bbc3..a4042d57e 100644 --- a/apps/assets/templates/assets/domain_list.html +++ b/apps/assets/templates/assets/domain_list.html @@ -1,6 +1,14 @@ {% extends '_base_list.html' %} {% load i18n static %} {% block table_search %}{% endblock %} + +{% block help_message %} +
+ 网域功能是为了解决部分环境(如:混合云)无法直接连接而新增的功能,原理是通过网关服务器进行跳转登 +录。 +
+{% endblock %} + {% block table_container %}
{% trans "Create domain" %} @@ -69,6 +77,3 @@ $(document).ready(function(){ }); {% endblock %} - - - diff --git a/apps/static/js/jumpserver.js b/apps/static/js/jumpserver.js index 461455085..2b5b74110 100644 --- a/apps/static/js/jumpserver.js +++ b/apps/static/js/jumpserver.js @@ -173,14 +173,14 @@ function APIUpdateAttr(props) { } if (typeof props.success === 'function') { return props.success(data); - } + } }).fail(function(jqXHR, textStatus, errorThrown) { if (flash_message) { toastr.error(fail_message); } if (typeof props.error === 'function') { return props.error(jqXHR.responseText); - } + } }); // return true; } @@ -198,7 +198,8 @@ function objectDelete(obj, name, url, redirectTo) { } }; var fail = function() { - swal("错误", "删除"+"[ "+name+" ]"+"遇到错误", "error"); + // swal("错误", "删除"+"[ "+name+" ]"+"遇到错误", "error"); + swal("错误", "[ "+name+" ]"+"正在被资产使用中,请先解除资产绑定", "error"); }; APIUpdateAttr({ url: url, @@ -219,7 +220,7 @@ function objectDelete(obj, name, url, redirectTo) { confirmButtonText: '确认', closeOnConfirm: true, }, function () { - doDelete() + doDelete() }); }