From af05126dac3415ce33e5187fb97b494b6cd330a8 Mon Sep 17 00:00:00 2001 From: Eileen McNaughton Date: Sat, 4 Jun 2022 21:15:34 +1200 Subject: [PATCH] Enotice fix Enotice fix --- CRM/Contact/Import/Parser/Contact.php | 2 ++ CRM/Member/Import/Form/MapField.php | 2 +- CRM/Member/Import/Parser/Membership.php | 2 ++ 3 files changed, 5 insertions(+), 1 deletion(-) diff --git a/CRM/Contact/Import/Parser/Contact.php b/CRM/Contact/Import/Parser/Contact.php index a1b98e4b71..83777cc257 100644 --- a/CRM/Contact/Import/Parser/Contact.php +++ b/CRM/Contact/Import/Parser/Contact.php @@ -77,6 +77,8 @@ class CRM_Contact_Import_Parser_Contact extends CRM_Import_Parser { * The initializer code, called before processing. */ public function init() { + // Force re-load of user job. + unset($this->userJob); $this->setFieldMetadata(); foreach ($this->getImportableFieldsMetadata() as $name => $field) { $this->addField($name, $field['title'], CRM_Utils_Array::value('type', $field), CRM_Utils_Array::value('headerPattern', $field), CRM_Utils_Array::value('dataPattern', $field), CRM_Utils_Array::value('hasLocationType', $field)); diff --git a/CRM/Member/Import/Form/MapField.php b/CRM/Member/Import/Form/MapField.php index 5d2ba587d8..795f392678 100644 --- a/CRM/Member/Import/Form/MapField.php +++ b/CRM/Member/Import/Form/MapField.php @@ -61,7 +61,7 @@ class CRM_Member_Import_Form_MapField extends CRM_Import_Form_MapField { foreach ($columnHeaders as $i => $columnHeader) { $sel = &$this->addElement('hierselect', "mapper[$i]", ts('Mapper for Field %1', array(1 => $i)), NULL); $jsSet = FALSE; - if ($this->get('savedMapping')) { + if ($this->getSubmittedValue('savedMapping')) { if (isset($mappingName[$i])) { if ($mappingName[$i] != ts('do_not_import')) { //When locationType is not set diff --git a/CRM/Member/Import/Parser/Membership.php b/CRM/Member/Import/Parser/Membership.php index 9ceda1d478..67fa939784 100644 --- a/CRM/Member/Import/Parser/Membership.php +++ b/CRM/Member/Import/Parser/Membership.php @@ -254,6 +254,8 @@ class CRM_Member_Import_Parser_Membership extends CRM_Import_Parser { * @return void */ public function init() { + // Force re-load of user job. + unset($this->userJob); $this->setFieldMetadata(); $this->_newMemberships = []; -- 2.25.1