Andrew Wallo před 4 měsíci
rodič
revize
5076fd4b1c
1 změnil soubory, kde provedl 2 přidání a 0 odebrání
  1. 2
    0
      app/Services/ReportService.php

+ 2
- 0
app/Services/ReportService.php Zobrazit soubor

@@ -968,6 +968,7 @@ class ReportService
968 968
                 ->whereNotIn('status', [InvoiceStatus::Draft, InvoiceStatus::Void])
969 969
                 ->whereNotNull('approved_at')
970 970
                 ->whereNotNull('paid_at')
971
+                ->whereHas('client')
971 972
                 ->with(['client:id,name'])
972 973
                 ->get()
973 974
                 ->groupBy('client_id'),
@@ -975,6 +976,7 @@ class ReportService
975 976
                 ->whereBetween('date', [$startDate, $endDate])
976 977
                 ->whereNotIn('status', [BillStatus::Void])
977 978
                 ->whereNotNull('paid_at')
979
+                ->whereHas('vendor')
978 980
                 ->with(['vendor:id,name'])
979 981
                 ->get()
980 982
                 ->groupBy('vendor_id'),

Načítá se…
Zrušit
Uložit