I have 4 tables:
- user
- particular
- pro
- advertiser
I have a table where i show the users data. in this table i have a column named Name where i use the code below
<td>
@if($user->pro))
{{$user->pro->company_name}}
@elseif($user->particular))
{{$user->particular->name." ".$user->particular->last_name}}
@elseif($user->advertiser)
{{$user->advertiser->company_name}}
@endif
</td>
So this column is popuplated from 3 different tables and different column. How can i sort this column table.