@php $role = Auth::user()->roles[0]->name; if ($role == 'Company' || $role == 'Musteri') { $rolePathIndex = 'company.index'; } if ($role == 'Branch') { $rolePathIndex = 'branch.index'; } if ($role == 'Operasyon') { $rolePathIndex = 'operation.index'; } if ($role == 'Hr') { if (count(auth()->user()->permissions) > 1) { if (!auth()->user()->can('ik_bordro')) { $rolePathIndex = 'hummanresource.index'; } else { $rolePathIndex = 'hummanresource.firstPage'; } } else { if (auth()->user()->can('ik_ise_alim')) { $rolePathIndex = 'hummanresource.index'; } elseif (auth()->user()->can('ik_bordro')) { $rolePathIndex = 'hummanresource.index2'; } elseif (auth()->user()->can('call_support')) { $rolePathIndex = 'hummanresource.index3'; } } } if ($role == 'Muhasebe') { $rolePathIndex = 'accounting.index'; } if ($role == 'Randevu') { $rolePathIndex = 'randevu.pageIndex'; } if ($role == 'Sales_marketing') { $rolePathIndex = 'salesMarketing.index'; } if ($role == 'Root') { $rolePathIndex = 'root.index'; } if ($role == 'department') { $rolePathIndex = 'department.index'; } if ($role == 'isg') { $rolePathIndex = 'isg.index'; } @endphp