<%@ page language="java" contentType="text/html; charset=UTF-8"   pageEncoding="UTF-8"%>
<%@ taglib prefix="c"  uri="http://java.sun.com/jsp/jstl/core" %>
<% pageContext.setAttribute("phpurl",request.getScheme()+"://"+request.getServerName()); %>
<c:set var="member" value="${sessionScope.member}" />
<c:if test="${not empty member}">
  <c:set var="member_code" value="${member.getId()}" />
</c:if>
<!-- 고객 리스트 -->
<!-- 여기가 본 페이지이다 -->
<div class="row">
	<div class="col-lg-12">
		<div class="panel panel-default">
			<div class="panel-heading"><h4><i class="fa fa-desktop fa-fw"></i> 고객 리스트</h4></div>
			<div class="panel-body">
				<div class="row"></div>
				<!-- row -->
				<div class="table-responsive">
					<table class="table table-bordered table-hover table-striped">
						<thead>
							<tr>
								<td>고객코드</td>
								<td>고객명</td>
								<td>리셀러</td>
								<td>연락처1</td>
								<td>연락처2</td>
								<td>E-mail</td>
								<td>E-mail</td>
								<td>등록일</td>
								<td>갱신일</td>
								<!-- <td>비고</td>-->
								<td>청구서</td>
							<tr>
						</thead>
						<tbody>
							<c:forEach items="${ClientList }" var="temp" >
								<tr>
												<td><a href=/serviceDetail.sev?client_code=${temp.client_code }>${temp.client_code }</a></td>
												<td><!-- <a href=/IdcClientDBList.cli?searchOption=client_name&searchContent=${temp.client_name }>--><a href=/serviceDetail.sev?client_code=${temp.client_code }>${temp.client_name }</a></td>
												<td>${temp.client_reseller }</td>
												<td>${temp.client_phone1 }</td>
												<td>${temp.client_phone2 }</td>
												<td>${temp.client_email1 }</td>
												<td>${temp.client_email2 }</td>
												<td>${temp.client_receive_date }</td>
												<td>${temp.client_renew_date }</td>
												<!-- <td>${temp.client_note }</td>-->
												<td><a href="/IdcDepositNonPaymentList.dep?searchContent=${temp.client_name }">청구서 확인</a></td>
								</tr>
								<tr>
										<td>비고</td>
										<td colspan=9><c:import url="${phpurl}/dbms/client/update_form?client_code=${temp.client_code}&member_code=${member_code}" /></td>
								</tr>
							</c:forEach>
						</tbody>
					</table>
				</div>
				<!-- table-responsive -->
			</div>
			<!-- panel-body -->
		</div>
		<!-- panel panel-default -->
	</div>
	<!-- col-lg-12 -->
</div>
<!-- row -->
<!-- /#page-wrapper -->
<!-- 고객 리스트 -->

<!-- 서비스 리스트 -->
<!-- 여기가 본 페이지이다 -->
<div class="row">
	<div class="col-lg-12">
		<div class="panel panel-default">
			<div class="panel-heading">
				<h4><i class="fa fa-desktop fa-fw"></i> 서비스 리스트 </h4>
			</div>
			<div class="panel-body">
				<div class="row">
				</div>
				<!-- row -->
	   			<div class="table-responsive">
					<table class="table table-bordered table-hover table-striped">
						<thead>	
							<tr>
								<!-- <td>번호</td>							
								<td>상태</td> 
								<td>고객코드</td>-->
								<td>서비스 코드</td>
								<td>고객명</td>
								<td>라인 종류</td>
								<td>장비 번호</td>
								<td>SW</td>
								<td>IP</td>
								<td>OS</td>
								<td>신청일</td>
								<td>결제일</td>
								<td>서비스 금액</td>
								<td>미지급 금액</td>							
								<td>담당자</td>
								<td>메모</td>
							</tr>
						</thead>
						<tbody>
							<c:forEach items="${ServiceList}" var="dto">
								<tr>
									<!-- <td>${dto.service_num}</td>								
									<td>${dto.service_status}</td>
									<td>${dto.client_code}</td> -->
									<td><a href="serviceDetail.sev?client_code=${dto.client_code}">${dto.service_code}</a></td>
									<td>${dto.client_name}</td>
									<td>${dto.service_line}</td>
									<td>${dto.server_code}</td>
									<td>${dto.service_sw}</td>
									<td>${dto.service_ip}</td>
									<td>${dto.service_os}</td>
									<td>${dto.service_request_date}</td>
									<td>${dto.service_payment_date}</td>
									<td>${dto.service_amount}</td>
									<td>${dto.service_nonpayment}</td>
									<td>${dto.service_manager}</td>
									<td>${dto.service_note}</td>								
								</tr>
							</c:forEach>
						</tbody>
						<tfoot>
						</tfoot>
					</table>
				</div>
				<!-- table-responsive -->
			</div>
			<!-- panel-body -->
		</div>
		<!-- panel panel-default -->
	</div>
	<!-- col-lg-12 -->
</div>
<!-- row -->
<!-- /#page-wrapper -->
<!-- 서비스 리스트 -->

<!-- 서버 목록조회 -->
<!-- 여기가 본 페이지이다 -->
<div class="row">
	<div class="col-lg-12">
		<div class="panel panel-default">
			<div class="panel-heading">
				<h4><i class="fa fa-desktop fa-fw"></i> 서버 목록 조회</h4>
			</div>
			<div class="panel-body">
				<div class="row">
				</div>
				<!-- row -->
	   			<div class="table-responsive">
					<table class="table table-bordered table-hover table-striped">
						<thead>
							<tr>
								<td>가용여부</td>
								<td>장비번호</td>
								<td>구분</td>
								<td>스펙</td>
								<td>cpu모델명</td>
								<td>장비 사양</td>
								<td>브랜드</td>
								<td>위치정보</td>
								<td>포맷보류</td>
								<td>입고일</td>
								<td>출고일</td>
								<td>비고</td>
								<td>폐기일</td>
							</tr>
						</thead>
						<tbody>
							<c:forEach items="${ServerList }" var="dto">
								<tr>
									<td><a href="serverRead.ser?server_num=${dto.server_num}">${dto.server_use_status}</a></td>
									<td><a href="serverRead.ser?server_num=${dto.server_num}">${dto.server_code}</a></td>
									<td><a href="serverRead.ser?server_num=${dto.server_num}">${dto.server_process}</a></td>
									<td><a href="serverRead.ser?server_num=${dto.server_num}">${dto.server_spec}</a></td>
									<td><a href="serverRead.ser?server_num=${dto.server_num}">${dto.server_cpuname}</a></td>
									<td><a href="serverRead.ser?server_num=${dto.server_num}">${dto.server_spec} ${dto.server_ram} ${dto.server_hdd}</a></td>
									<td><a href="serverRead.ser?server_num=${dto.server_num}">${dto.server_brand}</a></td>
									<td><a href="serverRead.ser?server_num=${dto.server_num}">${dto.server_location}</a></td>
									<td><a href="serverRead.ser?server_num=${dto.server_num}">${dto.server_fomat_date}</a></td>
									<td><a href="serverRead.ser?server_num=${dto.server_num}">${dto.server_recieve_date}</a></td>
									<td><a href="serverRead.ser?server_num=${dto.server_num}">${dto.server_release_date}</a></td>
									<td><a href="serverRead.ser?server_num=${dto.server_num}">${dto.server_note}</a></td>
									<td><a href="serverRead.ser?server_num=${dto.server_num}">${dto.server_disuse_date}</a></td>
								</tr>
							</c:forEach>
						</tbody>
						<tfoot>
						</tfoot>
					</table>
				</div>
				<!-- table-responsive -->
			</div>
			<!-- panel-body -->
		</div>
		<!-- panel panel-default -->
	</div>
	<!-- col-lg-12 -->
</div>
<!-- row -->
<!-- /#page-wrapper -->
<!-- 서버 목록 조회 -->

<!-- IP 리스트 -->
<!-- 여기가 본 페이지이다 -->
<div class="row">
	<div class="col-lg-12">
		<div class="panel panel-default">
			<div class="panel-heading">
				<h4><i class="fa fa-desktop fa-fw"></i> IP 리스트</h4>
			</div>
			<div class="panel-body">
				<div class="row">
				</div>
				<!-- row -->
	   			<div class="table-responsive">
					<table class="table table-bordered table-hover table-striped">
						<thead>
						<tr>
								<td>회선명</td>
								<td>회선구분</td>
								<td>사용자</td>
								<td>IP</td>
								<td>가용여부</td>
								<td>해지사유</td>
								<td>차단</td>
								<td>차단해제일</td>
								<td>메모</td>
							</tr>
						</thead>
						<tbody>
							<c:forEach items="${IPList }" var="temp">
								<tr>
									<td>${temp.ip_user }</td>
									<td>${temp.ip_case2 }</td>
									<td>${temp.ip_user }</td>
									<td>${temp.ip_address }</td>
									<td>
										<c:if test="${temp.ip_able==1 }">
											사용가능
										</c:if>
										<c:if test="${temp.ip_able==0 }">
											사용불가 OR 사용중
										</c:if>
									</td>
									<td>${temp.cancel_reason }</td>
									<td>${temp.block }</td>
									<td>${temp.block_endday }</td>
									<td>${temp.ip_note }</td>
								</tr>
							</c:forEach>
						</tbody>
						<tfoot>
						</tfoot>
					</table>
				</div>
				<!-- table-responsive -->
			</div>
			<!-- panel-body -->
		</div>
		<!-- panel panel-default -->
	</div>
	<!-- col-lg-12 -->
</div>
<!-- row -->
<!-- /#page-wrapper -->
<!-- IP 리스트 -->
