diff --git a/templates/jasset/asset_list.html b/templates/jasset/asset_list.html
index 1dc6b5aab..92de964e0 100644
--- a/templates/jasset/asset_list.html
+++ b/templates/jasset/asset_list.html
@@ -119,7 +119,7 @@
|
- {{ asset.hostname|default_if_none:"" }} |
+ {{ asset.hostname|default_if_none:"" }} |
{{ asset.ip|default_if_none:"" }} |
{{ asset.idc.name|default_if_none:"" }} |
{{ asset.group.all|group_str2 }} |
@@ -175,6 +175,7 @@
var url='/jlog/get_role_name/?id=' + $(this).attr('value');
var href = $(this).attr('href');
var new_url = '/jlog/web_terminal/?id=' + $(this).attr('value') + '&role=';
+ var hostname = $(this).closest('tr').find('.hostname')[0].innerHTML;
$.ajax({
type: 'GET',
url: url,
@@ -182,21 +183,22 @@
success: function(data){
var dataArray = data.split(',');
if (dataArray.length == 1 && data != 'error'){
+ var title = 'Jumpserver Web Terminal' + ' '+ hostname +'';
layer.open({
- type: 2,
- title: 'Jumpserver Web Terminal',
- maxmin: true,
- shade: false,
- area: ['628px', '452px'],
- content: new_url
- });
+ type: 2,
+ title: title,
+ maxmin: true,
+ shade: false,
+ area: ['628px', '452px'],
+ content: new_url
+ });
//window.open(new_url + data, '', 'location=no, resizeable=no, height=410, width=625, top=89px, left=99px,toolbar=no,menubar=no,scrollbars=auto,status=no');
} else if (dataArray.length == '1' && data == 'error'){
layer.alert('没有授权角色')
} else {
aUrl = '';
$.each(dataArray, function(index, value){
- aUrl += '' + value + ' '
+ aUrl += '' + value + ' '
});
layer.alert(aUrl, {
skin: 'layui-layer-molv',
@@ -211,11 +213,13 @@
});
});
- function windowOpen(aTab){
- var new_url = aTab.href;
+ function windowOpen(a){
+ var new_url = $(a).attr('href');
+ var hostname = $(a).attr('value');
+ var title = 'Jumpserver Web Terminal - ' + ' '+ hostname +'';
layer.open({
type: 2,
- title: 'Jumpserver Web Terminal',
+ title: title,
maxmin: true,
area: ['628px', '452px'],
shade: false,
@@ -261,7 +265,6 @@
});
-
$('#asset_del').click(function () {
var asset_id_all = getIDall();
if (asset_id_all == ''){
diff --git a/templates/jlog/log_offline.html b/templates/jlog/log_offline.html
index ecf791b7a..012a58bc7 100644
--- a/templates/jlog/log_offline.html
+++ b/templates/jlog/log_offline.html
@@ -98,6 +98,7 @@
+ ID |
用户名 |
登录主机 |
来源IP |
@@ -114,15 +115,16 @@
{% for post in contacts.object_list %}
- {{ post.user }} |
- {{ post.host }} |
- {{ post.remote_ip }} |
+ {{ post.id }} |
+ {{ post.user }} |
+ {{ post.host }} |
+ {{ post.remote_ip }} |
{% ifnotequal session_role_id 0 %}
命令统计 |
{% endifnotequal %}
回放 |
- {{ post.start_time|date:"Y-m-d H:i:s"}} |
- {{ post.end_time|date:"Y-m-d H:i:s" }} |
+ {{ post.start_time|date:"Y-m-d H:i:s"}} |
+ {{ post.end_time|date:"Y-m-d H:i:s" }} |
{% endfor %}
@@ -142,20 +144,36 @@