<%@ include file="/includes.jsp" %>
<%@ taglib uri="http://java.sun.com/jsp/jstl/fmt" prefix="fmt" %>
<html>
<head>
	<title>Referral Statistics Detailed Report</title>
	<link rel="icon" href="../../images/emdt.ico" type="image/x-icon" >
	<link rel="shortcut icon" href="../../images/emdt.ico" type="image/x-icon" >
	<link rel="stylesheet" href="../referrals/css/reports.css" type="text/css"
		media="screen, print">
	
	<style media="print" type="text/css">
	.noPrint {
		visibility: hidden;
		display: none;
	}
	</style>
</head>
<body>

<h2>Referral Statistics Summary  Report</h2>

<b>Date range:  <c:out value="${fromDate}"/> - <c:out value="${toDate}"/></b>
<br/>
<br/>
Total Number of referrals waiting for response: <c:out value="${detailReportListDTO.numOfReferralsWaitingResp}"/><br/>
Total Number of referrals completed: <c:out value="${detailReportListDTO.numOfReferralsCompleted}"/><br/>
Total Number of referrals waiting for acknowledgement: <c:out value="${detailReportListDTO.numOfReferralsWaitingAck}"/><br/>
Total Number of referrals: <c:out value="${detailReportListDTO.numOfReferrals}"/><br/>
Maximum time for referral: <c:out value="${detailReportListDTO.timeTakenForReferral}"/> days<br/>
<br/>
<br/>
<table border="1" class="report">

	<tr align="center">
		<th>Hospital Name</th>
		<th>Number of referrals waiting for response</th>
		<th>Number of referrals waiting for acknowledgement</th>
		<th>Number of referrals completed</th>
		<th>Number of referrals</th>
	</tr>
	<c:forEach var="hospital" items="${detailReportListDTO.hospitals}" varStatus="line">
		<tr>
			<td>
				<c:out value="${hospital.hospitalName}"/>
			</td>
			<td align="right">
				<c:out value="${hospital.numOfReferralsWaitingResp}"/>
			</td>
			<td align="right">
				<c:out value="${hospital.numOfReferralsWaitingAck}"/>
			</td>
			<td align="right">
				<c:out value="${hospital.numOfReferralsCompleted}"/>
			</td>
			<td align="right">
				<c:out value="${hospital.numOfReferrals}"/>
			</td>
		</tr>
	</c:forEach>
</table>
<br/>

<br/>
<br/>

<div id="navigation"  class="navButtonBar noPrint">
	
	<%String str1 = (String)request.getAttribute("module");%>
	<c:set var="str" value="<%=str1%>"/>

	<c:choose>
		<c:when test="${str eq 'referral'}">
			<img src="../images/16x16/arrow_undo.png" />&nbsp;Back to: <a href="../referrals/referralsReportMenu.jsp">Reports main menu</a> &nbsp; &gt; &nbsp;<a href="../referrals/referralsSummaryDetailedReport.jsp?module=referral" class="noPrint"> This report settings</a>
		</c:when>
		<c:otherwise>
			<a href="../emdt/referralsSummaryReport.jsp" class="noPrint"><img src="../images/16x16/arrow_undo.png" />&nbsp;&nbsp;Return to previous screen</a>
		</c:otherwise>
	</c:choose>

	&nbsp; &nbsp; &nbsp;
	
	<a href="javascript:print();"><img border="0" alt="Printer icon" src="../images/16x16/printer.png"> Print</a>

	&nbsp; &nbsp; &nbsp;
	
</div>



</body>
</html>