~fabiocbalbuquerque/sahana-agasti/web-services

« back to all changes in this revision

Viewing changes to lib/model/doctrine/agWebservicesPackage/sfGuardUserProfileTable.class.php

  • Committer: Clayton Kramer
  • Date: 2011-07-26 18:12:28 UTC
  • mto: (1.26.1 push-trunk)
  • mto: This revision was merged to the branch mainline in revision 25.
  • Revision ID: clayton.kramer@mail.cuny.edu-20110726181228-ldpybh717xkhuq25
Added event facilities export to webservices

Show diffs side-by-side

added added

removed removed

Lines of Context:
16
16
    {
17
17
        return Doctrine_Core::getTable('sfGuardUserProfile');
18
18
    }
19
 
    
20
 
    public function getByToken(array $parameters) 
21
 
    {
22
 
        $user = Doctrine_Core::getTable('sfGuardUserProfile')->findOneByToken($parameters['token']);
23
 
        if (!$user || !$user->getIsWebserviceClient() ||!$user->getIsActive())
24
 
        {
25
 
            throw new sfError404Exception(sprintf('Client with token "%s" does not exist or is not activated.', $parameters['token']));
26
 
        }
27
 
        return $user;
28
 
    }
29
19
}
 
 
b'\\ No newline at end of file'