Migrate discount and discount_offer

Created on 29 August 2017, about 7 years ago
Updated 7 November 2023, about 1 year ago

Problem/Motivation

Both the commerce 1 discounts and discount_offer need a migration. Note that discounts are added as order items in D8, so it needed as part of line item migrations.

The source has discounts, discount offers and discount usage. These become promotions with a plugin for the type/details of the promotion.

Proposed resolution

Do not use field migrations for the fields on discounts. While nice to conform, some of these fields (date and one of the entityreferences) have settings that cause failures with core field migrations so let's just avoid that. Plus the promotion is a very different entity, so let's just migrate the values.
The migration yml has all the fields.
Skip discounts in C1 that do not map to a C2 promotion. These are

  • free_shipping
  • percent_off_shipping
  • shipping_upgrade

Remaining tasks

Migration working for non-shipping discounts
Investigate shipping discounts and then decide what to do next here.

User interface changes

N/A

API changes

N/A

Data model changes

N/A

πŸ“Œ Task
Status

Needs review

Version

4.0

Component

Drupal Commerce 1.x

Created by

πŸ‡³πŸ‡ΏNew Zealand quietone

Live updates comments and jobs are added and updated live.
Sign in to follow issues

Comments & Activities

Not all content is available!

It's likely this issue predates Contrib.social: some issue and comment data are missing.

Production build 0.71.5 2024