<%@ page language="java" pageEncoding="UTF-8"%> 
<%@ taglib uri="/WEB-INF/tld/struts-html.tld" prefix="html"%>
<%@ taglib uri="/WEB-INF/tld/struts-bean.tld" prefix="bean"%>
<%@ taglib uri="/WEB-INF/tld/extremecomponents.tld" prefix="ec" %>
<%@ page isELIgnored="false" %> 
<html:html locale="true">
	<head>
		<title>开启关闭时间列表</title>
		<link href="${pageContext.request.contextPath}/css/extremecomponents.css" rel="stylesheet" type="text/css"> 
		<link href="${pageContext.request.contextPath}/css/style.css" rel="stylesheet" type="text/css">
		<script src="${pageContext.request.contextPath}/js/select.js"></script> 
		<script language="javascript">
			function doSubmit() {
				if(!hasChecked(subForm.id)) {
					alert("请选择需要删除的开启关闭时间");
					return false;
				} else {
					if(!confirm("确实要删除这些记录吗?")) {
						return false;
					} else {
						subForm.submit();
					}
				}
			}
		</script>
	</head>
	<body>
		<form name="subForm" method="post" action="${pageContext.request.contextPath}/callTimeLimitAction.do?method=deleteCallTimeLimit">
			<table width="98%" align="center" border="0" cellpadding="4" cellspacing="1" class="list_detail">
		        <tr align="center"> 
					<td align="center" width="100%" class="title_td">
  						<div class="title_font">开启关闭时间列表</div>
					</td>
		        </tr>
		        <tr>
		   			<td>
		   				<input type="button" name="addProduct" value="新增" class="btn_style" onclick="window.location.href='${pageContext.request.contextPath}/callTimeLimitManage/add.jsp';"/>
		                <br>
		                <input type="checkbox" name="checkbox2" onclick="checkboxselect(document.subForm.id, document.subForm.checkbox2.checked)" style="border:0px"/>
		                  全选<input type="button" name="delall" value="删除所选" class="btn_style" onclick="return doSubmit();"/>
		   			</td>
		   		</tr>
		        <tr> 
		          <td height="74">
				    <ec:table
						items="callTimeLimitList" 
						action="${pageContext.request.contextPath}/callTimeLimitAction.do?method=getCallTimeLimitList"
						imagePath = "${pageContext.request.contextPath}/images/ec/*.gif"
						title = ""
					    cellpadding = "1"
					    width = "100%"
					    locale = "zh_CN"
					    rowsDisplayed = "30"
					    sortable="false"
					    var = "map"
					    filterable = "true"
					    form="subForm">
						<ec:row highlightRow="true">  
							<ec:column property="checkbox" title="选择" width="30" sortable="false" viewsAllowed="html" style="width: 50px;text-align:center"> 
			           			<script>
	                                <!--
	                                document.write('<input type="checkbox" name="id" value="${map.id}" style="border:0px"/> ');
	                                //-->
	                           	</script>   
			       			</ec:column>
			       			<ec:column property="num" title="序号" style="text-align:center"/>
							<ec:column property="limitType" title="类型" style="text-align:center"/>
							<ec:column property="startTime" title="开始时间" style="text-align:center"/>
							<ec:column property="endTime" title="结束时间" style="text-align:center"/>
							<ec:column property="操作" filterable="false" style="text-align:center">
			                	<a href="${pageContext.request.contextPath}/callTimeLimitAction.do?method=getCallTimeLimit&id=${map.id}"><img src="${pageContext.request.contextPath}/images/ec/edit.gif" border="0" alt="修改"></a>
			                </ec:column>
			             </ec:row>
					</ec:table>
		          </td>
		      </tr>
		    </table>
		</form>
	</body>
</html:html>