Problem/Motivation

Currently the "shipments" field is not present in the field names whitelist.
As a consequence, its relationship/field is not returned alongside the order.

Support from Acquia helps fund testing for Drupal Acquia logo

Comments

jsacksick created an issue. See original summary.

Pooja Ganjage’s picture

Hi,

I am applying patch for this issue.

Kindly review this patch once.

Thanks.

Pooja Ganjage’s picture

Status: Active » Needs review
mglaman’s picture

Status: Needs review » Reviewed & tested by the community

Thanks @ Pooja Ganjage!

diff --git a/modules/contrib/commerce_api/src/FieldAccess.php b/modules/contrib/commerce_api/src/FieldAccess.php
index d56a760..3f11ad7 100644
--- a/modules/contrib/commerce_api/src/FieldAccess.php
+++ b/modules/contrib/commerce_api/src/FieldAccess.php

The patch was generated incorrectly. It looks like the patch was generated from a different repository. Next time, make sure you are in the proper directly and it will apply :)

  • mglaman committed b71f10f on 8.x-1.x authored by Pooja Ganjage
    Issue #3162425 by Pooja Ganjage: Add "shipments" to the allowed field...
mglaman’s picture

Status: Reviewed & tested by the community » Fixed

🥳 Committed!

jsacksick’s picture

Status: Fixed » Needs work

The tests had to be updated as well, they're currently failing because this changes the payload...

jsacksick’s picture

Status: Needs work » Needs review
FileSize
9.1 KB

I'm wondering if this require Commerce shipping to be patched though, in which case, we need to commit the Commerce shipping patch from #3174306: Viewing shipments requires the "administer commerce_shipment" permission and require Commerce shipping dev until the next release is tagged.

jsacksick’s picture

FileSize
633 bytes

Attaching the "shipments" patch that applies.

  • jsacksick committed 3b56e90 on 8.x-1.x
    Issue #3162425 followup by jsacksick: Fix the tests broken since the...
jsacksick’s picture

Status: Needs review » Fixed

Committing since this fixes the broken tests.

Status: Fixed » Closed (fixed)

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