<html xmlns:th="http://www.thymeleaf.org">
<head>
	<title>私塾家</title>
	<script th:include="sys/common/metaCSS" th:remove="tag"></script>
	<script th:include="sys/common/metaJS" th:remove="tag"></script>
	<script src="sys/js/My97DatePicker/WdatePicker.js" th:src="@{/static/sys/js/My97DatePicker/WdatePicker.js}"></script>
</head>
<style>
	.tablelink{margin-right:10px;}
	.stylecss{
		color: red;
	}
	.select_width{
		width: 70px;
	}
	.date_width{
		width: 100px;
	}
</style>
<body>
<div class="place">
	<span>位置：</span>
	<ul class="placeul">
		<li><a href="#">用户管理中心</a></li>
		<li><a th:href="@{/sys/usercenter/vipStudentList.html}">学生列表</a></li>
	</ul>
</div>
<div class="rightinfo">
	<form id="seachform" th:action="@{/sys/usercenter/vipStudentList.html}" method="post">
		<ul class="seachform">
			<li>
				<label>名字/家长/学校/年级：</label>
				<input name="LIKE_value" type="text" class="scinput" th:value="${search.get('LIKE_value')}"/>
			</li>
			<li>
				<label>用户昵称/电话号码：</label>
				<input name="LIKE_value2" type="text" class="scinput" th:value="${search.get('LIKE_value2')}"/>
			</li>
			<li>
				<label>开始时间</label>
				<input type="text" id="beginDate" autocomplete="off" name="beginDate"  onclick="WdatePicker({maxDate:'#F{$dp.$D(\'endDate\')}'})" th:value="${search.get('beginDate') }" class="scinput date_width " placeholder="开始时间">
			</li>


			<li>
				<label>结束时间</label>
				<input type="text" id="endDate" autocomplete="off" name="endDate"  onclick="WdatePicker({minDate:'#F{$dp.$D(\'beginDate\')}'})" th:value="${search.get('endDate') }" class="scinput date_width" placeholder="结束时间">
			</li>
			<li>
				<label>&nbsp;</label>
				<input type="button" class="scbtn" value="查询" />
			</li>
		</ul>
	</form>
	<ul><li><input type="button" id="button" class="scbtn" value="导出" /></li></ul>

	<table class="tablelist">
		<thead>
		<tr>
			<th>用户昵称</th>
			<th>电话号码</th>
			<th>创建时间</th>
			<th style="width: 70%;">
				<table style="width: 100%;">
					<thead><tr>
						<th style="width:10%;">名字</th>
						<th style="width:10%;">头像</th>
						<th style="width:10%;">性别</th>
						<th style="width:10%;">电话</th>
						<th style="width:15%;">学校</th>
						<th style="width:15%;">校区</th>
						<th style="width:10%;">年级</th>
						<th style="width:10%;">家长</th>
						<th style="width:10%;">激活时间</th>
					</tr></thead>
				</table></th>
		</tr>
		</thead>
		<tbody>
		<tr th:each="item2:${list}" >
			<td th:text="${item2.user_name}" ></td>
			<td th:text="${item2.mobile}" ></td>
			<td th:text="${item2.create_time}" ></td>
			<td style="width: 70%;">
				<table style="width: 100%;">
					<tbody>
					<tr th:each="item:${item2.childList}" th:if="${item2.childList}">
						<td th:text="${item.child_name}"  style="width:10%;"></td>
						<td  class="imgtd"  style="width:10%;">
							<img th:if="${not #lists.isEmpty(item.img_url)}" th:src="${imgUrl}+''+${item.img_url}" style="width: 50px;height: 50px;" />
						</td>
						<td th:text="${item.sex}"  style="width:10%;"></td>
						<td th:text="${item.phone}"  style="width:10%;"></td>
						<td th:text="${item.school}"  style="width:15%;"></td>
						<td th:text="${item.league_name}"  style="width:15%;"></td>
						<td th:text="${item.grade}"  style="width:10%;"></td>
						<td th:text="${item.parent_name}"  style="width:10%;"></td>
						<td th:text="${item.activate_time}"  style="width:10%;"></td>
					</tr>
					</tbody>
				</table>
			</td>
		</tr>
		</tbody>
	</table>
	<!--分页-->
	<div class="pagin">
		<div class="message">共<i class="blue">[[${page.rowCnt}]]</i>条记录，当前显示第&nbsp;<i class="blue">[[${page.pageNo }]]&nbsp;</i>页</div>
		<div th:utext='${listNavigatHtml}' th:remove="tag" ></div>
	</div>
</div>
</body>
<script type="text/javascript">
	$("#button").on('click',function(){
		document.getElementById("seachform").action = "[[${sysUrl}]]/sys/usercenter/exportVipData";
		$("#seachform").submit();
		window.setTimeout(function(){
			document.getElementById("seachform").action = "[[${sysUrl}]]/sys/usercenter/vipStudentList.html";
		},3000);

	});
</script>
</html>