The current way of exporting discounts via Entity module directly makes discounts be deleted and recreated, resulting in their ids being changed and thus breaking relationship with promo codes.

Comments

recidive created an issue. See original summary.

recidive’s picture

Status: Active » Needs review
StatusFileSize
new3.41 KB

Attached patch fix this by overriding standard entities exporting and making it only update existing coupon codes, keeping discount/promo codes relationship.

recidive’s picture

Fixed inc file description.

recidive’s picture

Simplified how $discount->status is set.

recidive’s picture

Updated patch.

recidive’s picture

Updated patch.

rszrama’s picture

Status: Needs review » Reviewed & tested by the community

  • recidive committed d47f5a5 on 7.x-1.x
    Issue #3138654: Add support for exporting discounts.
    
recidive’s picture

Status: Reviewed & tested by the community » Fixed

Committed patch in #6.

Status: Fixed » Closed (fixed)

Automatically closed - issue fixed for 2 weeks with no activity.