{if $actionInfo != ""}
  <div class="note">
    {$actionInfo}
  </div>
{/if}
<table>
<tr>
<td>
<h2>{$course.name}</h2>
<table border="0">
  <tr>
    <td width="80px"><b>Učiteľ:</b></td>
    <td> 
{if $teacher}
<a href="index.php?site=teacher&amp;action=info&amp;id={$teacher.id}">{$teacher.namePrefix} {$teacher.name}
 {$teacher.surname} {$teacher.nameSuffix}</a>
{else}
  Predmet nemá prideleného učiteľa.
{/if}
    </td>
  </tr>
  <tr>
    <td><b>Kód:</b></td>
    <td>{$course.code}</td>
  </tr>
</table>
<br />
{if $course.description != ""}
<br />
<b>informácie o predmete:</b><br />
{$course.description}<br />
{/if}
<br />
<a href="index.php?site=course&amp;action=edit&amp;id={$course.id}">[editovať]</a> |
<a href="index.php?site=course&amp;action=delete&amp;id={$course.id}">[vymazať]</a><br />
<br />
<br />
<b>Zoznam študentov:</b><br />
{if !$students}
  <br />
  Žiaden študent nemá priradený tento predmet.
{else}
<br />
<form action="index.php?site=course&amp;action=remove_students&amp;id={$course.id}" method="post">
  <table class="default spacy">
    <tr class="head">
      <td colspan="2">Meno</td>
    </tr>
{foreach from=$students item=student}
    <tr>
      <td style="width: 400px"><a href="index.php?site=student&amp;action=info&amp;id={$student.id}">{$student.namePrefix} 
{$student.name} {$student.surname} {$student.nameSuffix}</a></td>
      <td><input type="checkbox" name="{$student.id}" /></td>
    </tr>
{/foreach}
  	<tr class="head"> 
      <td colspan="2" align="right"><input type="submit" name="remove" value="Odstrániť" /></td>
  	</tr>
  </table>
</form>
{/if}
</td>
</tr>
</table>
