<?php
/**
 * @author Lukas Havlicek
 * @version 1.0
 */

$this->headTitle($this->projectName);
$this->placeholder('title')->set($this->t('historie-f'));
?>
<h1 class="page_title"><?=$this->t('historie-f')?></h1>
        <h1 class="group_title"><?=$this->t('prehled-f')?></h1>
            <div class="main_inner2">
    			<div class="main_inner">
    	            
    				<div class="main_text">
                        <h2 class="section_heading"><?=$this->t('historie-f')?></h2>

  						<?php if (isset($this->data) && $this->data->count()) : ?>
		                <table>
		                	<?php foreach ($this->data as $i) : ?>
		                	
		                    <tr class="<?=$this->evod('odd', 'even');?>">
		                    	<td><?=$this->date($i->history_added)?></td>
		                    	<td><?=$this->time($i->history_added)?></td>
		                    	<td><?=$this->t($i->history_action)?></td>
		                    	<td><?=$this->escape($i->user_surname . ' ' . $i->user_firstname)?></td>
		                    	<td><?=$this->escape($i->doc_name)?></td>
		                        <td class="actions">
	                            	<a class="action_read" href="<?=$this->baseUrl()?>/documents/detail/id/<?=$i->id_document?>"><?=$this->t('prejit-k-dokumentu-AF')?></a>
		                        </td>
		                    </tr>
		                    <?php endforeach; ?>
		                    <?php $this->evod('','', 1);?>
		                </table>
                        
                        <div class="paging">
                            <?=$this->paginationControl($this->data, 'Sliding', 'history/paging.phtml'); ?>
                        </div>
                        <?php else : ?>
                        	<div class="info_box"><?=$this->t('zadne-zaznamy-f')?>.</div>
                        <?php endif; ?>
                        
                    </div>
    			
    			</div>
			</div>