Merge pull request #12254 from akemidx/documentating_something

Commenting on a scope in Models/Company.php
This commit is contained in:
snipe 2022-12-19 12:41:32 -08:00 committed by GitHub
commit 88291cadc1
No known key found for this signature in database
GPG key ID: 4AEE18F83AFDEB23

View file

@ -73,6 +73,10 @@ final class Company extends SnipeModel
}
}
/**
* Scoping table queries, determining if a logged in user is part of a company, and only allows
* that user to see items associated with that company
*/
private static function scopeCompanyablesDirectly($query, $column = 'company_id', $table_name = null)
{
if (Auth::user()) {