Files
kimai2/src/Repository/Query/UserQuery.php
Kevin Papst cd7cbeae88 improved code styles #158 (#172)
* use php-cs-fixer instead of phpcodesniffer
* updated scrutinizer config
* adjusted code yules to all files
* updated CONTRIBUTING guidelines
2018-06-22 21:09:10 +02:00

43 lines
757 B
PHP

<?php
/*
* This file is part of the Kimai time-tracking app.
*
* For the full copyright and license information, please view the LICENSE
* file that was distributed with this source code.
*/
namespace App\Repository\Query;
/**
* Can be used for advanced queries with the: UserRepository
*/
class UserQuery extends VisibilityQuery
{
/**
* @var string
*/
protected $role;
/**
* @return string
*/
public function getRole()
{
return $this->role;
}
/**
* @param string $role
* @return UserQuery
*/
public function setRole($role)
{
if (false !== strpos($role, 'ROLE_') || null === $role) {
$this->role = $role;
}
return $this;
}
}