<script type="text/javascript" language="JavaScript"
	src="../scripts/ESR-Script.js"></script>
<%@ taglib uri="http://struts.apache.org/tags-bean-el" prefix="bean-el"%>
<%@ taglib uri="http://struts.apache.org/tags-html" prefix="html-el"%>
<%@ taglib uri="/tags/esr-core" prefix="esrcore"%>
<%@ taglib uri="http://java.sun.com/jsp/jstl/core" prefix="c"%>
<%@ taglib uri="/tags/fw" prefix="fw"%>
<%@ taglib uri="/tags/valuelist" prefix="vlh"%>

<table width="100%" border="0" cellpadding="0" cellspacing="0"
	role="presentation">


<TR><TD colspan="2">
<TABLE class=moduleShellTableHead cellSpacing=0 cellPadding=0 width="100%" border=0>
<TBODY>
<TR>
<TD class=moduleBlueBox>&nbsp;</TD>
<TD class=moduleHeadline width="75%">Community Care Determination</TD>
<TD class=moduleHeadline width="23%"><html-el:link  title="${vcDeterminationText}" action="vcDeterminationHistory.do?methodName=VC Determination History">Community Care Determination History</html-el:link></TD></TR></TBODY></TABLE></TD></TR>

	<tr valign="top">
		<td width="50%">

			<table width="100%" border="0" cellpadding="0" cellspacing="0"
				role="presentation" class="moduleShell">

				<!-- VC Determination Start -->
				<tr>
					<td>
						<table width="100%"  cellpadding="0" cellspacing="0"
							class="moduleShell" role="presentation">
							<tr>
								<td>
									<table width="100%" border="0" cellpadding="1" cellspacing="0"
										class="moduleShellTableHead" role="presentation">
										<tr>
											<td class="moduleBlueBox">&nbsp;</td>
											<td colspan="1" class="moduleHeadline">Veteran Information</td>
											
										</tr>
									</table>
								</td>
							</tr>

							<tr>
								<td>
									<table width="100%" border="0" cellspacing="0" cellpadding="0"
										class="moduleShellTableBody" role="presentation">
										<tr>
											<td width="30%" class="label">Residential Address Status (BAI):</td>
											<td class="value">
												<c:choose>
												<c:when test="${commsLogForm.address != null && commsLogForm.address.badAddressReason != null}">
													${commsLogForm.address.badAddressReason.code}
												</c:when>
												<c:otherwise>
													N/A
												</c:otherwise>
												</c:choose>
											</td>
											<td class="label"></td>
											<td class="label"></td>
										</tr>
		
										<tr>
											<td width="30%" class="label">Address Accuracy:</td>
											<td colspan="3" class="value">
												<c:choose>
													<c:when test="${commsLogForm.geocodeTransmit != null}">
														${commsLogForm.geocodeTransmit.addressMatchType}
													</c:when>
													<c:otherwise>
														N/A
													</c:otherwise>
												</c:choose>
											</td>
											
										</tr>
		
										<tr>
											<td class="label">&nbsp;</td>
											<td colspan="3" class=value>
											<c:if test="${commsLogForm.address != null}">
												<c:if test="${commsLogForm.address.internalLine1 != null}">
													${commsLogForm.address.internalLine1}<br />
												</c:if>
												<c:if test="${commsLogForm.address.internalLine2 != null}">
													${commsLogForm.address.internalLine2}
													<br />
												</c:if>
												<c:if test="${commsLogForm.address.internalCity != null}">
														${commsLogForm.address.internalCity}
														${commsLogForm.address.internalState}
														${commsLogForm.address.internalZipCode}
														<br />
												</c:if>
											</c:if>
											</td>
											
										</tr>
		
										<tr>
											<td colspan="4" class="value">&nbsp;</td>
										</tr>
										<tr>
														<td class="label" width="25%">Enrolled:</td>
														<td class="value" width="25%">${commsLogForm.effectiveDate}</td>
														<td class="label" width="25%">Combat Veteran:</td>
														<td class="value" width="25%">${commsLogForm.combatVeteranStatus}</td>
													</tr>
													<tr>
														<td class="label">Service Connected:</td>
														<td class="value">${commsLogForm.serviceConnectionAward}</td>
														<td class="label">Special Authority:</td>
														<td class="value">${commsLogForm.specialAuthority}</td>
													</tr>
										<tr>
											<td colspan="4" class="value">&nbsp;</td>
										</tr>
										<tr>
										
											<td colspan="4">
											<table width="100%" cellpadding="0" cellspacing="0"
							class="moduleShell" role="presentation">
							<tr>
								<td colspan="4">
									<table width="100%" border="1" cellpadding="0" cellspacing="0"
										class="moduleShellTableHead" role="presentation">
										<tr>
											<td class="moduleBlueBox">&nbsp;</td>
											<td colspan="2" class="moduleHeadline">Phone Numbers</td>
										</tr>
									</table>
								</td>
							</tr>
												<!--table width="100%" border="0" cellspacing="0" cellpadding="0"-->
													<tr>
														<td class="label" width="25%">Home:</td>
														<td class="value" width="25%">${commsLogForm.homePhone}</td>
														<td class="label" width="25%">Cell:</td>
														<td class="value" width="25%">${commsLogForm.cellPhone}</td>
													</tr>
													<tr>
														<td class="label">Work:</td>
														<td class="value" width="25%">${commsLogForm.workPhone}</td>
														<td class="label">Temp:</td>
														<td class="value" width="25%">${commsLogForm.tempPhone}</td>
													</tr>
													
													
												</table>
											</td>
										</tr>
		
									</table>
								</td>
							</tr>
						</table>
					</td>
				</tr>
				<!-- VC Determination End -->

				<tr height="5">
					<td />
				</tr>

				<tr>
					<td>
						<table width="100%" cellpadding="0" cellspacing="0"
							class="moduleShell" role="presentation">
							<tr>
								<td colspan="2">
									<table width="100%" border="1" cellpadding="0" cellspacing="0"
										class="moduleShellTableHead" role="presentation">
										<tr>
											<td class="moduleBlueBox">&nbsp;</td>
											<td colspan="2" class="moduleHeadline">Hardship</td>
										</tr>
									</table>
								</td>
							</tr>
							<tr>
								<td width="30%" class="label">Site Granting Hardship:</td>
								<td class="value">Information Not Available</td>
							</tr>
							<tr>
								<td width="30%" class="label">Date Hardship Granted:</td>
								<td class="value">Information Not Available</td>
							</tr>
							<tr>
								<td class="label">Date Hardship Expires:</td>
								<td class="value">Information Not Available</td>
							</tr>
						</table>
					</td>
				</tr>

			</table> <!-- End left column of tables -->
		</td>

		<!-- Column spacer between left and right set of tables. -->
		<td width="50%" valign="top">
			<table width="100%" border="1" cellpadding="0" cellspacing="0" role="presentation">

				<!-- right Start -->
				<tr>
					<td>
						<table width="100%" cellspacing="0" cellpadding="0" class="moduleShell" role="presentation">
							<tr>
								<td colspan="2">
									<table width="100%" border="0" cellpadding="0" cellspacing="0"
										class="moduleShellTableHead" role="presentation">
										<tr>
											<td class="moduleBlueBox">&nbsp;</td>
											<td colspan="2" class="moduleHeadline">Community Care Outcome</td>
										</tr>
									</table>
								</td>
							</tr>

							<tr>
								<td>
									<table table width="100%" border="0" cellspacing="0"
										cellpadding="0" class="moduleShellTableBody"
										role="presentation">
										<c:if test="${commsLogForm.vetChoiceStat == ''}">
											<tr>
												<td colspan="4" width="100%" class="moduleLabel"
													style="padding: 10 0 10 10; text-align: left"><bean-el:message
														key="label.noDataAvailable" /></td>
											</tr>
										</c:if>
										<c:if test="${commsLogForm.vetChoiceStat == 'B'}">
											<tr>
												<td width="30%" class="label">Community Care:</td>
												<td class="value">Basic</td>
											</tr>
										</c:if>
										<c:if test="${commsLogForm.vetChoiceStat == 'X'}">
											<tr>
												<td width="30%" class="label">Community Care:</td>
												<td class="value">Not Eligible</td>
											</tr>
										</c:if>
										<c:if test="${commsLogForm.vetChoiceStat == 'M' || commsLogForm.vetChoiceStat == 'MWT'}">
											<tr>
												<td width="30%" class="label">Community Care:</td>
												<td class="value">Mileage</td>
											</tr>
										</c:if>
										<c:if
											test="${commsLogForm.vetChoiceStat == 'WT' || commsLogForm.vetChoiceStat == 'MWT' || commsLogForm.vetChoiceStat == 'HWT'}">
											<tr>
												<td  width="30%" class="label">Community Care:</td>
												<td class="value">Wait-Time</td>
											</tr>
										</c:if>
										<c:if test="${commsLogForm.vetChoiceStat == 'H' || commsLogForm.vetChoiceStat == 'HWT'}">
											<tr>
												<td width="30%" class="label">Community Care:</td>
												<td class="value">Hardship</td>
											</tr>
										</c:if>
									</table>
								</td>
							</tr>
						</table>
					</td>
				</tr>


				<tr height="10">
					<td></td>
				</tr>

				<tr>
					<td>
						<table width="100%" cellpadding="0" cellspacing="0" class="moduleShell" role="presentation">
							<tr>
								<td colspan="2">
									<table width="100%" border="0" cellpadding="1" cellspacing="0" class="moduleShellTableHead" role="presentation">
										<tr>
											<td class="moduleHeadline">Nearest VACAA Facility</td>
										</tr>
									</table>
								</td>
							</tr>
							<tr>
								<td width="30%" class="label">VISN Number:</td>
								<td class="value">
								
									<c:if test="${commsLogForm.geocodeTransmit != null && commsLogForm.geocodeTransmit.newVisn}">
										${commsLogForm.geocodeTransmit.newVisn} <br />
									</c:if>
						        </td>
								</tr>
									<tr>
								<td width="30%" class="label">Station Number:</td>
								<td class="value">
								
									<c:if test="${commsLogForm.geocodeTransmit != null && commsLogForm.geocodeTransmit.geocodeStationId}">
										${commsLogForm.geocodeTransmit.geocodeStationId} <br />
									</c:if>
						        </td>
								</tr>
							<tr>
								<td width="30%" class="label">Station Address:</td>
								<td class="value">
									<c:if test="${commsLogForm.geocodeTransmit != null && commsLogForm.geocodeTransmit.addressLocationName != null}">
										${commsLogForm.geocodeTransmit.addressLocationName} <br />
									</c:if>
									
									<c:if test="${commsLogForm.geocodeTransmit != null && commsLogForm.geocodeTransmit.addressLine1 != null}">
										${commsLogForm.geocodeTransmit.addressLine1} <br />
									</c:if>
									<c:if test="${commsLogForm.geocodeTransmit != null && commsLogForm.geocodeTransmit.addressLine2 != null}">
										${commsLogForm.geocodeTransmit.addressLine2} <br />
									</c:if>
									<c:if test="${commsLogForm.geocodeTransmit != null}">
										${commsLogForm.geocodeTransmit.city}  ${commsLogForm.geocodeTransmit.state} ${commsLogForm.geocodeTransmit.zip}
									</c:if>
								</td>
							</tr>
							<tr>
								<td width="30%" class="label">Distance:</td>
								<td class="value">
									<c:if test="${commsLogForm.geocodeTransmit != null}">
										${commsLogForm.geocodeTransmit.drivingDistance}
									</c:if>
								</td>
							</tr>
							<tr>
								<td width="30%" class="label">Date Determined:</td>
								<td class="value">${commsLogForm.geocodeDate}</td>
							</tr>
							<tr>
								<td class="label">Result:</td>
								<td class="value">To be filled</td>
							</tr>
							<tr>
								<td class="label">Select Community Care:</td>
								<td class="value">${commsLogForm.vetChoiceStat}</td>
							</tr>
							<tr>
								<td class="label">Comments:</td>
								<td class="value">To be filled</td>
							</tr>
						</table>
					</td>
				</tr>
			</table> <!-- END OF RIGHT table -->

		</td>
	</tr>

	<tr height="10">
		<td>&nbsp;</td>
	</tr>

	<tr>
		<td colspan="3">
			<table width="100%" cellpadding="0" cellspacing="0"
				class="moduleShell" role="presentation">
				<tr>
					<td colspan="5">
						<table width="100%" border="1" cellpadding="0" cellspacing="0"
							class="moduleShellTableHead" role="presentation">
							<tr>
								<td class="moduleBlueBox">&nbsp;</td>
								<td colspan="2" class="moduleHeadline">Wait-Time Information</td>
							</tr>
						</table>
					</td>
				</tr>

				<tr>
					<td width="20%" class="label">VISN</td>
					<td width="20%" class="label">Record Type</td>
					<td width="20%" class="label">Medical Facility (Station No.)</td>
					<td width="20%" class="label">Clinically Indicated Date</td>
					<td class="label">&nbsp;</td>
					<!--td width="350" class="label">Veteran Choice Opt In/Out</td>
					<td width="350" class="label">Date Select Choice</td>
					<td width="350" class="label">Comments</td-->
				</tr>
				<c:forEach var="waittime" items="${commsLogForm.waittimeList}">
				<tr>
					<td width="20%" class="value">${waittime.vaFacility.visnId}</td>
					<td width="20%" class="value">${waittime.waitType.code}</td>
					<td width="20%" class="value">${waittime.vaFacility.stationNumber}</td>
					<td width="20%" class="value">${waittime.waitlistStartDate}</td>
					<td class="label">&nbsp;</td>
					<!--td width="350" class="value">&nbsp;</td>
					<td width="350" class="value">&nbsp;</td>
					<td width="350" class="value">&nbsp;</td-->
				</tr>
				</c:forEach>

			</table>
		</td>
	</tr>
</table>


