how to scope count in multi-tenancy?
I use
However is also use
That is not scoped anymore (it counts all records).
How to resolve this?
Should i put double logic in my Model also?
Or i can use
tenant in my panel. It scopes records by user. Logic is in ApplyTenantScopes::class. And it works correctly.However is also use
count() in Resource getNavigationBadge():That is not scoped anymore (it counts all records).
How to resolve this?
Should i put double logic in my Model also?
Or i can use
ApplyTenantScopes::class (logic) in here somehow?