else {
$savedMapping = $this->get('savedMapping');
- list($mappingName, $mappingContactType, $mappingLocation, $mappingPhoneType, $mappingRelation) = CRM_Core_BAO_Mapping::getMappingFields($savedMapping);
+ list($mappingName) = CRM_Core_BAO_Mapping::getMappingFields($savedMapping);
$mappingName = $mappingName[1];
- $mappingContactType = $mappingContactType[1];
- $mappingLocation = $mappingLocation['1'] ?? NULL;
- $mappingPhoneType = $mappingPhoneType['1'] ?? NULL;
- $mappingRelation = $mappingRelation['1'] ?? NULL;
//mapping is to be loaded from database
$parser->set($this);
}
+ /**
+ * @return \CRM_Member_Import_Parser_Membership
+ */
+ protected function getParser(): CRM_Member_Import_Parser_Membership {
+ if (!$this->parser) {
+ $this->parser = new CRM_Member_Import_Parser_Membership();
+ $this->parser->setUserJobID($this->getUserJobID());
+ $this->parser->init();
+ }
+ return $this->parser;
+ }
+
}