@php
parse_str($data, $module);
$entId = (isset($module['entityId']) ? $module['entityId'] : false);
$news = DB::connection('mysql_site_' . session('serverID'))->table('posts')->where('site_id','=',$siteID)
->where(function ($query) use ($entId) { $query->where('categories', 'like', '%'.$entId.'%'); })
->orderBy('id','desc')->limit($module['quantity'])->get();
@endphp
@if($news->count() == 0)
Nenhum registro encontrado
@else
@foreach($news as $new)
{{ date('d/m/Y H:i',strtotime($new->created_at)) }}
{{ mb_strimwidth($new->title, 0, 125, "...") }}
@endforeach
@endif