As we changed approach for Tax Calculation in Return Transaction case (BudId#3831376). In changed approach now we are getting Tax values for items from DB in place of calculating them again and again.
So to check Return case in code we put a condition in which during Return Customer Order, a part of condition is failing which is passing for return from ‘Show Journal’ & ‘Return Transaction’ in MPOS.
Due to that Tax calculation is not appropriate for Customer Order Partial Return.
Earlier condition was
if ((salesLine != null && salesLine.Quantity <>
&& (this.TaxableEntity.IsReturnByReceipt || this.Transaction.IsReturnByReceipt))
Now to resolve the issue we removed that "IsReturnByReceipt" condition and now we are only using condition to check cart has a salesLine and salesLine.quantity is less than zero.
And at the same time we are also putting a condition to check if the return is related with any parent order, if return has not any parent transaction than its Tax calculation will be perform as it calculates earlier.
E.G Return product Retail Operation.
New condition is
if (salesLine != null && salesLine.Quantity < 0="" &&="" math.abs(salesline.returnquantity)=""> 0)
Article ID: 4025912 - Last Review: 2017, ജൂൺ 9 - Revision: 1