"Shipping Charges - <abbr>": Selling, Fixed, posting to a "Shipping Charges" income account under Direct Income (created if the chart lacks it) with the default cost center. Shipping Rule is named by its label, so the company abbreviation keeps one rule per company, as ERPNext names its tax templates. Created on Company save, after install, and by a patch for existing companies. The amount is entered on the transaction, not the rule: ERPNext re-applies the rule on every recalculation and would reset the charge row to the rule's fixed amount. ThaiShippingRule overrides the doctype class so a Fixed rule with no amount only seeds the row and leaves the entered amount alone.
10 lines
441 B
Plaintext
10 lines
441 B
Plaintext
[pre_model_sync]
|
|
# Patches added in this section will be executed before doctypes are migrated
|
|
# Read docs to understand patches: https://frappeframework.com/docs/v14/user/en/database-migrations
|
|
|
|
[post_model_sync]
|
|
# Patches added in this section will be executed after doctypes are migrated
|
|
default_thai_company.patches.create_vat_accounts
|
|
default_thai_company.patches.create_vat_templates
|
|
default_thai_company.patches.create_shipping_rules
|