@extends('layouts.app') @section('title', 'Kelola Akun') @section('content')

Kelola Akun

@forelse ($user as $item) @include('components.modal-form-akun', [ 'modalId' => 'edit-akun-' . $item->id, 'action' => route('user-management.update', $item->id), 'method' => 'PATCH', 'title' => 'Edit Akun Admin', 'buttonClass' => 'btn-primary', 'buttonText' => 'Simpan', 'data' => $item, ]) @include('components.modal-delete-akun', [ 'modalId' => 'delete-akun-' . $item->id, 'route' => route('user-management.destroy', $item->id), 'message' => "Yakin ingin menghapus akun {$item->name}?", ]) @empty @endforelse
No Username No. HP Email Role Aksi
{{ $loop->iteration }} {{ $item->username }} {{ preg_replace('/(\d{4})(\d{4})(\d+)/', '$1 $2 $3', $item->phone) }} {{ $item->email }} @if ($item->role == 'superadmin') @elseif ($item->role == 'admin') @else @endif {{ ucfirst($item->role) }}
Belum ada data pengguna
@include('components.modal-form-akun', [ 'modalId' => 'tambah-akun', 'action' => route('user-management.store'), 'method' => 'POST', 'title' => 'Tambah Akun Admin', 'buttonClass' => 'btn-success', 'buttonText' => 'Simpan', ]) @if (session('info')) @include('components.modal-success', [ 'message' => session('info'), ]) @endif @endsection @push('pageScripts') @endpush