<%@ page language="java" contentType="text/html; charset=UTF-8"
    pageEncoding="UTF-8"%>
<%@ taglib prefix="c"  uri="http://java.sun.com/jsp/jstl/core" %>

<!-- 여기가 본 페이지이다 -->
<div class="row">
	<div class="col-lg-10">
		<div class="panel panel-default">
			<div class="panel-heading">
				<h5><i class="fa fa-desktop fa-fw"></i>IP 등록기</h5>
			</div>
			<div class="panel-body">
				<form class="form-inline" role="form" METHOD="get" action="IdcLineIPFirstWrite.lin">
					<div class="input-group" >
						<input type="text" name="Line_ip" value="${Line_ip[0] }">
						<input type="text" name="Line_ip" value="${Line_ip[1] }">
						<input type="text" name="Line_ip" value="${Line_ip[2] }">
						<input type="text" name="Line_ip" value="${Line_ip[3] }">~
						<input type="text" name="Line_ip" value="${Line_ip[4] }"><input  class="btn btn-outline btn-default" type="submit" value="예비등록">
					</div>
				</form>
				<div class="table-responsive col-lg-6" style="padding-left:0px">
					<c:if test="${isPrint }">	
			   			<form METHOD="POST" action="IdcLineIPWrite.lin">
							<table class="table table-bordered table-hover table-striped">
								<thead>
								</thead>
								<tbody>
									<c:forEach begin="${Line_ip[3] }" end="${Line_ip[4] }" varStatus="i">
										<tr>
											<c:if test="${IdcIPDBList[i.count-1].ip_able == 0 }">
											<td>
												<font color="red">사용중</font>
											</td>
											<td>
												<font color="red">${IdcIPDBList[i.count-1].ip1 }.${IdcIPDBList[i.count-1].ip2 }.${IdcIPDBList[i.count-1].ip3 }.${IdcIPDBList[i.count-1].ip4 }</font>
											</td>
											<td>
												사용불가
											</td>
											</c:if>
											<c:if test="${IdcIPDBList[i.count-1].ip_able != 0 }">
												<td>사용가능</td>
												<td>${Line_ip[0] }.${Line_ip[1] }.${Line_ip[2] }.${i.count+Line_ip[3]-1 }</td>
												<td>
													<input type="checkbox" name="IdcIPDBCheckList" value="${i.count-1 }">${i.count-1 }  사용하기
												</td>
											</c:if>
										</tr>
									</c:forEach>
								</tbody>
								<tfoot>
									<tr>
										<td colspan="3"><input class="btn btn-outline btn-default" type="submit" value="등록하기"></td>
									</tr>
								</tfoot>
							</table>
						</form>
					</c:if>
				</div>
				<!-- table-responsive -->
			</div>
			<!-- panel-body -->
		</div>
		<!-- panel panel-default -->
	</div>
	<!-- col-lg-12 -->
</div>
<!-- row -->
<!-- /#page-wrapper -->
