<?php /* Smarty version 2.6.18, created on 2007-06-06 00:19:34
         compiled from specList.tpl */ ?>
<?php if ($this->_tpl_vars['specCount'] > 0): ?>
<?php if ($this->_tpl_vars['actionInfo'] != ""): ?>
  <div class="note">
    <?php echo $this->_tpl_vars['actionInfo']; ?>

  </div>
<?php endif; ?>
<div class="note">
  Zoznam štúdijných odborov môžete utriediť podľa <b>Názvu</b> alebo <b>Garanta odboru</b>.
</div>
<table class="default spacy" width="100%">
  <tr class="head">
    <td>
      <a href="index.php?site=spec&amp;action=list&amp;order=name<?php if ($this->_tpl_vars['order'] == 'name'): ?>D<?php endif; ?>">Odbor</a>
    </td>
    <td>
      <a href="index.php?site=spec&amp;action=list&amp;order=garant<?php if ($this->_tpl_vars['order'] == 'garant'): ?>D<?php endif; ?>">Garant</a>
    </td>
    <td colspan="3">Akcia</td>
  </tr>
  <?php $_from = $this->_tpl_vars['specs']; if (!is_array($_from) && !is_object($_from)) { settype($_from, 'array'); }$this->_foreach['row'] = array('total' => count($_from), 'iteration' => 0);
if ($this->_foreach['row']['total'] > 0):
    foreach ($_from as $this->_tpl_vars['id'] => $this->_tpl_vars['specialization']):
        $this->_foreach['row']['iteration']++;
?>  
  <tr id="item<?php echo ($this->_foreach['row']['iteration']-1); ?>
" class="<?php if (($this->_foreach['row']['iteration']-1)%2 == 0): ?>row1<?php else: ?>row2<?php endif; ?>" 
      onmouseover="document.getElementById('item<?php echo ($this->_foreach['row']['iteration']-1); ?>
').style.background='#feda87'"
      onmouseout="document.getElementById('item<?php echo ($this->_foreach['row']['iteration']-1); ?>
').style.background='<?php if (($this->_foreach['row']['iteration']-1)%2 == 0): ?>#f8f8f8<?php else: ?>#e8e8e8<?php endif; ?>'">  
    <td width="300"><b><?php echo $this->_tpl_vars['specialization']['name']; ?>
</b></td>
    <td>
    <?php if ($this->_tpl_vars['specialization']['garant']): ?>
      <a href="index.php?site=teacher&amp;action=info&amp;id=<?php echo $this->_tpl_vars['specialization']['garant']['id']; ?>
"><?php echo $this->_tpl_vars['specialization']['garant']['namePrefix']; ?>
 
        <?php echo $this->_tpl_vars['specialization']['garant']['surname']; ?>
 <?php echo $this->_tpl_vars['specialization']['garant']['name']; ?>
 <?php echo $this->_tpl_vars['specialization']['garant']['nameSuffix']; ?>
</a><br />
    <?php endif; ?>
    </td>
    <td class="action"><a href="index.php?site=spec&amp;action=info&amp;id=<?php echo $this->_tpl_vars['id']; ?>
">[detaily]</a></td>
    <td class="action"><a href="index.php?site=spec&amp;action=edit&amp;id=<?php echo $this->_tpl_vars['id']; ?>
">[editovať]</a></td>
    <td class="action"><a href="index.php?site=spec&amp;action=delete&amp;id=<?php echo $this->_tpl_vars['id']; ?>
">[zmazať]</a></td>
  </tr>
  <?php endforeach; endif; unset($_from); ?>
  <tr class="head">
    <td colspan="5">&nbsp;</td>
  </tr>
</table>
<?php else: ?>
  <div class="note">
    V databáze zatiaľ nie sú vytvorené žiadne odbory štúdia.<br/>
    <br/>
    Nové štúdijné odbory môžete pridať <a href="index.php?site=spec&amp;action=add">manuálne</a>, 
    alebo ich získať <a href="index.php?site=import&amp;action=import_q">importovaním</a>
    užívateľov (štúdijné odbory budú vytvorené automaticky). 
  </div>
<?php endif; ?>
