Add a way to get the primary table of an entity type from TableMappingInterface

Created on 11 April 2018, about 6 years ago
Updated 4 April 2023, about 1 year ago

Problem/Motivation

#2232465: Deprecate table names from entity definitions → will deprecate all the $entity_type->get(Base|Data|Revision|RevisionData)Table() methods, so we need to provide a replacement for them.

Proposed resolution

Add a getPrimaryTableName() method to TableMappingInterface.

Remaining tasks

Review/discuss.

User interface changes

Nope.

API changes

API addition, a new method on TableMappingInterface and an implementation in the default base class: DefaultTableMapping.

Data model changes

Nope.

📌 Task
Status

Needs work

Version

10.1 ✨

Component
Entity  →

Last updated 1 day ago

  • Maintained by
  • 🇬🇧United Kingdom @catch
  • 🇨🇭Switzerland @Berdir
  • 🇩🇪Germany @hchonov
Created by

🇷🇴Romania amateescu

Live updates comments and jobs are added and updated live.
  • Needs change record

    A change record needs to be drafted before an issue is committed. Note: Change records used to be called change notifications.

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.

  • The Needs Review Queue Bot → tested this issue. It either no longer applies to Drupal core, or fails the Drupal core commit checks. Therefore, this issue status is now "Needs work".

    Apart from a re-roll or rebase, this issue may need more work to address feedback in the issue or MR comments. To progress an issue, incorporate this feedback as part of the process of updating the issue. This helps other contributors to know what is outstanding.

    Consult the Drupal Contributor Guide → to find step-by-step guides for working with issues.

  • Status changed to Needs review over 1 year ago
  • 🇮🇳India arunkumark Coimbatore

    The patch has been rerolled for Drupal 10.1.x version.

  • Status changed to Needs work about 1 year ago
  • 🇺🇸United States smustgrave

    Not sure this is a major anymore.

    The new functions will need to be typehinted.

    Also change record will be needed to announce the new function.

Production build 0.69.0 2024