_contactType; $class::buildQuickForm($this, 2); } /** * Set defaults for the form. * * @return array */ public function setDefaultValues() { return parent::setDefaultValues(); } /** * Process the form. * * @return void */ public function postProcess() { $params = $this->exportValues(); // Process / save contact info $params['contact_type'] = $this->_contactType; $params['contact_id'] = $this->_contactId; if (!empty($this->_contactSubType)) { $params['contact_sub_type'] = $this->_contactSubType; } CRM_Contact_BAO_Contact::create($params); // Saving current employer affects relationship tab, and possibly related memberships and contributions $this->ajaxResponse['updateTabs'] = array( '#tab_rel' => CRM_Contact_BAO_Contact::getCountComponent('rel', $this->_contactId), ); if (CRM_Core_Permission::access('CiviContribute')) { $this->ajaxResponse['updateTabs']['#tab_contribute'] = CRM_Contact_BAO_Contact::getCountComponent('contribution', $this->_contactId); } if (CRM_Core_Permission::access('CiviMember')) { $this->ajaxResponse['updateTabs']['#tab_member'] = CRM_Contact_BAO_Contact::getCountComponent('membership', $this->_contactId); } $this->response(); } }