-
Notifications
You must be signed in to change notification settings - Fork 9.4k
Open
Labels
Issue: ready for confirmationTriage: Dev.ExperienceIssue related to Developer Experience and needs help with Triage to Confirm or Reject itIssue related to Developer Experience and needs help with Triage to Confirm or Reject it
Description
Magento\Sales\Model\Order\Payment is missing implementation of method getEntityId()
Preconditions
- Magento version : 2.4.7
Steps to reproduce
- Place an order.
- add event sales_order_payment_place to trigger some code.
- Attempt to retrieve the entity_id from the
sales_order_paymenttable using the following method in any class:
$order->getPayment()->getEntityId() from any class.
Expected result
The method should return the actual entity_id value from thesales_order_payment table.
Actual result
It returns NULL
Root Cause
Upon investigation, I found that:
The interface \Magento\Sales\Api\Data\OrderPaymentInterface declares the method getEntityId().
However, there is no implementation of this method in the class Magento\Sales\Model\Order\Payment.
For comparison:
The \Magento\Sales\Api\Data\OrderAddressInterface interface also declares getEntityId(), and its implementation exists in the class \Magento\Sales\Model\Order\Address.
Request
Could you please review this and consider adding the missing implementation for getEntityId() in Magento\Sales\Model\Order\Payment?
Thank you!
Metadata
Metadata
Assignees
Labels
Issue: ready for confirmationTriage: Dev.ExperienceIssue related to Developer Experience and needs help with Triage to Confirm or Reject itIssue related to Developer Experience and needs help with Triage to Confirm or Reject it
Type
Projects
Status
Ready for Confirmation