-
-
Notifications
You must be signed in to change notification settings - Fork 825
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
[REF] Remove handling for non-existent 'savedMapping' field #23283
Conversation
(Standard links)
|
@@ -288,68 +288,66 @@ public function buildQuickForm() { | |||
public static function formRule($fields, $files, $self) { | |||
$errors = []; | |||
|
|||
if (!array_key_exists('savedMapping', $fields)) { |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Remember to use w=1 to make this readable....https://github.com/civicrm/civicrm-core/pull/23283/files?w=1
I ran headlong into this when I was trying to create a function to submit imports via the command line. I started with the importCSV you are familiar with. So I had to unset this variable in the submittedFields before calling the forms post_process. |
@darrick it looks like this is stale so I would need to rebase to bring back to life - are you saying a rebased version of this SHOULD be merged? |
Also - I should note @darrick - my hope is that there will be a simple way to run the import in the end - the goal is that we can use the civicrm_queue table - which requires it to be easily runabe |
cd87d1c
to
90ea781
Compare
OK - it's rebased - if you are able to confirm you agree with the change I should be able to get someone to merge it |
@mlutfy do you feel you could merge this too? |
I did revisit this again last night as I was unsure exactly how forms were processed. I can confirm this PR does what is intended. |
@darrick ie - you are saying it should be merged? |
@eileenmcnaughton yes. |
Overview
[REF] Remove handling for non-existent 'savedMapping' field
Before
The
mapField
class has handling for the fieldsavedMapping
- however this field is NOT present on themapField
form - it IS present on theDataSource
form - but that isn't accessed by the mapField class - so I can't see any way the inside of the removed IF is reachable.MapField
does have the fieldsaveMapping
- the difference is not a typo - the field onDataSource
would ideally besaved_mapping_id
whereassaveMapping
is an instruction to save the mappingAfter
poof
Technical Details
This pattern is repeated across all the
MapField
classes so my analysis here is right then I can remove in the others tooComments
I did an r-run in the Membership import