<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd">

<html>
<head>
	  <title>Probatur - rozhranie pre študentov</title>                                        
	  <meta http-equiv="Content-Type" content="text/html; charset=utf-8" />
	  <link href="styles/teststyles.css" rel="stylesheet" type="text/css" />
	  <script type="text/javascript" src="dynamic.js"></script>
</head>

<body>
  <div class="main">

    <div class="mini_header">Študent: {$userFullName}, ISIC: {$userIsic}</div>
    <span id="container">
{if $timeOut == 0}
    <div class="mini_headerR">Zostávajúci čas / Uplynulý čas nad otázkou: <span id="totalTime" class="bold">{$totalTime}</span> / <span id="qTime">{$question.time}</span></div>
    <div class="otazky">
			{foreach from=$questions item="entry" name="data"}
      	<a class="{$entry.qMark}" href="?site=test&amp;action=showTest&amp;examId={$examId}&amp;qId={$entry.qIndex}&amp;oldQId={$qIndex}&amp;time={$timeStamp}">{$entry.qIndex}. {$entry.question|truncate:50:"..."}</a><br />
      {/foreach}
      <br />
      <form action="?site=test&amp;action=lockTest&amp;examId={$examId}&amp;qId={$qIndex}&amp;oldQId={$qIndex}&amp;time={$timeStamp}" method="post">
      	<div><input type="submit" name="send" value="Lock testu" /></div>
      </form>
      <div class="legenda">
      Vo vlastnom záujme pred dočasným opustením testovania test locknite.<br />
      </div>
      <form action="?site=evaluateTest&amp;testId={$testId}&amp;oldQId={$qIndex}&amp;time={$timeStamp}" method="post">
      	<div><input type="submit" onclick="return confirm('Naozaj chcete odoslať test (nebudú možné ďalšie úpravy)?')" name="send" value="Odoslať test" /></div>
      </form>
      <div class="legenda">
      Po odoslaní testu, už nie je možná žiadna úprava!
      </div>
    </div>

    <div class="obsah_otazky">
      <form action="?site=test&amp;action=saveAnswer&amp;examId={$examId}&amp;qId={$qIndex}&amp;oldQId={$qIndex}&amp;time={$timeStamp}" method="post">
	      <span class="bold">{$qIndex}. {$question.question}</span><br />                                                        
				{foreach from=$answers item="entry" name="data"}
	      	<input type="checkbox" name="odpoved[]" value="{$entry.aLetter}" {if ($entry.aChecked)}checked="checked"{/if} /> <span class="bold">{$entry.aLetter}.</span> {$entry.answer} <br />
	      {/foreach}
	      <br />
	      Poznámka:<br />
	      <textarea rows="4" cols="40" name="poznamka">{$question.comment}</textarea><br />
	      <br />
	      <input type="submit" name="submit" value="Uložiť">
      </form>
	  	<br />
      Označiť ako:<br />
      <a class="unread" href="?site=test&amp;action=markAsUnread&amp;examId={$examId}&amp;qId={$qIndex}&amp;oldQId={$qIndex}&amp;time={$timeStamp}">Neprečítané</a><br />
      <a class="answered" href="?site=test&amp;action=markAsAnswered&amp;examId={$examId}&amp;qId={$qIndex}&amp;oldQId={$qIndex}&amp;time={$timeStamp}">Zodpovedané</a><br />
      <a class="undone" href="?site=test&amp;action=markAsUndone&amp;examId={$examId}&amp;qId={$qIndex}&amp;oldQId={$qIndex}&amp;time={$timeStamp}">Nedokončené</a><br />
      <a class="unknown" href="?site=test&amp;action=markAsUnknown&amp;examId={$examId}&amp;qId={$qIndex}&amp;oldQId={$qIndex}&amp;time={$timeStamp}">Neviem</a><br />
      <a class="else" href="?site=test&amp;action=markAsElse&amp;examId={$examId}&amp;qId={$qIndex}&amp;oldQId={$qIndex}&amp;time={$timeStamp}">Iné</a><br />
      <br />
      <a href="?site=test&amp;action=showTest&amp;examId={$examId}&amp;qId={$qIndexPrev}&amp;oldQId={$qIndex}&amp;time={$timeStamp}">&lt;&lt;&lt;</a>&nbsp;&nbsp;&nbsp;<a href="?site=test&amp;action=showTest&amp;examId={$examId}&amp;qId={$qIndexNext}&amp;oldQId={$qIndex}&amp;time={$timeStamp}">&gt;&gt;&gt;</a>
      <input type="hidden" name="globTime" id="globTime" value="{$totalTime}" />
      <input type="hidden" name="questionTime" id="questionTime" value="{$question.time}" />
    	<input type="hidden" name="testId" id="testId" value="{$testId}" />
    	<input type="hidden" name="userId" id="userId" value="{$userId}" />
    	<input type="hidden" name="oldQId" id="oldQId" value="{$qIndex}" />
		</div>
{else}
		<div>
			Časový limit vypršal. Pokračujte kliknutím na <a href="?site=evaluateTest&amp;testId={$testId}&amp;oldQId={$qIndex}&amp;time={$timeStamp}">tento link</a>.
		</div>
{/if}
		</span>

  </div>

</body>
</html>

