Create getters for fields that should be available to use in alter hooks

Created on 19 June 2024, 5 months ago
Updated 20 June 2024, 5 months ago

Problem/Motivation

When altering transform objects in transform_alter hooks, there are objects that can't be fully or sufficiently altered.

Example

transform_alter hook for block_content entity type.

When trying to alter any field, its $fieldTransform variable is protected and does not have a getter function.

Proposed resolution

Add getter for $fieldTransform in FieldTransform class.

Data model changes

Addition of getter function.

📌 Task
Status

Active

Version

1.1

Component

Code

Created by

🇩🇰Denmark erik_petra

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

Comments & Activities

  • Issue created by @erik_petra
  • 🇩🇰Denmark LupusGr3y

    Transform API 1.1 does not return FieldTransform objects when transforming fields on entities, is this related to Transform API 1.0?

    Also can the issue not be resolved by a transform_alter on the field?

Production build 0.71.5 2024