Обновлен вывод сведений о жк в таблице
This commit is contained in:
parent
5bdbec2f16
commit
f8d30e4908
@ -100,10 +100,9 @@ function getClients()
|
||||
})
|
||||
->orderBy('deal_clients.id', 'desc')
|
||||
->with('deals');
|
||||
$clients = $clients->select('users.*');
|
||||
$clients = $clients->orderBy('name');
|
||||
$clients->select('users.id','users.name','users.phone','users.email');
|
||||
$clients->orderBy('name');
|
||||
$clients->join('deals', 'deal_clients.deal_id', '=', 'deals.id');
|
||||
|
||||
if (array_key_exists('status', $this->filter)) {
|
||||
$clients->where('deals.status', $this->filter['status']);
|
||||
}
|
||||
@ -129,7 +128,6 @@ function getClients()
|
||||
$query->whereIn('status', [DealStatus::MODERATION, DealStatus::NEW , DealStatus::NOT_UNIQUE]);
|
||||
});
|
||||
}
|
||||
//$clients = $clients->skip($this->currentPage)->take(10)->get();
|
||||
return $clients;
|
||||
}
|
||||
public function render()
|
||||
@ -139,6 +137,7 @@ public function render()
|
||||
$this->clientsCount = $clients->count();
|
||||
$this->currentPage = 1;
|
||||
};
|
||||
$clients->groupBy('users.id','users.name','users.phone','users.email');
|
||||
$clients = $clients->skip(($this->currentPage - 1) * $this->count)->take($this->count)->get();
|
||||
return view(
|
||||
'livewire.clients-table',
|
||||
|
||||
Loading…
Reference in New Issue
Block a user