mailwolt/resources/views/livewire/ui/system/modal/user-edit-modal.blade.php

61 lines
3.0 KiB
PHP

<div class="mw-modal-frame">
<div class="mw-modal-head">
<div style="display:flex;align-items:center;gap:7px">
<span class="mbx-badge-mute">Benutzer</span>
<span style="font-size:12px;color:var(--mw-t3)"> {{ $name }}</span>
</div>
<button wire:click="$dispatch('closeModal')" class="mw-modal-close">
<svg width="13" height="13" viewBox="0 0 13 13" fill="none"><path d="M1 1l11 11M12 1L1 12" stroke="currentColor" stroke-width="1.4" stroke-linecap="round"/></svg>
</button>
</div>
<div class="mw-modal-body">
<div class="mw-modal-grid2">
<div>
<label class="mw-modal-label">Name</label>
<input type="text" wire:model.defer="name" class="mw-modal-input">
@error('name') <div class="mw-modal-error">{{ $message }}</div> @enderror
</div>
<div>
<label class="mw-modal-label">E-Mail</label>
<input type="email" wire:model.defer="email" class="mw-modal-input">
@error('email') <div class="mw-modal-error">{{ $message }}</div> @enderror
</div>
</div>
<div style="margin-top:12px">
<label class="mw-modal-label">Neues Passwort <span style="color:var(--mw-t4);font-weight:400">(leer lassen = unverändert)</span></label>
<input type="password" wire:model.defer="password" class="mw-modal-input" placeholder="Mindestens 8 Zeichen">
@error('password') <div class="mw-modal-error">{{ $message }}</div> @enderror
</div>
<div class="mw-modal-grid2" style="margin-top:12px">
<div>
<label class="mw-modal-label">Rolle</label>
<select wire:model.defer="role" class="mw-modal-input" {{ $isSelf ? 'disabled' : '' }}>
@foreach($roles as $r)
<option value="{{ $r->value }}">{{ $r->label() }}</option>
@endforeach
</select>
@if($isSelf)
<div class="mw-modal-hint">Eigene Rolle kann nicht geändert werden.</div>
@endif
</div>
<div style="padding-top:22px">
<label class="sec-check" style="{{ $isSelf ? 'opacity:.4;pointer-events:none' : '' }}">
<input type="checkbox" wire:model.defer="is_active" {{ $isSelf ? 'disabled' : '' }}>
<span style="font-size:12.5px;color:var(--mw-t2)">Aktiv</span>
</label>
</div>
</div>
</div>
<div class="mw-modal-foot">
<button wire:click="$dispatch('closeModal')" class="mw-btn-cancel">Abbrechen</button>
<button wire:click="save" class="mw-btn-primary">
<svg width="12" height="12" viewBox="0 0 14 14" fill="none"><path d="M2 2h8l2 2v8a1 1 0 0 1-1 1H3a1 1 0 0 1-1-1V3a1 1 0 0 1 1-1Z" stroke="currentColor" stroke-width="1.2"/><path d="M5 2v3h4V2" stroke="currentColor" stroke-width="1.2" stroke-linecap="round"/></svg>
Speichern
</button>
</div>
</div>