mirror of
https://github.com/monstra-cms/monstra.git
synced 2025-08-03 19:57:57 +02:00
58 lines
2.2 KiB
PHP
Executable File
58 lines
2.2 KiB
PHP
Executable File
<h2><?php echo __('Users', 'users'); ?></h2>
|
|
<br />
|
|
|
|
<?php if (Notification::get('success')) Alert::success(Notification::get('success')); ?>
|
|
|
|
<?php echo Html::anchor(__('Register new user', 'users'), 'index.php?id=users&action=add', array('title' => __('Register new user', 'users'), 'class' => 'btn default btn-small')); ?>
|
|
|
|
<div class="pull-right">
|
|
<?php echo Form::open(null, array('name' => 'users_frontend')); ?>
|
|
<?php echo Form::hidden('csrf', Security::token()); ?>
|
|
<?php echo Form::checkbox('users_frontend_registration', null, $users_frontend_registration); ?> <?php echo __('Allow user registration', 'users') ?>
|
|
<?php echo Form::input('users_frontend_submit', 'users_frontend_submit', array('style' => 'display:none;')); ?>
|
|
<?php echo Form::close();?>
|
|
</div>
|
|
|
|
<br /><br />
|
|
|
|
<!-- Users_list -->
|
|
<table class="table table-bordered">
|
|
<thead>
|
|
<tr>
|
|
<th><?php echo __('Username', 'users'); ?></th>
|
|
<th><?php echo __('Email', 'users'); ?></th>
|
|
<th><?php echo __('Registered', 'users'); ?></th>
|
|
<th><?php echo __('Role', 'users'); ?></th>
|
|
<th></th>
|
|
</tr>
|
|
</thead>
|
|
<tbody>
|
|
<?php foreach ($users_list as $user) { ?>
|
|
<tr>
|
|
<td>
|
|
<?php echo Html::toText($user['login']); ?>
|
|
</td>
|
|
<td>
|
|
<?php echo Html::toText($user['email']); ?>
|
|
</td>
|
|
<td>
|
|
<?php echo Date::format($user['date_registered']); ?>
|
|
</td>
|
|
<td>
|
|
<?php echo $roles["{$user['role']}"]; ?>
|
|
</td>
|
|
<td>
|
|
<div class="pull-right">
|
|
<?php echo Html::anchor(__('Edit', 'users'), 'index.php?id=users&action=edit&user_id='.$user['id'], array('class' => 'btn btn-small')); ?>
|
|
<?php echo Html::anchor(__('Delete', 'users'),
|
|
'index.php?id=users&action=delete&user_id='.$user['id'].'&token='.Security::token(),
|
|
array('class' => 'btn btn-small', 'onclick' => "return confirmDelete('".__('Delete user: :user', 'users', array(':user' => Html::toText($user['login'])))."')"));
|
|
?>
|
|
</div>
|
|
</td>
|
|
</tr>
|
|
<?php } ?>
|
|
</tbody>
|
|
</table>
|
|
<!-- /Users_list -->
|