commercetools / commercetools-sync-java

Java library for importing and syncing (taking care of changes) data into one or more commercetools projects from external data files or from another commercetools project.
https://commercetools.github.io/commercetools-sync-java
Apache License 2.0
32 stars 37 forks source link

CartDiscount sync ignore "stores" field #1160

Closed valtechtmn closed 9 months ago

valtechtmn commented 9 months ago

Hello,

I've been experimenting with CartDiscount sync lately and I've noticed that the "store" field is not synced. After some digging I can see that the toCartDiscountDrafts utility method uses : https://github.com/commercetools/commercetools-sync-java/blob/63f679cdf5e115165dd7f4cb3ac06b0f212d6ca7/src/main/java/com/commercetools/sync/cartdiscounts/utils/CartDiscountReferenceResolutionUtils.java#L78 Which doesn't add stores to the draft. Is that on purpose or an oversight ?

Thanks for your continued support.

valtechtmn commented 9 months ago

@lojzatran I know you are pretty active around here, any update on this ? We can manually add the store property to the created drafts if this is not going to be addressed.

lojzatran commented 9 months ago

Hello @valtechtmn,

Sorry for the late reply.

The reason there is no store field is that this field was added after we finished the cart discount sync. To add this field, we would need to add a sync for stores as well and it‘s not a quick task. If you need this, please create a support ticket: https://support.commercetools.com/. For now the fastest way is to add it manually as you suggested.

Thank you.