ODOO ->Login->Create Quotation->Apply Fixed Discount->Confirm Sale->Create Invoice->Validate->Register Payment.
Now refund the same invoice. When refund is processed for such an invoice having discount, the refund invoice does not account for the discounted amount, instead only the pre-discount amount gets refunded.
Following are the screen shots from QA04.
Invoice with Discount -
When the functionality of Discount with an amount (Fixed Discount under Discount Method) was being implemented, the column “discount_percentage”, “disc_acc_id”, “discount” and “discount_type” of the table “account_invoice” were not considered for the process flow of refund of the sales order.
Because of while refunding a sales order, the system could not identify if there was any discount (Fixed Discount under Discount Method) applied to the invoice.
@angshuonline I have raised a PR for this against ticket BAH-965