You are here

function wf_crm_webform_preprocess::__construct in Webform CiviCRM Integration 7.4

Same name and namespace in other branches
  1. 7.5 includes/wf_crm_webform_preprocess.inc \wf_crm_webform_preprocess::__construct()

File

includes/wf_crm_webform_preprocess.inc, line 17

Class

wf_crm_webform_preprocess

Code

function __construct(&$form, &$form_state) {
  civicrm_initialize();
  $this->form =& $form;
  $this->form_state =& $form_state;
  $this->node = $form['#node'];
  $this->settings = $this->node->webform_civicrm;
  $this->data = $this->settings['data'];
  $this->ent['contact'] = array();
  $this->all_fields = wf_crm_get_fields();
  $this->all_sets = wf_crm_get_fields('sets');
  $this->enabled = wf_crm_enabled_fields($this->node);
  $this->line_items = wf_crm_aval($form_state, 'civicrm:line_items', array());
}