mirror of https://github.com/MISP/MISP
fix: [user view] server issues fixed
parent
965b00d164
commit
8438db4565
|
@ -483,7 +483,8 @@ class UsersController extends AppController
|
|||
'conditions' => array('User.id' => $id),
|
||||
'contain' => array(
|
||||
'UserSetting',
|
||||
'Role'
|
||||
'Role',
|
||||
'Organisation'
|
||||
)
|
||||
));
|
||||
if (empty($user)) {
|
||||
|
@ -516,9 +517,9 @@ class UsersController extends AppController
|
|||
), $this->response->type());
|
||||
return $this->RestResponse->viewData(array('User' => $user['User']), $this->response->type());
|
||||
} else {
|
||||
$temp = $this->User->data['User']['invited_by'];
|
||||
$user2 = $this->User->find('first', array('conditions' => array('User.id' => $user['User']['invited_by']), 'recursive' => -1));
|
||||
$this->set('id', $id);
|
||||
$this->set('user2', $this->User->read(null, $temp));
|
||||
$this->set('user2', $user2);
|
||||
}
|
||||
}
|
||||
|
||||
|
|
|
@ -41,7 +41,7 @@ $buttonModifyStatus = $mayModify ? 'button_on':'button_off';
|
|||
'key' => __('Authkey'),
|
||||
'html' => $authkey_data
|
||||
);
|
||||
$table_data[] = array('key' => __('Invited By'), 'value' => $user2['User']['email']);
|
||||
$table_data[] = array('key' => __('Invited By'), 'value' => empty($user2['User']['email']) ? 'N/A' : $user2['User']['email']);
|
||||
$org_admin_data = array();
|
||||
foreach ($user['User']['orgAdmins'] as $orgAdminId => $orgAdminEmail) {
|
||||
$org_admin_data[] = sprintf(
|
||||
|
|
Loading…
Reference in New Issue