@csrf
@php
$loopcount=1;
$closediv=0;
$i=0;
$h=0;
$OldPanelId='';
$closePreviousTab="0";
$firsttab="show active";
$countHeader=count($header);
@endphp
@foreach($header as $fieldList)
@php
$h++;
$field_name=$fieldList['FieldName'];
$DisplayName=$fieldList['DisplayName'];
$DisplayType=$fieldList['DisplayType'];
$DependentFieldPanelType=$fieldList['DependentFieldPanelType'];
$DependentFieldPanelId=$fieldList['DependentFieldPanelId'];
$PanelId=$fieldList['PanelId'];
if(!array_key_exists(0,$results_obj))
{
$LabelValue='';
}
else
{
$LabelValue = $results_obj[0]->$field_name;
}
$displayColor="#888ea8";
if(array_key_exists($LabelValue,$DropDownColors))
{
$displayColor=$DropDownColors[$LabelValue];
}
$DropDownNameId=$fieldList['DropDownNameId'];
$ParentModuleId=$fieldList['ParentModuleId'];
@endphp
@if($closePreviousTab=="1" && $PanelId!=$OldPanelId)
@endif
@if($PanelId!=$OldPanelId)
@php
if($firsttab)
{
$className="displayblock";
}
else
{
$className="displaynone";
}
@endphp
@php
$OldPanelId=$PanelId;
$closePreviousTab=1;
$firsttab="";
@endphp
@endif
@php
if($DisplayType==2 || $DisplayType==26)
{
if(empty($ListBoxNamesIDs) || $DropDownNameId=='')
{
$LabelValue="";
//$LabelValue=$GetDropdownLists[$LabelValue];
}
else
{
$ListBoxNamesIDVal=$DropDownNameId;
if(array_key_exists($ListBoxNamesIDVal,$GetDropdownLists))
{
$listBoxVal=$GetDropdownLists[$ListBoxNamesIDVal];
if(array_key_exists($LabelValue,$listBoxVal))
$LabelValue=$listBoxVal[$LabelValue];
}
}
}
if($DisplayType==3)
{
if(empty($ListBoxNamesIDs) || $DropDownNameId=='')
{
$LabelValue="";
//$LabelValue=$GetDropdownLists[$LabelValue];
}
else
{
$ListBoxNamesIDVal=$DropDownNameId;
if(array_key_exists($ListBoxNamesIDVal,$GetDropdownLists))
{
$listBoxVal=$GetDropdownLists[$ListBoxNamesIDVal];
$listArray=explode(",",$LabelValue);
$LabelValue="";
foreach($listArray as $listVal)
{
if(array_key_exists($listVal,$listBoxVal))
$LabelValue.="
".$listBoxVal[$listVal]."";
}
}
}
}
if($DisplayType==5)
{
if(empty($ListBoxNamesIDs) || $DropDownNameId=='')
{
$LabelValue="";
//$LabelValue=$GetDropdownLists[$LabelValue];
}
else
{
$ListBoxNamesIDVal=$DropDownNameId;
if(array_key_exists($ListBoxNamesIDVal,$GetDropdownLists))
{
$listBoxVal=$GetDropdownLists[$ListBoxNamesIDVal];
if(array_key_exists($LabelValue,$listBoxVal))
$LabelValue=$listBoxVal[$LabelValue];
}
}
}
if($DisplayType==4 && $DateFormat!="" && $LabelValue!="")
{
// added on 28th April '21
//echo $LabelValue;
if($LabelValue=="0000-00-00" || $LabelValue=="0000-00-00 00:00:00")
$LabelValue="";
else
$LabelValue = date("$DateFormat", strtotime($LabelValue));
}
if($DisplayType==14 && $DateFormat!="" && $TimeFormat!="" && $LabelValue!="")
{
// updated on 16th Sept '21
if($LabelValue=="0000-00-00 00:00:00")
{
$LabelValue="";
}
else
{
// added on 29th April '21
$datetime = new DateTime($LabelValue);
$datetime->format("$DateFormat $TimeFormat");
$la_time = new DateTimeZone($TimeZone);
//$datetime->setTimezone($la_time);
$LabelValue = $datetime->format("$DateFormat $TimeFormat");
}
}
if($DisplayType==8)
{
// RelateTo
$passArray=array("ModuleId"=>$LabelValue,"RowId"=>$field_name);
$row_id=$LabelValue;
if($LabelValue!="")
{
if(array_key_exists($LabelValue,$RelateModules))
{
$LabelValue=$RelateModules[$LabelValue];
}
else
{
$LabelValue=$LabelValue;
}
}
}
if($DisplayType==23)
{
if(array_key_exists($LabelValue,$getChildDependentRelateToList))
{
$LabelValue=$getChildDependentRelateToList[$LabelValue];
}
$LabelValue=$LabelValue;
}
if($DisplayType==25)
{
// Self RelateTo
@endphp
@foreach($selfRelatedList as $selfRelated)
@php
if($LabelValue==$selfRelated['key'])
{
$LabelValue=$selfRelated['value'];
}
@endphp
@endforeach
@php
}
if($DisplayType==15 && $LabelValue!="")
{
// AssignedTo
if(array_key_exists($LabelValue,$AssignedToList))
$LabelValue=$AssignedToList[$LabelValue]['name'];
}
//if($DisplayType==7 || $DisplayType==10)
if($DisplayType==7 )
{
// TextArea OR TextEditor, added on 6th May '21
$LabelValue=strip_tags($LabelValue);
}
//if($DisplayType==10)
//{
//}
@endphp
@if($loopcount == 1)
@endif
@if($DisplayType==10)
@if($RelatedModules['Status']=="Success")
@php
$subpanel_loop=0;
@endphp
@foreach($RelatedModules['data'] as $subpanels=>$modules)
@if($modules['AssociationType']==2 || $modules['AssociationType']==3)
@php
$SecondaryModuleId=$modules['SecondaryModuleId'];
$AssociationType=$modules['AssociationType'];
$ModuleIcon=$modules['ModuleIcon'];
$TableCount=$modules['TableCount'];
$SubPanel_Count=0; // $modules['AssociationType'];
if($ModuleIcon=="")
$ModuleIcon='
';
@endphp
@php
$subpanel_loop++;
@endphp
@endif
@endforeach
@if(sizeof($EmailsList))
| Slno |
Subject |
From Address |
Date |
View |
@php
$m=0;
@endphp
@foreach($EmailsList as $em)
@php
if($em['EmailStatus']=="Unread")
{
$fontStyle="unread";
}
else
{
$fontStyle="";
}
$m++;
@endphp
| {{$m}} |
{{$em['EmailSubject']}} |
{{$em['FromAddress']}} |
@php echo date('d-m-Y',strtotime($em['CreatedDate'])) @endphp |
@php
$EmailID=$em['EmailId'];
@endphp
|
@endforeach
@else
No Emails!
@endif
@if(sizeof($AssignedTeams))
| Slno |
Teams |
@php
$tc=0;
@endphp
@foreach($AllTeams as $Team)
@if(in_array($Team['TmTeamID'],$AssignedTeams))
@php
$tc++;
@endphp
| {{$tc}} |
{{$Team['TeamName']}} |
@endif
@endforeach
@else
| Teams Not Assigned |
@endif
@endsection
@php
$siteurl=$_SERVER['HTTP_HOST'];
//$url=explode(".",$siteurl); // crm.bpm360.net
@endphp