rent.php 2.24 KB
<? include $_SERVER["DOCUMENT_ROOT"] . "/common/classes/ApiBill.php"; ?>
<?
	$obj = new ApiBill($_REQUEST);
	
	$result = $obj->getRentList() ; 
	
	$requestList = $result["requestList"] ;
	$rentList = $result["rentList"] ;
	
// 	echo json_encode($rentList) ;
?>

<script>

	$(document).ready(function(){


	});

</script>


<div class="Wrap" style="height:100%">

<!-- 리스트 -->
<section>
	<? for($i=0; $i<sizeof($requestList); $i++) { 
			$row = $requestList[$i] ;
		?>
	<!-- 리스트 1개당 ul반복 -->
	<ul class="room_info jView" _no="<?= $row["no"] ?>" page="requestView.php">
		<li>
			<div class="date room_num">
				<p><?= $row["room_name"] ?></p><!-- 호실 -->
			</div>
		</li>
		<li>
			<p style="margin:20px 0px 7px 0px;"><?= $row["requestDate"] ?></p>
			<p class="price"><?= number_format($row["charge"]) ?></p><!-- 금액 -->
		</li>
		<li class="status_box">
			<div class="status logn_status rent_list brown">
				<a>비용청구</a><!-- 상태([임대료내역]비용청구일때는 class = 'brown') -->
			</div>
		</li>
		
		<div style="clear:both;"></div>
	</ul>
	<!-- 리스트 1개당 ul반복 -->
	<? } ?>
	
	<? for($i=0; $i<sizeof($rentList); $i++) { 
			$row = $rentList[$i] ;
		?>
	<!-- 리스트 1개당 ul반복 -->
	<ul class="room_info" page="rentView.php">
		<li>
			<div class="date room_num">
				<p><?= $row["name"] ?></p><!-- 호실 -->
			</div>
		</li>
		<li>
			<p style="margin:20px 0px 7px 0px;"><?= $row["monthDate"] ?></p>
			<p class="price"><?= number_format($row["payment_owner"]) ?></p><!-- 금액 -->
		</li>
		<li class="status_box" _no="<?= $row["NO"] ?>">
			<div class="status logn_status rent_list brown">
				<a>월세</a>
			</div>
		<? if($row["is_paid"] == 0) { ?>
			<div class="status logn_status rent_list long_orange">
				<a>연체</a>
			</div>
		<? } else if($row["is_paid"] == 1) {?>
			<div class="status logn_status rent_list long_orange">
				<a>납입</a>
			</div>
		<? } else if($row["is_paid"] == 2) {?>
			<div class="status logn_status rent_list brown">
				<a>청구중</a>
			</div>
		<? } ?>
		</li>
		
		
		<div style="clear:both;"></div>
	</ul>
	<!-- 리스트 1개당 ul반복 -->
	<? } ?>
</section>
<!-- 리스트 -->

</div>

<? include $_SERVER["DOCUMENT_ROOT"] . "/web/inc/php/footer.php" ?>