• Resolved webdesignkilkenny

    (@webdesignkilkenny)


    Hi guys,

    We’ve setup an attribute rule to map a value to GTIN…

    GTIN attribute:sp_wc_barcode_field

    This is working fine for simple products but it’s not pulling in the value for variable products.

    Any ideas?

    Thanks

    Eoin

Viewing 5 replies - 1 through 5 (of 5 total)
  • anastas10s

    (@anastas10s)

    Hi there @webdesignkilkenny ??

    Thank you for reaching out. I’d be happy to help you with this.

    We’ve setup an attribute rule to map a value to GTIN…

    GTIN attribute:sp_wc_barcode_field

    This is working fine for simple products but it’s not pulling in the value for variable products.

    Could you elaborate further on how the attribute mapping was set, please?

    Feel free to go ahead with sharing screenshot(s), also. https://snipboard.io/ is a tool we recommend for doing so.

    For reference, I’ll go ahead with linking to the related documentation here.

    Looking forward to hearing from you!

    Thread Starter webdesignkilkenny

    (@webdesignkilkenny)

    Hi Pepe,

    The 1st thing we did was to add the following to theme’s functions.php…

    add_filter(‘woocommerce_gla_attribute_mapping_sources_custom_attributes’,function( $values ) {return array_merge( $values, [‘sp_wc_barcode_field’]);});

    Then we mapped this field to the GTIN in the plugin – see https://snipboard.io/ncH0u1.jpg

    Using the plugin’s test page we deleted all products from the merchant center, waited a few minutes then resynced the products (to the merchant center)

    On viewing products in the merchant center we noticed that while the GTIN field was correctly set for simple products the GTIN field for variable products was emply – see https://snipboard.io/68B9G5.jpg

    Thanks

    Eoin

    anastas10s

    (@anastas10s)

    Hi there @webdesignkilkenny ??

    Kindly note that the filter added in the theme’s functions.php file is not covered by our support policy, I’m afraid.

    As an alternative, feel free to go ahead with utilizing the method described here for mapping GTIN.

    I hope this is helpful! Please let us know if you have any further questions or concerns.
    We will be happy to help you further.

    Thread Starter webdesignkilkenny

    (@webdesignkilkenny)

    Hi Pepe,

    The filter added in the theme’s functions.php is covered as Use Case 7 in your support documentation?

    We don’t use Yoast SEO.

    Regards,

    Eoin

    Plugin Support Shameem R. a11n

    (@shameemreza)

    Hi @webdesignkilkenny,

    The custom filter you added in your theme’s functions.php is indeed mentioned in our documentation as a use case. However, the support for custom code is limited as it falls outside the standard usage of our plugin and support policy.

    The issue you’re experiencing could be due to several factors. It might be worthwhile to ensure that the sp_wc_barcode_field is correctly set up for each variation of your variable products.

    If you continue to experience issues, I recommend asking development questions on the #developers channel of the WooCommerce Community Slack. Many of our developers hang out there and will be able to offer insights into your question. You can also seek help from the following:

    I wish I could help more, but hopefully, this gets you going in the right direction to get the job done.

Viewing 5 replies - 1 through 5 (of 5 total)
  • The topic ‘GTIN missing on variable products’ is closed to new replies.