import v2.0.0.0_RC3 | 2012-07-01

https://github.com/lucanos/CommunityID -> http://www.itadmins.net/archives/357
This commit is contained in:
2019-07-17 22:31:04 +02:00
parent 38c146901c
commit 2f397f01f7
2677 changed files with 296182 additions and 45159 deletions

View File

@ -0,0 +1,40 @@
<?php
/*
* @copyright Copyright (C) 2005-2010 Keyboard Monkeys Ltd. http://www.kb-m.com
* @license http://creativecommons.org/licenses/BSD/ BSD License
* @author Keyboard Monkey Ltd
* @since CommunityID 0.9
* @package CommunityID
* @packager Keyboard Monkeys
*/
class ProfileController extends CommunityID_Controller_Action
{
public function indexAction()
{
$this->view->queryString = $this->_queryString();
$server = $this->_getOpenIdProvider();
$request = $server->decodeRequest();
$this->view->fields = array();
$this->view->policyUrl = false;
$profiles = new Users_Model_Profiles();
$this->view->profiles = $profiles->getForUser($this->user);
$requestedProfileId = $this->_getParam('profile');
foreach ($this->view->profiles as $profile) {
if ($requestedProfileId == 0 || $requestedProfileId == $profile->id) {
$this->view->profileId = $profile->id;
$personalInfoForm = Users_Form_PersonalInfo::getForm($request, $profile);
$this->view->fields = $personalInfoForm->getElements();
if ($personalInfoForm->getPolicyUrl()) {
$this->view->policyUrl = $personalInfoForm->getPolicyUrl();
}
break;
}
}
//$this->view->profiles->rewind();
}
}