forked from tony903/Static-components
-
Notifications
You must be signed in to change notification settings - Fork 0
/
Copy pathlist-tree.html
357 lines (335 loc) · 11.8 KB
/
list-tree.html
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
118
119
120
121
122
123
124
125
126
127
128
129
130
131
132
133
134
135
136
137
138
139
140
141
142
143
144
145
146
147
148
149
150
151
152
153
154
155
156
157
158
159
160
161
162
163
164
165
166
167
168
169
170
171
172
173
174
175
176
177
178
179
180
181
182
183
184
185
186
187
188
189
190
191
192
193
194
195
196
197
198
199
200
201
202
203
204
205
206
207
208
209
210
211
212
213
214
215
216
217
218
219
220
221
222
223
224
225
226
227
228
229
230
231
232
233
234
235
236
237
238
239
240
241
242
243
244
245
246
247
248
249
250
251
252
253
254
255
256
257
258
259
260
261
262
263
264
265
266
267
268
269
270
271
272
273
274
275
276
277
278
279
280
281
282
283
284
285
286
287
288
289
290
291
292
293
294
295
296
297
298
299
300
301
302
303
304
305
306
307
308
309
310
311
312
313
314
315
316
317
318
319
320
321
322
323
324
325
326
327
328
329
330
331
332
333
334
335
336
337
338
339
340
341
342
343
344
345
346
347
348
349
350
351
352
353
354
355
356
357
<!doctype html>
<html>
<head>
<meta charset="UTF-8">
<meta name="renderer" content="webkit"/>
<meta http-equiv="X-UA-Compatible" content="IE=Edge,chrome=1"/>
<link rel="stylesheet" type="text/css" href="styles/list.css">
<link rel="stylesheet" type="text/css" href="styles/table.css">
<link rel="stylesheet" type="text/css" href="styles/tags.css">
<link rel="stylesheet" type="text/css" href="styles/btn.css">
<link rel="stylesheet" type="text/css" href="styles/pagination.css">
<link rel="stylesheet" type="text/css" href="styles/iconfont/iconfont.css">
<link rel="stylesheet" type="text/css" href="lib/zTree_v3/css/zTreeStyle/zTreeStyle.css">
<title>左侧树+右侧列表</title>
</head>
<body>
<div class="t-list-title">
<h2>组织管理</h2>
</div>
<!-- 左侧定宽,右侧自适应 -->
<div class="t-layout-ra">
<div class="ra-left">
<!-- 左侧内容 -->
<div class="ztree" id="treeDemo"></div>
<!-- 左侧内容 end -->
</div>
<div class="ra-right">
<div class="ra-rightinner">
<!-- 右侧内容 -->
<!-- 列表 -->
<div class="t-list">
<!-- 如不需要搜索,删除这部分 -->
<div class="t-list-search t-columns-4">
<!-- 检索字段 -->
<ul class="t-columns-group">
<li>
<!-- 必填项为label追加样式: necessary -->
<label for="fm01">
受理号码
</label>
<div>
<input id="fm01" type="text">
</div>
</li>
<li>
<label for="fm02">
开始时间
</label>
<div>
<input class="bg-date" id="fm02" type="text">
</div>
</li>
<li>
<label for="fm03">
结束时间
</label>
<div>
<input class="bg-date" id="fm03" type="text">
</div>
</li>
<li>
<label for="fm04">
用户姓名
</label>
<div>
<input id="fm04" type="text">
</div>
</li>
<li>
<label for="fm05">
下拉列表
</label>
<div>
<select name="" id="fm05">
<option value="">选项一</option>
<option value="">选项二</option>
<option value="">选项三</option>
</select>
</div>
</li>
<li>
<label for="fm06">
菜单树
</label>
<div>
<input class="bg-tree" id="fm06" type="text">
</div>
</li>
<!-- 时间组 -->
<li class="timegroup">
<label for="fm07">
起止日期
</label>
<div>
<div>
<input id="fm07" type="text" value="2016-02-18">
</div>
<span>~</span>
<div>
<input id="fm07" type="text" value="2016-03-01">
</div>
</div>
</li>
<!-- 默认隐藏的字段,显示 show 隐藏 hide -->
<li class="hide">
<label for="fm09">
警示字段
</label>
<div>
<input class="success" id="fm09" type="text" value="正确">
</div>
</li>
<li class="hide">
<label for="fm10">
警示字段
</label>
<div>
<input class="error" id="fm10" type="text" value="错误">
</div>
</li>
<li class="hide">
<label for="fm11">
警示字段
</label>
<div>
<input class="warning" id="fm11" type="text" value="警告">
</div>
</li>
<li>
<label>
</label>
<div>
<a href="#nogo" class="t-btn">
<i class="iconfont icon-chaxun"></i>
查询
</a>
</div>
</li>
</ul>
<!-- 展开/闭合按钮 -->
<span class="t-list-search-more">
<i class="iconfont icon-iconfontjiantou-copy-copy"></i>
<!-----------------------------------------------------------
---- 未展开状态:
---- <i class="iconfont icon-iconfontjiantou-copy-copy"></i>
---- 已展开状态:
---- <i class="iconfont icon-iconfontjiantou-copy"></i>
-------------------------------------------------------------
-->
</span>
</div>
<div class="t-list-btns">
<p>请求记录</p>
<span>(共124条记录)</span>
<a href="#nogo" title="刷新">
<i class="iconfont icon-shuaxin"></i>
</a>
<div>
<a class="t-btn t-btn-blue">新增</a>
<a class="t-btn t-btn-blue">修改</a>
<a class="t-btn t-btn-blue">按钮</a>
</div>
</div>
<div class="t-list-result">
<!-- 表格 -->
<table class="t-table">
<thead>
<tr>
<th>
<input type="checkbox">
</th>
<th>主要字段</th>
<th>类型</th>
<th>受理号码</th>
<th>用户姓名</th>
<th>用户级别</th>
<th>用户品牌</th>
<th>操作状态</th>
</tr>
</thead>
<tbody>
<tr>
<td>
<input type="checkbox">
</td>
<td>100231233</td>
<td>服务类 > 业务查询 > 消费信息查询</td>
<td>13723890766</td>
<td>苏三小</td>
<td>
<div class="t-stars">
<i class="iconfont icon-xingxing"></i>
<i class="iconfont icon-xingxing"></i>
<i class="iconfont icon-xingxing"></i>
<i class="iconfont icon-xingxing disabled"></i>
<i class="iconfont icon-xingxing disabled"></i>
</div>
</td>
<td>神州行</td>
<td>
<div class="t-tag-todo">
<span>未处理</span>
</div>
</td>
</tr>
<tr>
<td>
<input type="checkbox">
</td>
<td>100231233</td>
<td>服务类 > 业务查询 > 消费信息查询</td>
<td>13723890766</td>
<td>苏三小</td>
<td>
<div class="t-stars">
<i class="iconfont icon-xingxing"></i>
<i class="iconfont icon-xingxing"></i>
<i class="iconfont icon-xingxing"></i>
<i class="iconfont icon-xingxing"></i>
<i class="iconfont icon-xingxing disabled"></i>
</div>
</td>
<td>4G套餐</td>
<td>
<div class="t-tag-done">
<span>已处理</span>
</div>
</td>
</tr>
<tr>
<td>
<input type="checkbox">
</td>
<td>100231233</td>
<td>服务类 > 业务查询 > 消费信息查询</td>
<td>13723890766</td>
<td>苏三小</td>
<td>
<div class="t-stars">
<i class="iconfont icon-xingxing"></i>
<i class="iconfont icon-xingxing"></i>
<i class="iconfont icon-xingxing disabled"></i>
<i class="iconfont icon-xingxing disabled"></i>
<i class="iconfont icon-xingxing disabled"></i>
</div>
</td>
<td>神州行</td>
<td>
<div class="t-tag">
<span>默认的</span>
</div>
</td>
</tr>
</tbody>
</table>
<!-- 分页 -->
<div class="t-page">
<ul>
<li class="disabled"><span>上一页</span></li>
<li class="active"><span>1</span></li>
<li><a href="#">2</a></li>
<li><a href="#">3</a></li>
<li><span>...</span></li>
<li><a href="#">8</a></li>
<li><a href="#">9</a></li>
<li><a href="#">10</a></li>
<li><a href="#">下一页</a></li>
</ul>
<!-- 操作按钮
<div class="page-btns">
<a class="t-btn">导出</a>
<a class="t-btn">删除</a>
</div> -->
</div>
</div>
</div>
<!-- 右侧内容 end -->
</div>
</div>
</div>
<script type="text/javascript" src="lib/jquery/jquery.js"></script>
<!-- 左侧树 -->
<script type="text/javascript" src="lib/zTree_v3/js/jquery.ztree.core-3.5.min.js"></script>
<script type="text/javascript">
$(function(){
var setting = {
check: {
enable: true //是否启用 复选框
},
data: {
simpleData: {
enable: true
}
}
};
var zNodes =[
{ id:1, pId:0, name:"我的收藏", open:true,nocheck:true}, //pId 的 值就是上一级的id值
{ id:11, pId:1, name:"客服答疑技巧", open:true,nocheck:true},
{ id:111, pId:11, name:"业务咨询",nocheck:true},
{ id:112, pId:11, name:"客户投诉",nocheck:true},
{ id:113, pId:11, name:"其它来电",nocheck:true},
{ id:114, pId:11, name:"国际漫游",nocheck:true},
{ id:12, pId:1, name:"学习&提升", open:true,nocheck:true},
{ id:123, pId:12, name:"文件夹",nocheck:true},
{ id:121, pId:12, name:"TEST",nocheck:true},
{ id:13, pId:1, name:"班组工作",nocheck:true},
{ id:131, pId:13, name:"测试公告6",nocheck:true},
{ id:2, pId:0, name:"系统收藏", open:true,nocheck:true},
{ id:21, pId:2, name:"文化建设", open:true,nocheck:true},
{ id:211, pId:21, name:"班组建设",nocheck:true},
{ id:212, pId:21, name:"兴趣小组",nocheck:true},
{ id:22, pId:2, name:"话务技巧", open:true,nocheck:true},
{ id:221, pId:22, name:"10086",nocheck:true},
{ id:222, pId:22, name:"12580",nocheck:true}
];
$.fn.zTree.init($("#treeDemo"), setting, zNodes);
});
</script>
<!-- 展开/闭合控制,本段JS纯属实验,项目实施时请高手们替换掉 -->
<script type="text/javascript">
$(function(){
$('.t-list-search-more').click(function(){
if($('.t-columns-group li').hasClass('hide')) {
$('.t-columns-group li.hide').addClass('show').removeClass('hide');
$(this).children('i').addClass('icon-iconfontjiantou-copy').removeClass('icon-iconfontjiantou-copy-copy');
} else if($('.t-columns-group li').hasClass('show')) {
$('.t-columns-group li.show').addClass('hide').removeClass('show');
$(this).children('i').addClass('icon-iconfontjiantou-copy-copy').removeClass('icon-iconfontjiantou-copy');
}
})
});
</script>
</body>
</html>