@forelse($data as $item)
{{-- Status Triangle Ribbon --}}
{{ $item->isactive ? 'Active' : 'Blocked' }}
{{-- Profile Image / Initials --}} @if($item->image && file_exists(public_path('assets/images/'.$folder.'/'.$item->image))) @else @php $words = explode(' ', $item->name); $initials = strtoupper(substr($words[0],0,1) . (isset($words[1]) ? substr($words[1],0,1) : '')); @endphp
{{ $initials }}
@endif {{-- Name --}}
{{ $item->name }}
{{-- Contact --}}

{{ $item->cntctnum }}

{{-- Salary --}}

Rs. {{ number_format($item->salary) }}

{{-- Toggle Switch --}}
isactive == 1 ? 'checked' : '' }}>
{{-- Created By --}} @if($showCreator)

Created By: @if($item->admin_id && $item->admin) {{ $item->admin->name }} @else School @endif

@endif {{-- Delete Button --}}
@empty
No Records Found
@endforelse
{{--
--}} {{--@forelse($data as $item)--}} {{--
--}} {{--
--}} {{--
--}} {{-- Profile Image / Initials --}} {{--@if($item->image && file_exists(public_path('assets/images/'.$folder.'/'.$item->image)))--}} {{----}} {{--@else--}} {{--@php--}} {{--$words = explode(' ', $item->name);--}} {{--$initials = strtoupper(substr($words[0],0,1) . (isset($words[1]) ? substr($words[1],0,1) : ''));--}} {{--@endphp--}} {{--
--}} {{--{{ $initials }}--}} {{--
--}} {{--@endif--}} {{-- Name --}} {{--
{{ $item->name }}
--}} {{-- Contact --}} {{--

--}} {{-- {{ $item->cntctnum }}--}} {{--

--}} {{--

--}} {{-- {{ $item->salary }}--}} {{--

--}} {{-- Status --}} {{--
--}} {{--isactive == 1 ? 'checked' : '' }}>--}} {{--
--}} {{----}} {{--{{ $item->isactive ? 'Active' : 'Blocked' }}--}} {{----}} {{-- Created By (Except Admin) --}} {{--@if($showCreator)--}} {{--

--}} {{--Created By:--}} {{--@if($item->admin_id && $item->admin)--}} {{--{{ $item->admin->name }}--}} {{--@else--}} {{--School--}} {{--@endif--}} {{--

--}} {{--@endif--}} {{--
--}} {{-- Delete Button --}} {{----}} {{--
--}} {{--
--}} {{--
--}} {{--@empty--}} {{--
--}} {{--No Records Found--}} {{--
--}} {{--@endforelse--}} {{--
--}}