4a19c60ba2e393eb11c8e592b1f7c9eede55a948
ERPNext takes an Additional Discount off the items' net amounts and, for a discount on Grand Total, splits it between net and taxes: each charge is booked at tax_amount_after_discount_amount and Total Taxes and Charges sums those. The print showed the discount as entered and the pre-discount tax_amount, so on a Grand Total discount the VAT line disagreed with the invoice. The totals includes now print the discount's net share (sum of item.distributed_discount_amount), Net Total, and each charge after discount, so the lines add up to Grand Total whichever total the discount applies on and with inclusive or exclusive tax. A discount that is not distributed (cash / non-trade) stays after the charges.
Default Thai Company
Default Company Settings
Installation
You can install this app using the bench CLI:
cd $PATH_TO_YOUR_BENCH
bench get-app $URL_OF_THIS_REPO --branch develop
bench install-app default_thai_company
Thai language
Every string the app adds (custom field labels, messages, print format and letter head
text, Tax Withholding Category names) is translated in translations/th.csv; the same
file overrides the upstream Thai for the standard labels the print formats show. The
print formats embed Sarabun (public/fonts, OFL) so PDFs render Thai on servers
without a Thai system font. Switch a user or the print language to th to use it.
Contributing
This app uses pre-commit for code formatting and linting. Please install pre-commit and enable it for this repository:
cd apps/default_thai_company
pre-commit install
Pre-commit is configured to use the following tools for checking and formatting your code:
- ruff
- eslint
- prettier
- pyupgrade
License
gpl-3.0
Languages
Python
89.8%
HTML
7.9%
JavaScript
2.3%