@extends('layout.master') @section('content') @php $userType = \App\Helpers\Helpers::getUserRole()->type_id ?? []; $userAccess = \App\Helpers\Helpers::getUserAccess() ?? []; $access = $userAccess['accesses'] ?? []; @endphp @if (!empty($residents_list))
{{--

Residence

--}}
+ Add Resident {{-- + Add Visitor --}} {{-- --}}
@php $view = !empty($userType) ? ($userType == 1 || $userType == 3 || ($userType == 2 && (!empty($access['residence']) && in_array(2, $access['residence']))) ? '' : 'hide') : 'hide'; $edit = !empty($userType) ? ($userType == 1 || $userType == 3 || ($userType == 2 && (!empty($access['residence']) && in_array(3, $access['residence']))) ? '' : 'hide') : 'hide'; $delete = !empty($userType) ? ($userType == 1 || $userType == 3 || ($userType == 2 && (!empty($access['residence']) && in_array(4, $access['residence']))) ? '' : 'hide') : 'hide'; @endphp @include('residences.table')
@else

No records found

@endif {{-- filter model for residence --}} @push('scripts') @endPush @endsection