mirror of
https://github.com/snipe/snipe-it.git
synced 2024-12-24 21:24:13 -08:00
Commenting on a scope in Models/Company.php
This commit is contained in:
parent
29c2ff56ec
commit
133d6ffa50
|
@ -73,6 +73,10 @@ final class Company extends SnipeModel
|
|||
}
|
||||
}
|
||||
|
||||
/**
|
||||
* Adding scope to table queires, where only authorized users will be able to see a company's ID value
|
||||
*
|
||||
*/
|
||||
private static function scopeCompanyablesDirectly($query, $column = 'company_id', $table_name = null)
|
||||
{
|
||||
if (Auth::user()) {
|
||||
|
|
Loading…
Reference in a new issue