woocommerce / woocommerce-subscriptions-importer-exporter

Import your subscribers to WooCommerce from a CSV. Or export your subscription data from WooCommerce to CSV.
GNU General Public License v3.0
149 stars 57 forks source link

Missing coupon data #168

Open ghost opened 7 years ago

ghost commented 7 years ago

Hi, I've just set this up and tested a few exports on a site. Everything is coming through fine other than the coupons used data. (It's blank for all but one customer entry and there are definitely multiple customers that have used coupons, as I can cross reference them in the coupon reports section of WooCommerce).

Can you let me know what you need in order to look into this?

Thanks!

ghost commented 7 years ago

Anyone able to help with this?!

thenbrent commented 7 years ago

Can you let me know what you need in order to look into this?

Hey @joshmbedford, depending on your skill level, to fix that functionality you can either:

  1. attempt to fix the issue and submit a PR. As a head start, coupon line items should be added to the CSV here, but for some reason they clearly are not
  2. if you are not familiar enough with PHP/WC development, reach out to a Woo Expert with Subscriptions expertise to patch this and submit a pull request

We still haven't had time or resources to update the Importer for WooCommerce 3.0, so it is entirely possible the issue is caused by that if you are using it with that version. That will be a much larger job to fix.

glagonikas commented 6 years ago

Hi @joshmbedford not sure if you're experiencing the same issue like we did, but we've come across something similar in the past.

Upon further investigation, we realised that the plugin will only export coupons that are attached to Subscriptions (recurring discount, recurring % discount).

On the WooCommerce reports, you will see all coupons, including one-off coupons which are attached to the initial order instead of the subscription.

For our case, it wasn't a bug, but rather a limitation of the plugin, so we had to add some extra code to show all coupons, including one-off and could send a Pull Request if you think it'll help.