addressbook/Vanilla/templates/admin/users.html.php

36 lines
1.1 KiB
PHP
Raw Normal View History

2022-10-23 19:14:13 +02:00
<?php include dirname(path: __DIR__) . '/_header.html.php'; ?>
<h2>User list</h2>
<table>
<tr>
<th>Nick</th>
<th>First</th>
<th>Last</th>
<th>Is Admin</th>
2022-10-24 18:44:18 +02:00
<th colspan="2">&nbsp;</th>
2022-10-23 19:14:13 +02:00
</tr>
<?php foreach ($users as $userLine): ?>
<tr>
<td><?= $userLine->getNick() ?></td>
<td><?= $userLine->getFirst() ?></td>
<td><?= $userLine->getLast() ?></td>
<td style="text-align: center;">
<?php if ($userLine->isAdmin()): ?>
☑️
<?php else: ?>
👎
<?php endif; ?>
</td>
<td>
2022-10-24 18:44:18 +02:00
<a href="<?= $router->path('app_admin_users_edit', vars: ['nick' => $userLine->getNick()]); ?>">edit</a>
</td>
<td>
<a href="<?= $router->path('app_admin_users_delete', vars: ['nick' => $userLine->getNick()]); ?>">delete</a>
2022-10-23 19:14:13 +02:00
</td>
</tr>
<?php endforeach; ?>
</table>
2022-10-24 18:44:18 +02:00
<a href="<?= $router->path('app_admin_users_add'); ?>">Add User</a>
2022-10-23 19:14:13 +02:00
<?php include dirname(path: __DIR__) . '/_footer.html.php' ?>