useForSubpanel = true; $this->useModuleQuickCreateTemplate = true; } /** * @see SugarView::display() * * We are overridding the display method to manipulate the sectionPanels. * If portal is not enabled then don't show the Portal Information panel. */ public function display() { $this->ev->process(); if ( !empty($_REQUEST['contact_name']) && !empty($_REQUEST['contact_id']) && $this->ev->fieldDefs['report_to_name']['value'] == '' && $this->ev->fieldDefs['reports_to_id']['value'] == '') { $this->ev->fieldDefs['report_to_name']['value'] = $_REQUEST['contact_name']; $this->ev->fieldDefs['reports_to_id']['value'] = $_REQUEST['contact_id']; } $admin = new Administration(); $admin->retrieveSettings(); if(empty($admin->settings['portal_on']) || !$admin->settings['portal_on']) { unset($this->ev->sectionPanels[strtoupper('lbl_portal_information')]); } else { echo ''; echo ''; } echo $this->ev->display($this->showTitle); } }