For the items we have added price list, during creation of a sales order, for some customers we want to write a different price than the standard selling rate, when we do that it automatically gets calculated as ‘Discount Amount’ and gets displayed in the PDF also.
We dont want the customer to know that it is a discount. and hiding the field from print area is also not an option as for other customers we need sometimes to show that discount amount if given.
Is there anyway to disable this auto calculation of discount?
By far the easiest workaround: create 2 different Print Formats for Sales Orders and Sales Invoices:
- Show the discount.
- Do not show the discount.
Then later, when you print to PDF, choose the Print Format you want, depending on the Customer.
Otherwise, there is no easy way to alter the behavior of Price List Rate, Rate, and how the ERP displays the difference between the 2 values as “discounts”.
(Aside: I don’t like it either. I’ve spent nearly a hundred hours investigating, debugging, and hacking the Pricing Rule and Discount logic in ERPNext. It is not fun. I do not recommend altering, unless you have no other choice.)
I just found out that in Selling Settings we have an option called ‘Allow User to Edit Price List Rate in Transactions’ if you enable that, in the sales order after adding an item in items table, go to edit and you will find a field called ‘price list’, that field becomes editable now and if you change the value there, it will not count it as discount anymore.