id;
$returnName = $GLOBALS['current_user']->full_name;
if(!empty($_REQUEST['return_action']) && !empty($_REQUEST['return_module'])){
if('Users' == $_REQUEST['return_module']){
if('EditView' == $_REQUEST['return_action']){
$returnAction = 'EditView';
}
if(!empty($_REQUEST['return_name'])){
$returnName = $_REQUEST['return_name'];
}
if(!empty($_REQUEST['user_id'])){
$returnId = $_REQUEST['user_id'];
}
}
}
$this->_returnId = $returnId;
$iconPath = $this->getModuleTitleIconPath($this->module);
$params = array();
if (!empty($iconPath) && !$browserTitle) {
$params[] = "";
}
else {
$params[] = translate('LBL_MODULE_NAME','Users');
}
$params[] = "".$returnName."";
if($returnAction == 'EditView'){
$params[] = $GLOBALS['app_strings']['LBL_EDIT_BUTTON_LABEL'];
}
return $params;
}
/**
* @see SugarView::getModuleTitleIconPath()
*/
protected function getModuleTitleIconPath($module)
{
return parent::getModuleTitleIconPath('Users');
}
function display(){
$this->ss->assign('return_id', $this->_returnId);
if($GLOBALS['current_user']->is_admin || empty($this->bean) || empty($this->bean->id) || $this->bean->isOwner($GLOBALS['current_user']->id)){
parent::display();
} else {
ACLController::displayNoAccess();
}
}
}
?>