Make promotions and offers into fieldable entities

Created on 30 October 2023, over 1 year ago
Updated 17 November 2023, over 1 year ago

Right now promotions are not fieldable entities, and are not easily altered to store additional data in them.

This would not be a huge problem, but the promotion offers are not entities at all, and the data about which conditions the promotions applies to are thrown into serialized blobs, so it is impossible to query offers and promotions that match particular conditions.

Ideally, offers would be made into their own entities, with relations to things like product variations stored in actual data relationships so they can be queried. However, in the meantime making promotions into fieldable entities would allow them to have additional data added to them so they could be queried in cases like views filters.

Feature request
Status

Active

Version

2.0

Component

Contributed modules

Created by

🇺🇸United States mikemccaffrey

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

Comments & Activities

  • Issue created by @mikemccaffrey
  • First commit to issue fork.
  • 🇺🇸United States mikemccaffrey

    Here is a patch that adds a simple stub config page for promotions, so that the field api can add tabs to manage fields and the form/display settings.

  • 🇮🇱Israel jsacksick

    This started by a request to make promotion offer entities... But in the end you're patching Commerce to expose the field UI for the Promotion entity type...Should we repurpose this issue?

Production build 0.71.5 2024