finished story 2.1 with qa test and added future recommendations for the dev
This commit is contained in:
@@ -133,6 +133,22 @@ class User extends Authenticatable
|
||||
return $query->whereIn('user_type', [UserType::Individual, UserType::Company]);
|
||||
}
|
||||
|
||||
/**
|
||||
* Scope to filter individual clients.
|
||||
*/
|
||||
public function scopeIndividual($query)
|
||||
{
|
||||
return $query->where('user_type', UserType::Individual);
|
||||
}
|
||||
|
||||
/**
|
||||
* Scope to filter company clients.
|
||||
*/
|
||||
public function scopeCompanies($query)
|
||||
{
|
||||
return $query->where('user_type', UserType::Company);
|
||||
}
|
||||
|
||||
/**
|
||||
* Scope to filter active users.
|
||||
*/
|
||||
|
||||
Reference in New Issue
Block a user