index.html
5.4 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
105
106
107
108
109
110
111
112
113
114
115
116
117
<include file="public@header"/>
</head>
<body>
<div class="wrap js-check-wrap">
<ul class="nav nav-tabs">
<li class="active"><a href="{:url('comment/index')}">所有评论</a></li>
</ul>
<form method="post" class="js-ajax-form margin-top-20">
<div class="table-actions">
<!--<button class="btn btn-sm btn-primary js-ajax-submit" type="submit">{:lang('SORT')}</button>-->
<button class="btn btn-sm btn-success js-ajax-submit" type="submit"
data-action="{:url('comment/toggle',array('display'=>1))}" data-subcheck="true">通过
</button>
<button class="btn btn-sm btn-danger js-ajax-submit" type="submit"
data-action="{:url('comment/toggle',array('hide'=>1))}" data-subcheck="true">驳回
</button>
</div>
<php>$status=array('1'=>'通过','0'=>'待审核','2'=>'驳回');</php>
<table class="table table-hover table-bordered table-list">
<thead>
<tr>
<th width="50"><label><input type="checkbox" class="js-check-all" data-direction="x"
data-checklist="js-check-x"></label></th>
<!--<th width="50">{:lang('SORT')}</th>-->
<th width="100">ID</th>
<th width="100">昵称</th>
<th width="100">头像</th>
<th width="200">原文地址</th>
<th width="150">{:lang('STATUS')}</th>
<th width="300">评论内容</th>
<th width="80">{:lang('ACTIONS')}</th>
</tr>
</thead>
<tbody>
<foreach name="comment" item="vo">
<tr>
<td><input type="checkbox" class="js-check" data-yid="js-check-y" data-xid="js-check-x" name="ids[]"
value="{$vo.id}"></td>
<td>{$vo.id}</td>
<td>{$vo.nickname}</td>
<td>
<notempty name="vo.avatar">
<img width="25" height="25" src="{:cmf_get_image_url($vo.avatar)}"/>
<else/>
<img width="25" height="25" src="__TMPL__/public/assets/images/headicon.png"/>
</notempty>
</td>
<td>
<a href="{$vo.url}" target="_blank">{$vo.url}</a>
</td>
<td>
<switch name="vo.status">
<case value="0">
<span class="label label-default">
{$status[$vo['status']]}
</span>
</case>
<case value="1">
<span class="label label-success">
{$status[$vo['status']]}
</span>
</case>
<case value="2">
<span class="label label-default">
{$status[$vo['status']]}
</span>
</case>
<default/>
<span class="label label-default">
{$status[$vo['status']]}
</span>
</switch>
</td>
<td>
<p style="width:300px;overflow:hidden;white-space:nowrap;text-overflow:ellipsis;" title="{$vo.content}">{$vo.content}</p></td>
<td>
<a class="btn btn-xs btn-danger js-ajax-delete" href="{:url('comment/delete',array('id'=>$vo['id']))}" class="js-ajax-delete">
{:lang('DELETE')}
</a>
</td>
</tr>
</foreach>
</tbody>
<!--<tfoot>-->
<!--<tr>-->
<!--<th width="16">-->
<!--<label>-->
<!--<input type="checkbox" class="js-check-all" data-direction="x" data-checklist="js-check-x">-->
<!--</label>-->
<!--</th>-->
<!--<th width="50">{:lang('SORT')}</th>-->
<!--<th width="50">ID</th>-->
<!--<th>{:lang('NAME')}</th>-->
<!--<th>链接地址</th>-->
<!--<th width="50">{:lang('STATUS')}</th>-->
<!--<th width="120">{:lang('ACTIONS')}</th>-->
<!--</tr>-->
<!--</tfoot>-->
</table>
<!--<div class="table-actions">-->
<!--<button class="btn btn-sm btn-primary js-ajax-submit" type="submit">{:lang('SORT')}</button>-->
<!--<button class="btn btn-sm btn-success js-ajax-submit" type="submit"-->
<!--data-action="{:url('link/toggle',array('display'=>1))}" data-subcheck="true">{:lang('DISPLAY')}-->
<!--</button>-->
<!--<button class="btn btn-sm btn-danger js-ajax-submit" type="submit"-->
<!--data-action="{:url('link/toggle',array('hide'=>1))}" data-subcheck="true">{:lang('HIDE')}-->
<!--</button>-->
<!--</div>-->
</form>
</div>
<script src="__STATIC__/js/admin.js"></script>
</body>
</html>