@php $LoggedUser = Auth::user()->name; $IsAdmin = Auth::user()->IsAdmin; $LoggedUser = ucwords($LoggedUser); $profile=Auth::user()->ProfilePic; $userId=Auth::user()->RefId; $UserTitle = Auth::user()->UserTitle; if($UserTitle == ''){ $UserTitle = "User"; } $UserTitle = ucwords($UserTitle); $DisplayEmailTab=1; $siteurl=$_SERVER['HTTP_HOST']; $url=explode(".",$siteurl); $InstanceName=$url[0]; //$InstanceName = ucwords($InstanceName); $result=DB::table('InboundEmailConfiguration')->where('DeletedStatus',0)->orderby('CreatedDate','desc')->get("EmailId")->first(); $EmailId=$result->EmailId; $roleId="0c9b7578-91b7-4514-be00-ea381158cdeb";//call executive $userPrimaryRole=DB::table('UserRoleAssociation')->where('UserID',$userId)->where('RoleID',$roleId)->where('PrimaryRole',1)->get(["UserRoleAssociationId"])->first(); try { $userPrimaryRole=$userPrimaryRole->UserRoleAssociationId; } catch(\Exception $e) { $userPrimaryRole=""; } $GetuserPrimaryRole=DB::table('UserRoleAssociation')->where('UserID',$userId)->where('PrimaryRole',1)->get(["RoleID"])->first(); $LoggedUserRole=$GetuserPrimaryRole->RoleID; if($LoggedUserRole=='bbc3b105-8219-4839-a956-1a72ee035ba0' || $LoggedUserRole=='b61c54fb-0ea6-47e2-b2f3-0f65dba41e98' || $LoggedUserRole=='2fe5483f-00de-4741-a419-82763560e80b') { $DisplayUserBreakPage=1; } else { $DisplayUserBreakPage=0; } if($userId=='3890211028' || $userId=='1499005377' || $userId=='3400515195') { $DisplayUserBreakPage=1; } $DisplayImport=0; if($IsAdmin == 1) { $DisplayImport=1; } echo $UserTitle; if($UserTitle == 817405196) { $DisplayImport=1; } @endphp