mirror of
https://github.com/ad-aures/castopod.git
synced 2026-04-14 20:17:46 +02:00
refactor(auth): change contributor's role logic to have it included in the users_podcasts table
- update myth-auth and codeigniter to latest develop changes - improve permission check: remove all dynamic permissions per podcast and overwrite myth-auth services and permission filter - remove unnecessary code because of myth-auth upgrade - refactor some controller code for better clarity - add remaining seeders in docs closes #19, #20
This commit is contained in:
parent
e0da11517d
commit
58364bfed1
39 changed files with 1197 additions and 685 deletions
33
app/Views/admin/user/edit.php
Normal file
33
app/Views/admin/user/edit.php
Normal file
|
|
@ -0,0 +1,33 @@
|
|||
<?= $this->extend('admin/_layout') ?>
|
||||
|
||||
<?= $this->section('title') ?>
|
||||
<?= lang('User.edit_roles', ['username' => $user->username]) ?>
|
||||
<?= $this->endSection() ?>
|
||||
|
||||
|
||||
<?= $this->section('content') ?>
|
||||
|
||||
<form action="<?= route_to(
|
||||
'user_edit',
|
||||
$user->id
|
||||
) ?>" method="post" class="flex flex-col max-w-lg">
|
||||
<?= csrf_field() ?>
|
||||
|
||||
<label for="roles"><?= lang('User.form.roles') ?></label>
|
||||
<select id="roles" name="roles[]" autocomplete="off" class="mb-6 form-multiselect" multiple>
|
||||
<?php foreach ($roles as $role): ?>
|
||||
<option value="<?= $role->id ?>"
|
||||
<?php if (
|
||||
in_array($role->name, $user->roles)
|
||||
): ?> selected <?php endif; ?>>
|
||||
<?= $role->name ?>
|
||||
</option>
|
||||
<?php endforeach; ?>
|
||||
</select>
|
||||
|
||||
<button type="submit" class="px-4 py-2 ml-auto border">
|
||||
<?= lang('User.form.submit_edit') ?>
|
||||
</button>
|
||||
</form>
|
||||
|
||||
<?= $this->endSection() ?>
|
||||
Loading…
Add table
Add a link
Reference in a new issue