/** * Build all the data structures needed to build the form. */ public function preProcess() { if (!CRM_Core_Permission::checkActionPermission('CiviCase', CRM_Core_Action::DELETE)) { CRM_Core_Error::fatal(ts('You do not have permission to access this page.')); } parent::preProcess(); }
/** * Build all the data structures needed to build the form. */ public function preProcess() { $this->skipOnHold = $this->skipDeceased = FALSE; parent::preProcess(); $this->setContactIDs(); CRM_Contact_Form_Task_PDFLetterCommon::preProcess($this); }
/** * Build all the data structures needed to build the form. * * @return void */ public function preProcess() { parent::preProcess(); $rows = array(); // display name and email of all contact ids $caseIDs = implode(',', $this->_caseIds); $statusId = CRM_Core_DAO::getFieldValue('CRM_Core_DAO_OptionGroup', 'case_status', 'id', 'name'); $query = "\nSELECT ct.display_name as display_name,\n cs.start_date as start_date,\n ov.label as status\n\nFROM civicrm_case cs\nINNER JOIN civicrm_case_contact cc ON ( cs.id = cc.case_id)\nINNER JOIN civicrm_contact ct ON ( cc.contact_id = ct.id)\nLEFT JOIN civicrm_option_value ov ON (cs.status_id = ov.value AND ov.option_group_id = {$statusId} )\nWHERE cs.id IN ( {$caseIDs} )"; $dao = CRM_Core_DAO::executeQuery($query, CRM_Core_DAO::$_nullArray); while ($dao->fetch()) { $rows[] = array('display_name' => $dao->display_name, 'start_date' => CRM_Utils_Date::customFormat($dao->start_date), 'status' => $dao->status); } $this->assign('rows', $rows); }
/** * build all the data structures needed to build the form * * @return void * @access public */ function preProcess() { parent::preProcess(); }