<%@ page contentType="text/html; charset=UTF-8"%>
<%@ include file="/WEB-INF/jspf/include/taglibs.jsp"%>
<c:if test="${not empty dataMap['memoList']}">
	<table class="table tableWidth tableFont memoList">
  		<thead>
  			<tr>
  	  			<td width="40">ID</td>
  	  			<td width="150">Дата</td>
  	  			<td>Заголовок</td>
  	  		</tr>
  		</thead>
  		<tbody>
  			<c:forEach var="item" items="${dataMap['memoList']}">
			<tr>
				<td align="right">${item.id}</td>				
				<td><fmt:formatDate value="${item.time}" pattern="dd.MM.yyyy HH:mm:ss"/></td>
				<td style="text-align: left;"><a href="?action=Memo&module=contract&id=${item.id}">${item.subject}</a></td>
			</tr>
  			</c:forEach>
  		</tbody>
	</table>
</c:if>
<c:if test="${not empty dataMap['contractMemo']}">
	<c:set var="contractMemo" value="${dataMap['contractMemo']}" />
	<div class="date memoDate"><fmt:formatDate value="${contractMemo.time}" pattern="dd.MM.yyyy HH:mm:ss"/></div>
	<h1 class="title memoTitle">${contractMemo.subject}</h1>
	<div class="memoComment"><textarea readonly="readonly" style="width: 100%; height: 400px; font-size: 10pt; padding: 5px;">${contractMemo.comment}</textarea></div>
	<c:url var="url" value="">
		<c:param name="action" value="MemoTable" />
		<c:param name="module" value="contract" />
	</c:url>
	<div style="margin-top: 10px;"><input type="button" value="К списку ..." onclick="document.location='${url}'"></div>	
</c:if>