diff options
author | Chris Cornutt <chris.cornutt@hp.com> | 2015-01-16 15:41:01 -0600 |
---|---|---|
committer | Chris Cornutt <chris.cornutt@hp.com> | 2015-01-16 15:41:01 -0600 |
commit | 413aba0c02f70ef5eb02f9dcaed523405665ced7 (patch) | |
tree | d49e0d7f9e8f74215358ab736bd8949731747a46 /src | |
parent | 1b040e5a7e535f9a710f38828e286d83a91ab843 (diff) | |
download | gatekeeper-413aba0c02f70ef5eb02f9dcaed523405665ced7.zip gatekeeper-413aba0c02f70ef5eb02f9dcaed523405665ced7.tar.gz gatekeeper-413aba0c02f70ef5eb02f9dcaed523405665ced7.tar.bz2 |
removing the findByUserId from Permission collection, moved to findByUserId
Diffstat (limited to 'src')
-rw-r--r-- | src/Psecio/Gatekeeper/PermissionCollection.php | 20 |
1 files changed, 0 insertions, 20 deletions
diff --git a/src/Psecio/Gatekeeper/PermissionCollection.php b/src/Psecio/Gatekeeper/PermissionCollection.php index bd5f532..799abe4 100644 --- a/src/Psecio/Gatekeeper/PermissionCollection.php +++ b/src/Psecio/Gatekeeper/PermissionCollection.php @@ -5,26 +5,6 @@ namespace Psecio\Gatekeeper; class PermissionCollection extends \Psecio\Gatekeeper\Collection\Mysql { /** - * Find the permissions for a given user ID - * - * @param integer $userId User ID - */ - public function findByUserId($userId) - { - $data = array('userId' => $userId); - $sql = 'select p.* from permissions p, user_permission up' - .' where p.id = up.permission_id' - .' and up.user_id = :userId'; - - $results = $this->getDb()->fetch($sql, $data); - - foreach ($results as $result) { - $perm = new PermissionModel($this->getDb(), $result); - $this->add($perm); - } - } - - /** * Find the permissions for the given group ID * * @param integer $groupId Group ID |