diff --git a/loyalty_criteria_multi_product/migrations/16.0.1.0.0/pre-migration.py b/loyalty_criteria_multi_product/migrations/16.0.1.0.0/pre-migration.py index 6efc6d15..64c08928 100644 --- a/loyalty_criteria_multi_product/migrations/16.0.1.0.0/pre-migration.py +++ b/loyalty_criteria_multi_product/migrations/16.0.1.0.0/pre-migration.py @@ -19,10 +19,9 @@ def move_coupon_criteria_to_rule(env): env.cr, """ UPDATE loyalty_rule AS lr - SET loyalty_criteria = 'multi_product' + SET loyalty_criteria = lp.coupon_criteria FROM loyalty_program AS lp WHERE lr.program_id = lp.id - AND lp.coupon_criteria = 'multi_product' """, ) # coupon_criteria_ids to loyalty_criteria_ids