2015-09-07 15:04:31 +02:00
|
|
|
<?php if (! $this->compact): ?>
|
|
|
|
<div class="controls">
|
|
|
|
<?= $this->tabs; ?>
|
2015-09-17 15:17:46 +02:00
|
|
|
<?= $this->sortBox; ?>
|
|
|
|
<?= $this->limiter; ?>
|
|
|
|
<?= $this->paginator; ?>
|
|
|
|
<?= $this->filterEditor; ?>
|
2015-09-07 15:04:31 +02:00
|
|
|
</div>
|
|
|
|
<?php endif ?>
|
|
|
|
<div class="content" data-base-target="_next">
|
2015-09-17 15:17:46 +02:00
|
|
|
<?php if (count($items) === 0): ?>
|
2015-09-18 08:53:05 +02:00
|
|
|
<p><?= $this->translate('There are currently no navigation items being shared'); ?></p>
|
2015-09-16 13:07:41 +02:00
|
|
|
<?php else: ?>
|
2015-09-07 15:04:31 +02:00
|
|
|
<table class="action alternating">
|
|
|
|
<thead>
|
|
|
|
<th><?= $this->translate('Shared Navigation'); ?></th>
|
2015-09-16 15:37:56 +02:00
|
|
|
<th style="width: 10em"><?= $this->translate('Type'); ?></th>
|
2015-09-16 11:52:42 +02:00
|
|
|
<th style="width: 10em"><?= $this->translate('Owner'); ?></th>
|
2015-09-16 13:05:45 +02:00
|
|
|
<th style="width: 5em"><?= $this->translate('Unshare'); ?></th>
|
2015-09-07 15:04:31 +02:00
|
|
|
</thead>
|
|
|
|
<tbody>
|
|
|
|
<?php foreach ($items as $name => $item): ?>
|
|
|
|
<tr>
|
|
|
|
<td><?= $this->qlink(
|
|
|
|
$name,
|
|
|
|
'navigation/edit',
|
2015-09-23 14:21:04 +02:00
|
|
|
array(
|
|
|
|
'name' => $name,
|
|
|
|
'referrer' => 'shared'
|
|
|
|
),
|
2015-09-07 15:04:31 +02:00
|
|
|
array(
|
|
|
|
'title' => sprintf($this->translate('Edit shared navigation item %s'), $name)
|
|
|
|
)
|
|
|
|
); ?></td>
|
2015-09-16 15:37:56 +02:00
|
|
|
<td><?= $item->type && isset($types[$item->type])
|
|
|
|
? $this->escape($types[$item->type])
|
|
|
|
: $this->escape($this->translate('Unknown')); ?></td>
|
2015-09-16 11:52:42 +02:00
|
|
|
<td><?= $this->escape($item->owner); ?></td>
|
2015-09-18 11:34:00 +02:00
|
|
|
<?php if ($item->parent): ?>
|
|
|
|
<td><?= $this->icon(
|
|
|
|
'block',
|
|
|
|
sprintf(
|
|
|
|
$this->translate(
|
2015-09-18 13:24:44 +02:00
|
|
|
'This is a child of the navigation item %1$s. You can'
|
|
|
|
. ' only unshare this item by unsharing %1$s'
|
2015-09-18 11:34:00 +02:00
|
|
|
),
|
|
|
|
$item->parent
|
|
|
|
)
|
|
|
|
); ?></td>
|
|
|
|
<?php else: ?>
|
2015-09-16 13:08:44 +02:00
|
|
|
<td data-base-target="_self"><?= $removeForm->setDefault('name', $name); ?></td>
|
2015-09-18 11:34:00 +02:00
|
|
|
<?php endif ?>
|
2015-09-07 15:04:31 +02:00
|
|
|
</tr>
|
|
|
|
<?php endforeach ?>
|
|
|
|
</tbody>
|
|
|
|
</table>
|
2015-09-16 13:07:41 +02:00
|
|
|
<?php endif ?>
|
2015-09-07 15:04:31 +02:00
|
|
|
</div>
|