1
This commit is contained in:
@@ -203,7 +203,7 @@ class CustomerController
|
||||
$tagId = explode(',', $tagId);
|
||||
foreach ($tagId as $id) {
|
||||
$query->whereHas('tags', function($query) use ($id){
|
||||
$query->where('tag.id', $id);
|
||||
$query->where('tag_id', $id);
|
||||
});
|
||||
}
|
||||
}
|
||||
@@ -222,9 +222,12 @@ class CustomerController
|
||||
$query->onlyTrashed();
|
||||
}
|
||||
if ($seas == 'seas') {
|
||||
$query->withTrashed()();
|
||||
$query->withTrashed();
|
||||
}
|
||||
|
||||
$sql = str_replace(['?'], ['\'%s\''], $query->toSql());
|
||||
$fullSql = vsprintf($sql, $query->getBindings());
|
||||
var_dump($fullSql);
|
||||
$data = $query->paginate($perPage, ['*'], 'page', $page);
|
||||
|
||||
foreach ($data->items() as &$value) {
|
||||
@@ -232,6 +235,7 @@ class CustomerController
|
||||
if($seas == 'seas'){
|
||||
$value['phone'] = Util::mask($value['phone']);
|
||||
$value['email'] = Util::mask($value['email']);
|
||||
$value['WhatsApp'] = Util::mask($value['WhatsApp']);
|
||||
$value['seas_time'] = time()-strtotime($value['deleted_at']);
|
||||
}
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user