jumpserver/templates/jperm/perm_log_offline.html

127 lines
5.9 KiB
HTML
Raw Normal View History

2015-04-01 10:58:10 +00:00
{% extends 'base.html' %}
{% load mytags %}
{% block content %}
{% include 'nav_cat_bar.html' %}
<div class="wrapper wrapper-content animated fadeInRight">
<div class="row">
<div class="col-lg-12">
<div class="ibox float-e-margins">
<div id="ibox-content" class="ibox-title">
<h5> 用户权限申请详细信息列表 </h5>
<div class="ibox-tools">
<a class="collapse-link">
<i class="fa fa-chevron-up"></i>
</a>
<a class="dropdown-toggle" data-toggle="dropdown" href="#">
<i class="fa fa-wrench"></i>
</a>
<ul class="dropdown-menu dropdown-user">
<li><a href="#">未启用 1</a>
</li>
<li><a href="#">未启用 2</a>
</li>
</ul>
<a class="close-link">
<i class="fa fa-times"></i>
</a>
</div>
</div>
<div class="ibox-content">
<div class="panel-options">
<ul class="nav nav-tabs">
<li><a href="/jperm/apply_show/online/" class="text-center"><i class="fa fa-laptop"></i> 未审批 </a></li>
<li class="active"><a href="/jperm/apply_show/offline/" class="text-center"><i class="fa fa-bar-chart-o"></i> 已审批 </a></li>
<li style="float: right">
<form id="search_form" method="get" action="" class="pull-right mail-search">
<div class="input-group">
<input type="text" class="form-control input-sm" id="search_input" name="keyword" placeholder="Search">
<input type="text" style="display: none">
<div class="input-group-btn">
2015-04-04 04:47:07 +00:00
<button id='search_btn' type="button" class="btn btn-sm btn-primary" onclick="apply_search()">
2015-04-01 10:58:10 +00:00
Search
</button>
</div>
</div>
</form>
</li>
</ul>
</div>
<br/>
<div class="tab-content">
<table class="table table-striped table-bordered table-hover ">
<thead>
<tr>
<th class="text-center"> 申请人 </th>
<th class="text-center"> 所属部门 </th>
<th class="text-center"> 申请主机组 </th>
<th class="text-center"> 申请主机 </th>
<th class="text-center"> 批准人 </th>
<th class="text-center"> 申请时间 </th>
<th class="text-center"> 备注 </th>
2015-04-04 04:47:07 +00:00
<th class="text-center"> 详情 </th>
2015-04-01 10:58:10 +00:00
</tr>
</thead>
<tbody>
{% for post in contacts.object_list %}
<tr class="gradeX">
<td class="text-center" id="username"> {{ post.applyer }} </td>
<td class="text-center" id="dept"> {{ post.dept }} </td>
2015-04-07 11:15:45 +00:00
<td class="text-center" id="ip"> {{ post.bisgroup|ast_to_list }} </td>
<td class="text-center" id="remote_ip">{{ post.asset|ast_to_list }} </td>
2015-04-01 10:58:10 +00:00
<td class="text-center" id="approver"> {{ post.approver }} </td>
<td class="text-center" id="start_time"> {{ post.date_add|date:"Y-m-d H:i:s"}} </td>
<td class="text-center" id=""> {{ post.comment }} </td>
2015-04-04 04:47:07 +00:00
<td class="text-center" data-editable='false'>
<a value="/jperm/apply_info/?uuid={{ post.uuid }}" class="iframe btn btn-xs btn-primary">详情</a>
</td>
2015-04-01 10:58:10 +00:00
</tr>
{% endfor %}
</tbody>
</table>
<div class="row">
<div class="col-sm-6">
</div>
{% include 'paginator.html' %}
</div>
</div>
</div>
</div>
</div>
</div>
</div>
2015-04-04 04:47:07 +00:00
<script>
$(".iframe").on('click', function(){
var url= $(this).attr("value");
$.layer({
type: 2,
title: '权限申请详情',
maxmin: true,
shift: 'top',
border: [2, 0.3, '#1AB394'],
shade: [0.5, '#000000'],
shadeClose: true,
area : ['800px' , '600px'],
iframe: {src: url}
});
});
function apply_search(){
$.ajax({
type: "GET",
url: "/jperm/apply_search/?env=offline",
data: $("#search_form").serialize(),
success: function (data) {
$(".tab-content").html(data);
}
});
}
$("#search_input").keydown(function(e){
if(e.keyCode==13){
apply_search()
}
})
</script>
2015-04-01 10:58:10 +00:00
{% endblock %}