Exemple #1
0
 public function getFacebookUser()
 {
     if ($this->getIdUser() === 0) {
         $profile = Application_Model_User_Profile::getByEmail($this->getUserEmail());
         if (!$profile instanceof Application_Model_User_Profile) {
             $profile = parent::_createProfile();
             $profile->setConfirmedEmail();
             $profile->save();
         } else {
             $this->setProfile($profile);
             $this->save();
         }
     } else {
         $profile = parent::getProfile();
     }
     return $profile;
 }
Exemple #2
0
 public function getAccounts()
 {
     $where = new RM_Query_Where();
     $where->add('idUser', RM_Query_Where::EXACTLY, $this->getId());
     return Application_Model_User_Account::getList($where, new RM_Query_Limits(2));
 }