Log in
Model

RefundInvoice

Magento\Sales\Model\Order\Validation\RefundInvoice

What it does

This class validates whether a refund (credit memo) can be created against an invoice in Magento 2.

Developers use this validator when processing refunds to ensure the order can be refunded, the invoice is refundable, the credit memo totals are correct, and the item quantities are valid.

It aggregates multiple validation rules and returns a combined result indicating whether the refund operation should proceed.

Public Methods

  • validate()