mirror of
https://gitlab.linphone.org/BC/public/flexisip-account-manager.git
synced 2026-01-17 10:08:05 +00:00
Fix FLEXIAPI-320 Domain filtering in statistics
This commit is contained in:
parent
ad8e520047
commit
f130380809
1 changed files with 2 additions and 2 deletions
|
|
@ -57,7 +57,7 @@ class StatisticsGraphFactory
|
|||
$fromQuery = StatisticsMessage::query();
|
||||
$toQuery = StatisticsMessage::query();
|
||||
|
||||
if (!Auth::user()?->isAdmin) {
|
||||
if (!Auth::user()?->admin) {
|
||||
$fromQuery->where('from_domain', space()->domain);
|
||||
$toQuery->toDomain($this->domain);
|
||||
} elseif ($this->domain) {
|
||||
|
|
@ -126,7 +126,7 @@ class StatisticsGraphFactory
|
|||
// Accounts doesn't have a from and to
|
||||
$this->domain = $this->domain ?? $this->fromDomain;
|
||||
|
||||
if (!Auth::user()?->isAdmin) {
|
||||
if (!Auth::user()?->admin) {
|
||||
$this->data->where('domain', space()->domain);
|
||||
} elseif ($this->domain) {
|
||||
$this->data->where('domain', $this->domain);
|
||||
|
|
|
|||
Loading…
Add table
Reference in a new issue