Closed (won't fix)
Project:
Salesforce Suite
Version:
7.x-3.x-dev
Component:
salesforce_pull.module
Priority:
Normal
Category:
Task
Assigned:
Unassigned
Reporter:
Created:
29 Dec 2015 at 20:57 UTC
Updated:
21 Feb 2026 at 19:28 UTC
Jump to comment: Most recent, Most recent file
Comments
Comment #2
aaronbaumanrefactor attached
- reduced code by 34 lines
- reduced indent by 2 levels by adding helper function salesforce_pull_process_record()
Comment #3
aaronbaumanComment #4
asherry commentedSince this is a bit outdated, and so is a related issue which is #2694245: Multiple mapping for the same drupal entity, I'd like to propose a patch that incorporates some fixes for mappings, as well as dry-ing out the salesforce pull process in general.
I posted this patch here - https://www.drupal.org/node/2694245#comment-11903133, as well as a summary of the changes. For the projects we have this made it very easy to test one single mapping at a time, and I can post an example of that code if it's of interest.
Comment #5
asherry commentedHi Aaron, I wanted to share my approach to this. I forked the salesforce repo and have my commits in a separate branch in hopes that we can discuss the changes and see if maybe with a few tweaks I can get something that can get committed.
I feel like the most important functions to separate out were the actual entity update and entity insert parts of the code, and my first phase was just creating an external include. The next phase in my opinion should be creating a SalesforcePullRecord class which would be able to encapsulate those particular actions better.
https://github.com/FreeflowDigital/salesforce/tree/refactor-salesforce-pull
Comment #6
aaronbauman7.x is no longer supported