<?php if(is_array($this->view->accesses) && !empty($this->view->accesses)): ?>
	<div class="clearfix">
		<a href="<?php echo $this->helper->setHash('users-access-logs/1'); ?>" class="float-right"><?php echo _('Show more...'); ?></a>
	</div>
	<table  class="table table-hover">
		<thead class="thead-light">
			<tr>
				<th width="1%"></th>
				<th><?php echo _('Surname'); ?></th>
				<th><?php echo _('Name'); ?></th>
				<th class="text-right"><?php echo _('Interval'); ?></th>
			</tr>
		</thead>
		
		<tbody>
			<?php foreach($this->view->accesses as $access): ?>
				<tr>
					<td><?php echo $this->helper->setAvatarView($this->user->getAvatar($access['user_id']), ['timestamp'=>md5($access['user_updated_at'])]); ?></td>
					<td><?php echo $access['surname']; ?></td>
					<td><?php echo $access['name']; ?></td>
					<td class="text-right"><?php echo $this->helper->dateIntervalString($access['created_at']); ?></td>
				</tr>
			<?php endforeach; ?>
		</tbody>
	</table>
<?php else: ?>
	<div class="alert alert-light" role="alert"><?php echo _('The accesses content is currently empty, please try again in a few minutes.'); ?></div>
<?php endif; ?>