[BUG] Sales Order shows incorrect net total after saving draft

While entering data in the Sales Order, it shows totals as below:

After saving the sales order, it shows net totals as below (which is incorrect):

In my scenario:
Gross Total = Rs.18352
VAT Rate = 20% (included in above price). Hence,
Net Total = Rs.15293.33

Apply Additional Discount on
Net Total = Rs.706

New Net Total = Rs.14587.33
VAT @20% = Rs.2917.47
New Gross Total = Rs.17505 (rounded)

During data entry, the ALL values are correctly shown. However, after saving the draft, the system incorrectly considers:

  • Gross Total as Net Total (it means Rs.18352 which was Gross Total, becomes Net Total)
  • Applies the additional discount of Rs.706 on Rs.18352 making Net Total as Rs.17646
  • Then applies VAT (20%) on the incorrect value of Rs.17646 making the Gross Total as Rs.21175.19

Is there any other member who is facing this issue? I’m on the latest version of ERPNext!


Regards
Saurabh

@ArundhatiS can you replicate this?

I just update my server to following versions:
ERPNext - v7.2.6
Frappe - v7.2.5

Unfortunately, the problem persists for me. I observed from GitHub, that as per the fix, test_sales_order.py file has been updated but not sales_order.py. Do I need to manually make changes on my server to make it work?


Regards
Saraubh