Not Able to add another Field
-
Hi ,
we are using “Object Sync for Salesforce” Plugin for one of our client and successfully able to set-up a connection.
But we are facing a issue while adding the field’s. Please see the below link :
https://drive.google.com/file/d/1XiLBXrBFai_18J_tfcBnNBm4dC0Kkozk/view?usp=sharingWhen We click on the “add another field mapping” button then nothing is happening. tried with other browsers , cleared the cache.
For one field map that is shown in the screenshot , the records are coming in wordpress.Please help.
Regards ,
Apoorv Jain
-
@apoorv29 I have not been able to reproduce this. This button works with JavaScript, so that could be relevant. You say you’ve tried with other browsers – which browsers have you tried?
I would also recommend that you open the browser console and see if it shows any JavaScript errors.
Dear Jonathan
I have tried various ways as you suggest and in Chrome, Firefox, Internet Explorer and Opera. Not able to get it working to add more than one field mapping. The button “Add another field mapping” is showing no response, like the button has no functionality to do anything. Is there anything you can suggest to help us on this or some workaround to get the fields mapped. We have had our developer trying to resolve it and they don′t seem to be able to get it working. Could you or someone in your team assist with resolving it if we gave you access to the server?
Regards
Thor@thormag No, we don’t do that kind of assistance; MinnPost is a small nonprofit and it’s a free plugin.
Here’s what I would try, though:
1. Reinstall the plugin.
2. Make sure you’ve cleared the browser cache.
3. Turn on WordPress’ debug mode. If you’re not sure how to do that, you add this to wp-config.php:define( 'WP_DEBUG', true ); define( 'SCRIPT_DEBUG', true );
4. See if there are any error messages on your server, and/or in the plugin’s Logs. It’s possible the Salesforce API calls are returning errors, and they could be in one or both of those places.
5. Use the Firefox or Chrome inspector tool to see if there are JavaScript errors. The “add another field mapping” expects an Ajax response. If it is not working, it’s possible that either there is a JavaScript error, and/or an error in the response coming from your Salesforce API calls (see #4).If there’s something wrong in your installation, either in WordPress or in Salesforce itself, getting an error log is the best way to find out what it is.
Hi Jonathan,
I reinstalled it and started afresh. Also disabled plugins. In the end I found out that there is a conflict with Woocommerce. If Woocommerce is active I am not able to map multiple fields. Are you aware of this conflict with Woocommerce?
I created with Toolset Custom Post Object and I see the fields from there in the mapping. But they do not populate with data on the Custom Post. Would you know what could be the reason for this?
I also have tried using ACF plugin but then I do not see the fields in the mapping.
@thormag I’m not aware of any specific conflicts with WordPress. Object Sync for Salesforce does not intentionally support WooCommerce. What I mean by that is that WooCommerce does things in its own way; it doesn’t use default WordPress methods to create and work with data. So sometimes this plugin sees WooCommerce data and sometimes it needs to use developer hooks to get WooCommerce data (we have abundant developer hooks, and they’re decently documented in the docs folder). But I haven’t seen a case when WooCommerce would prevent mapping. I think you’ll need to get some server logs to figure that part out.
I am not at all familiar with Toolset Custom Post Object. But probably, it’s a similar situation. If data does not populate, it’s because the other plugin is working in a non-standard way from the way WordPress works by default. But if you have a developer, you can have them use the developer hooks in this plugin to build out this kind of support. The same with WooCommerce, of course. If you build such an extension, we’d happily link to it for other users to use, but since many people don’t use either of these plugins we don’t have any intention of building this full support directly into Object Sync for Salesforce.
As for ACF, it again uses its own methods, but Object Sync for Salesforce does work pretty well with ACF. If you don’t see the fields in the mapping, try the following:
1. Make sure there is at least one item that has values for the ACF fields you want to map. If they don’t have values in the database, they won’t show up in the mapping. That is, if you have an field called “test_field” on the User object, make sure there is at least one user that has a value for “test_field” before you try to map it.
2. Make sure you clear the plugin cache for Object Sync for Salesforce. You’ll see that link on the main Fieldmaps page (it says “Has your WordPress or Salesforce data structure changed? Clear the plugin cache to make sure you can map the most recent data structures.”)
3. In my testing, you’ll see ACF field names both with and without an underscore, because ACF creates both for its own purposes. As long as you map the ACF field that does not have the underscore in front of it into Object Sync for Salesforce, you should be fine. For example I have a test install that maps test_field to Contact_description. The fieldmap screen also has a _test_field in the dropdown because of how ACF works in its non-WordPress way, but I’ve found that I can safely ignore that one and it will work fine in both push and pull.Update how issue with Woocommerce issue was fixed. Perhaps you can implement something in future updates to avoid this conflict?
woocomerece is loading
jquery 1.2 version
in which all function all call through jQuery reference
but sale force plugin using great than 1.4 in which Reference variable is $ sign
the quick fix to copy jQuery Reference to $ but
its not working
then I download the Sale force JS file
and modify it
/wp-content/plugins/object-sync-for-salesforce/assets/js/object-sync-for-salesforce-admin.min.js?ver=1.2.7
also add
jQuery in the header
it will work
hopefully@thormag this sounds like you may be using an old version of WooCommerce, or of WordPress? Assigning $ to jQuery is a fairly common practice in WordPress, and as far as I’ve ever seen, it does not cause conflicts with WooCommerce or with other plugins. At least in current versions, WooCommerce itself does this (using
jQuery( function( $ ) {
which is slightly different than the way we do it, but same purpose.I’m still curious if you are getting JavaScript errors in your browser console. I’d like to see those, if you have them.
@thormag I think you’ll find that the most recent update of this plugin may fix your issue. I’ve noticed that some older plugins can cause the same conflict you reported, so I’ve gotten around it and it will stop happening.
I’m going to go ahead and close this issue, but do feel free to reopen it if you continue to have the issue after updating the plugin.
- The topic ‘Not Able to add another Field’ is closed to new replies.