Add a views field that allows showing adjustments filtered by type

Created on 7 November 2018, over 6 years ago
Updated 17 July 2025, 16 days ago

Spun off from Views support for adjustments Closed: won't fix since this doesn't require schema changes.

See https://github.com/drupalcommerce/commerce/pull/622/files for the initial code.

Feature request
Status

Active

Version

3.0

Component

Order

Created by

🇷🇸Serbia bojanz

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

Merge Requests

Comments & Activities

Not all content is available!

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

  • 🇺🇸United States TomTech
  • Pipeline finished with Success
    16 days ago
    Total: 858s
    #549837
  • 🇺🇸United States TomTech

    MR created that implements two field formatters for adjustments.

    One is separator based. The other displays as a table.

    Configuration options include specifying the adjustment type(s) to include, whether to display the label(s) of the adjustments, and currency options.

    We can consider the collectAdjustments as a followup enhancement.

  • 🇮🇱Israel jsacksick

    Thank you Tom for addressing this, retitling the issue.

    Tested this manually, works great! Only one minor comment regarding the Adjustment types setting. Just wondering whether we should use the label simply? Or if we stick with the plural label, perhaps we should uppercase the first character using ucfirst?

    I think everywhere else (e.g: when adding an adjustment from the order edit form) we simply use the label (which is singular).

  • Pipeline finished with Skipped
    16 days ago
    #550002
  • 🇮🇱Israel jsacksick

    Ok, went with the label for consistency. We might need a followup to call collectAdjustments() as it looks kinda odd to only display order level adjustments (which normally only contains shipping, shipping taxes and eventually shipping promotions). Other than that, all other adjustments are added to order items.
    But I'm fine with doing this as a followup, since this is already a big improvement as we don't have formatters for anything atm :).

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

Production build 0.71.5 2024