• Resolved oscardodo

    (@oscardodo)


    Hi.

    I have the premium extension to get wordpress users and automate creation of a CRM customer (WordPress Utilities). I noticed that this module is very basic and only imports email, name and surname. I’ve modificaded de code of the module to be able to import user fields like address and phone, through a $customer_array = array (‘zbsc_whatever’ = whatever field on woocommerce) but I have a problem to import the name company. I use the array ‘zbsc_company’ but nothing happens. Is there another array for this field so I can get the company name of a new user that is registering on my ecommerce?

    Thanks in advance.

Viewing 2 replies - 1 through 2 (of 2 total)
  • Plugin Support Stef (a11n)

    (@erania-pinnera)

    Hi there,

    Any customizations of our features and extensions will fall outside the scope of our support. Let me check with the developers if there’s any room for assistance for such case.

    I will follow-up with you as soon as I have updates. Thanks!

    (for internal use – that GH Issue 3511)

    Plugin Support Stef (a11n)

    (@erania-pinnera)

    Hi there, @oscardodo,

    <span style=”box-sizing: border-box; margin: 0px; padding: 0px;”>I have some updates for you! I can confirm that your question falls outside the?scope of our support.?However, our developers could share a bit about it to point you in the right direction</span>.?

    To retrieve the company details of a given contact, you need to check their relationship in the wp_zbs_object_links table. The zbsol_objtype_from column should be 1 (where 1 is the object code for CONTACT), and ZBS_TYPE_COMPANY should be 2 (where 2 is the object code for COMPANY). The zbsol_objid_from column should match the ID of your contact.

    Example: To retrieve the company name for a contact with an ID of 10, you can use the following SQL query:

    SELECT
      zbsco_name
    FROM wp_zbs_companies
    WHERE ID IN 
    (
      SELECT DISTINCT zbsol_objid_to 
      FROM wp_zbs_object_links
      WHERE
      zbsol_objtype_from = 1
      AND zbsol_objtype_to = 2
      AND zbsol_objid_from = 10
    )

    Hope that helps! Please note that given the nature of your request, we won’t be able to provide any more detailed support, but we hope this is something you can start working from!

Viewing 2 replies - 1 through 2 (of 2 total)
  • You must be logged in to reply to this topic.