Ident the user/list view script w/ 4 spaces

refs #5543
This commit is contained in:
Eric Lippmann 2015-09-25 12:23:43 +02:00
parent 49a7084b6a
commit 1728d5a949
1 changed files with 61 additions and 57 deletions

View File

@ -14,20 +14,21 @@ if (! $this->compact): ?>
</div>
</div>
<?php endif ?>
<div class="content users">
<?php if (! isset($backend)): ?>
<p><?= $this->translate('No backend found which is able to list users.') ?></p>
</div>
<?php return; endif ?>
<?php if (! $users->hasResult()): ?>
<p><?= $this->translate('No users found matching the filter.') ?></p>
</div>
<?php return; endif ?>
<?php
if (! isset($backend)) {
echo $this->translate('No backend found which is able to list users') . '</div>';
return;
} elseif (! $users->hasResult()) {
echo '<p>' . $this->translate('No users found matching the filter') . '</p>' . '</div>';
return;
} else {
$extensible = $this->hasPermission('config/authentication/users/add') && $backend instanceof Extensible;
$reducible = $this->hasPermission('config/authentication/users/remove') && $backend instanceof Reducible;
}
$extensible = $this->hasPermission('config/authentication/users/add') && $backend instanceof Extensible;
$reducible = $this->hasPermission('config/authentication/users/remove') && $backend instanceof Reducible;
?>
<table data-base-target="_next" class="action user-list alternating">
<table data-base-target="_next" class="action user-list alternating">
<thead>
<tr>
<th class="user-name"><?= $this->translate('Username') ?></th>
@ -39,15 +40,19 @@ if (! isset($backend)) {
<tbody>
<?php foreach ($users as $user): ?>
<tr>
<td class="user-name"><?= $this->qlink($user->user_name, 'user/show', array(
<td class="user-name"><?= $this->qlink(
$user->user_name,
'user/show',
array(
'backend' => $backend->getName(),
'user' => $user->user_name
), array(
),
array(
'title' => sprintf($this->translate('Show detailed information about %s'), $user->user_name)
)) ?></td>
)
) ?></td>
<?php if ($reducible): ?>
<td class="user-remove">
<?= $this->qlink(
<td class="user-remove"><?= $this->qlink(
null,
'user/remove',
array(
@ -58,18 +63,17 @@ if (! isset($backend)) {
'title' => sprintf($this->translate('Remove user %s'), $user->user_name),
'icon' => 'trash'
)
) ?>
</td>
) ?></td>
<?php endif ?>
</tr>
<?php endforeach ?>
</tbody>
</table>
<?php endforeach ?>
</tbody>
</table>
<?php if ($extensible): ?>
<?= $this->qlink($this->translate('Add a new user'), 'user/add', array('backend' => $backend->getName()), array(
<?= $this->qlink($this->translate('Add a new user'), 'user/add', array('backend' => $backend->getName()), array(
'icon' => 'plus',
'data-base-target' => '_next',
'class' => 'user-add'
)) ?>
)) ?>
<?php endif ?>
</div>