action.phtml
5.9 KB
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
<div class="row">
<div style="height: 2px;"></div>
<div class="col-md-12">
<div class="widget box">
<div class="widget-content no-padding">
<div id="DataTables_Table_0_wrapper" class="dataTables_wrapper form-inline" role="grid">
<div class="row">
<div class="dataTables_header clearfix">
<div class="col-md-6" style="width:100%;">
<div class="tabbable tabbable-custom" style="float:inherit;width:70%;margin-bottom:0px;">
<ul class="nav nav-tabs">
<li <?php if(empty($this->dept_id)){?>class="active" <?php }?>>
<a href="/system/resource/action.html">ALL</a>
</li>
<?php
$deptData = Adminx_Models_Dept_Client::getDeptAll();
foreach($deptData as $key =>$val){
?>
<li <?php if($this->dept_id==$val['id']){?>class="active" <?php }?>>
<a href="/system/resource/action.html?dept_id=<?php echo $val['id'];?>"><?php echo $val['dept_name'];?></a>
</li>
<?php }?>
</ul>
</div>
<div class="dataTables_filter" style="float: right;">
<form action="/system/resource.html" method="get">
<div class="input-group">
<span class="input-group-addon" style="padding:0px;">
<button class="btn btn-xs btn-primary" style="height: 30px;">
<i class="icon-search"></i>
</button>
</span>
<input type="text" name="resource_name" placeholder="资源名称" class="form-control">
</div>
</form>
</div>
</div>
</div>
</div>
<table class="table table-striped table-bordered table-hover table-checkable table-responsive datatable dataTable" id="DataTables_Table_0" aria-describedby="DataTables_Table_0_info">
<thead>
<tr role="row">
<th class="checkbox-column sorting_disabled" role="columnheader" rowspan="1" colspan="1" aria-label="">
<input type="checkbox" class="uniform">
</th>
<th> 功能名称 </th>
<th> 归属资源 </th>
<th> 访问规则 </th>
<th> 管理</th>
</tr>
</thead>
<tbody role="alert" aria-live="polite" aria-relevant="all">
<?php foreach($this->resourceActionData as $key =>$val){ ?>
<tr>
<td class="checkbox-column sorting_1">
<div class="checker"><span><input type="checkbox" class="uniform"></span></div>
</td>
<td>
<?php echo $val['action_name'];?>
</td>
<td>
<?php
$parentResource = Adminx_Models_Resource_Client::getResourceByID($val['resource_id']);
if(!empty($parentResource)){
echo '<a href="/system/resource/action.html?dept_id='.$val['dept_id'].'&resource_id='.$val['resource_id'].'"><i class="icon-th-list"></i> '.$parentResource['resource_name'].'</a>';
}
?>
</td>
<td>
<?php echo $val['pattern'];?>
</td>
<td>
<ul class="table-controls">
<li>
<a href="/system/resource/edit.html?resource_id=<?php echo $val['id'];?>" class="bs-tooltip" title="Edit" data-original-title="Edit">
<i class="icon-pencil"></i>
</a>
</li>
<li>
<a href="/system/resource/del.html?resource_id=<?php echo $val['id'];?>" class="bs-tooltip" title="Delete" data-original-title="Delete">
<i class="icon-trash"></i>
</a>
</li>
</ul>
</td>
</tr>
<?php }?>
</tbody>
</table>
<div class="row">
<div class="dataTables_footer clearfix">
<?php $this->paging->view();?>
</div>
</div>
</div>
</div>
</div>
</div>
</div>