fix: updated logic for calculating tax_withholding_net_total in payment entry #42060
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
Issue:
Earlier TDS was deducted on base_tax_withholding_net_total even if the allocated amount is less than base_tax_withholding_net_total amount.
For eg:
PO = 100 + 18 = 118
Base Tax Withholding Net Total = 100
o/s amount = 118
Paid amount = 50
Net Total Amount= 100
Fix:
Now TDS will be deducted on net_payable_amount_before tax or allocated amount whichever is less.
For eg:
PO = 100 + 18 = 118
Base Tax Withholding Net Total = 100
1st Payment Entry
o/s amount = 118
Paid amount = 50
Net Base Tax Withholding Payable = 118-18 = 100
Net Total Amount= 50
2nd Payment Entry
o/s amount = 68
Paid amount = 60
Net Base Tax Withholding Payable = 68-18 = 50
Net Total Amount= 50
3rd Payment Entry
o/s amount = 8
Paid amount = 8
Net Base Tax Withholding Payable = 0
Net Total Amount= 0
Suppot Issue: https://support.frappe.io/helpdesk/tickets/17745