@classytic/ledger-bd 0.3.1 → 0.5.1

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
package/dist/index.mjs CHANGED
@@ -1,4 +1,4 @@
1
- import { defineCountryPack } from "@classytic/ledger";
1
+ import { ACCOUNT_PURPOSE, defineCountryPack } from "@classytic/ledger";
2
2
  //#region src/accounts/assets.ts
3
3
  const A$2 = "Balance Sheet-Asset";
4
4
  const CURRENT_ASSETS = [
@@ -6162,6 +6162,21 @@ function tdsLiability(code, name, description, meta) {
6162
6162
  taxMetadata: meta
6163
6163
  };
6164
6164
  }
6165
+ function subAsset(parentCode) {
6166
+ return (code, name, description, meta) => ({
6167
+ code,
6168
+ name,
6169
+ category: A$1,
6170
+ description,
6171
+ parentCode,
6172
+ isTotal: false,
6173
+ cashFlowCategory: "Operating",
6174
+ taxMetadata: meta
6175
+ });
6176
+ }
6177
+ const aitAsset = subAsset("1151");
6178
+ const tdsAsset = subAsset("1152");
6179
+ const vdsAsset = subAsset("1153");
6165
6180
  const VAT_LIABILITY_ACCOUNTS = [
6166
6181
  taxLiability("2132.VAT15.COLLECTED", "VAT Collected (15%)", "Standard rate VAT collected on sales at 15%.", {
6167
6182
  taxType: "VAT",
@@ -6183,7 +6198,27 @@ const VAT_LIABILITY_ACCOUNTS = [
6183
6198
  rate: .05,
6184
6199
  direction: "collected"
6185
6200
  }),
6186
- taxLiability("2132.TOT4.COLLECTED", "Turnover Tax Collected (4%)", "Turnover tax collected at 4%.", {
6201
+ taxLiability("2132.VAT4.5.COLLECTED", "VAT Collected (4.5%)", "Reduced rate VAT collected at 4.5% (real estate >1,600 sqft).", {
6202
+ taxType: "VAT",
6203
+ rate: .045,
6204
+ direction: "collected"
6205
+ }),
6206
+ taxLiability("2132.VAT2.4.COLLECTED", "VAT Collected (2.4%)", "Reduced rate VAT collected at 2.4% (medicine trading stage).", {
6207
+ taxType: "VAT",
6208
+ rate: .024,
6209
+ direction: "collected"
6210
+ }),
6211
+ taxLiability("2132.VAT2.COLLECTED", "VAT Collected (2%)", "Reduced rate VAT collected at 2% (petroleum trading / real estate ≤1,600 sqft).", {
6212
+ taxType: "VAT",
6213
+ rate: .02,
6214
+ direction: "collected"
6215
+ }),
6216
+ taxLiability("2132.VAT1.5.COLLECTED", "VAT Collected (1.5%)", "Reduced rate VAT collected at 1.5% (wholesale trading stage).", {
6217
+ taxType: "VAT",
6218
+ rate: .015,
6219
+ direction: "collected"
6220
+ }),
6221
+ taxLiability("2132.TOT4.COLLECTED", "Turnover Tax Collected (4%)", "Turnover tax collected at 4% (pre-FY2026-27 percentage model; FY2026-27+ turnover tax is a fixed assessed amount — post it here too).", {
6187
6222
  taxType: "TOT",
6188
6223
  rate: .04,
6189
6224
  direction: "collected"
@@ -6206,57 +6241,95 @@ const VAT_ASSET_ACCOUNTS = [taxAsset("1150.VAT15.INPUT", "VAT Input Credit (15%)
6206
6241
  isContraAccount: true
6207
6242
  })];
6208
6243
  const TDS_LIABILITY_ACCOUNTS = [
6209
- tdsLiability("2135.TDS.CONT", "TDS on Contractors", "TDS deducted from contractor payments (2-7%).", {
6244
+ tdsLiability("2135.TDS.CONT", "TDS on Contractors / Supply", "TDS deducted from contractor/supply/manufacturing payments — flat 5% (ITA 2023 s.89).", {
6210
6245
  taxType: "TDS",
6211
6246
  rate: .05,
6212
6247
  direction: "collected"
6213
6248
  }),
6214
- tdsLiability("2135.TDS.PROF", "TDS on Professional Fees", "TDS deducted from professional fee payments (10%).", {
6249
+ tdsLiability("2135.TDS.PROF", "TDS on Professional Fees", "TDS deducted from professional fees 7.5% entities / 15% natural persons (ITA 2023 s.90).", {
6215
6250
  taxType: "TDS",
6216
- rate: .1,
6251
+ rate: .075,
6217
6252
  direction: "collected"
6218
6253
  }),
6219
- tdsLiability("2135.TDS.RENT", "TDS on Rent", "TDS deducted from rent payments (3-5%).", {
6254
+ tdsLiability("2135.TDS.TECH", "TDS on Technical Service Fees", "TDS deducted from technical service / know-how fees — 10% (ITA 2023 s.90).", {
6220
6255
  taxType: "TDS",
6221
- rate: .05,
6256
+ rate: .1,
6222
6257
  direction: "collected"
6223
6258
  }),
6224
- tdsLiability("2135.TDS.INT", "TDS on Interest", "TDS deducted from interest payments (10%).", {
6259
+ tdsLiability("2135.TDS.RENT", "TDS on Rent", "TDS deducted from rent payments 10% (ITA 2023 s.109).", {
6225
6260
  taxType: "TDS",
6226
6261
  rate: .1,
6227
6262
  direction: "collected"
6228
6263
  }),
6229
- tdsLiability("2135.TDS.DIV", "TDS on Dividends", "TDS deducted from dividend payments (10%).", {
6264
+ tdsLiability("2135.TDS.INT", "TDS on Interest", "TDS deducted from interest payments — 20% companies / 10% individuals (ITA 2023 s.102).", {
6230
6265
  taxType: "TDS",
6231
- rate: .1,
6266
+ rate: .2,
6232
6267
  direction: "collected"
6233
6268
  }),
6234
- tdsLiability("2135.TDS.COMM", "TDS on Commission", "TDS deducted from commission payments (10%).", {
6269
+ tdsLiability("2135.TDS.DIV", "TDS on Dividends", "TDS deducted from dividend payments — 20% companies / 10% resident individuals (ITA 2023 s.117).", {
6270
+ taxType: "TDS",
6271
+ rate: .2,
6272
+ direction: "collected"
6273
+ }),
6274
+ tdsLiability("2135.TDS.COMM", "TDS on Commission", "TDS deducted from commission payments — 10% (ITA 2023 s.94).", {
6235
6275
  taxType: "TDS",
6236
6276
  rate: .1,
6237
6277
  direction: "collected"
6238
6278
  }),
6239
- tdsLiability("2135.TDS.ADV", "TDS on Advertising", "TDS deducted from advertising payments (3-4%).", {
6279
+ tdsLiability("2135.TDS.ADV", "TDS on Media Advertising", "TDS deducted from media advertising bill payments — 5% (ITA 2023 s.92).", {
6240
6280
  taxType: "TDS",
6241
- rate: .04,
6281
+ rate: .05,
6242
6282
  direction: "collected"
6243
6283
  }),
6244
- tdsLiability("2135.TDS.IMP", "AIT on Imports", "Advance income tax on imports (3-5%).", {
6284
+ tdsLiability("2135.TDS.TRANSPORT", "TDS on Transport / Ride-Sharing", "TDS deducted from transport / ride-sharing / sharing-economy payments — 2% from FY2026-27.", {
6285
+ taxType: "TDS",
6286
+ rate: .02,
6287
+ direction: "collected"
6288
+ }),
6289
+ tdsLiability("2135.TDS.IMP", "AIT on Imports (withheld)", "Advance income tax collected at customs stage — 5% general (ITA 2023 s.120).", {
6245
6290
  taxType: "TDS",
6246
6291
  rate: .05,
6247
6292
  direction: "collected"
6248
6293
  })
6249
6294
  ];
6250
- const VDS_LIABILITY_ACCOUNTS = [taxLiability("2136.VDS.COLLECTED", "VDS Collected", "VAT deducted at source from payments.", {
6295
+ const VDS_LIABILITY_ACCOUNTS = [taxLiability("2136.VDS.COLLECTED", "VDS Collected", "VAT deducted at source from supplier payments (VDS Rules 2025 — settled via increasing adjustment in own Mushak 9.1 when registered).", {
6251
6296
  taxType: "VDS",
6252
6297
  rate: .15,
6253
6298
  direction: "collected"
6254
6299
  })];
6300
+ const TAX_RECEIVABLE_ACCOUNTS = [
6301
+ aitAsset("1151.AIT.IMPORT", "AIT Paid at Import", "Advance income tax paid at customs stage (ITA 2023 s.120) — adjustable against assessed tax.", {
6302
+ taxType: "TDS",
6303
+ rate: .05,
6304
+ direction: "recoverable"
6305
+ }),
6306
+ aitAsset("1151.AIT.OTHER", "Advance Income Tax — Other", "Advance income tax paid under ss.154-158 (quarterly installments) and other AIT heads.", {
6307
+ taxType: "TDS",
6308
+ rate: 0,
6309
+ direction: "recoverable"
6310
+ }),
6311
+ tdsAsset("1152.TDS.SUFFERED", "TDS Suffered (withheld by customers)", "Income tax customers/payers deducted from our receipts — adjustable/refundable from FY2026-27 (minimum-tax withdrawal).", {
6312
+ taxType: "TDS",
6313
+ rate: 0,
6314
+ direction: "recoverable"
6315
+ }),
6316
+ vdsAsset("1153.VDS.SUFFERED", "VDS Suffered (Mushak 6.6 received)", "VAT withholding entities deducted from our supplies — decreasing adjustment in our Mushak 9.1 within 6 tax periods.", {
6317
+ taxType: "VDS",
6318
+ rate: 0,
6319
+ direction: "recoverable"
6320
+ }),
6321
+ vdsAsset("1153.AT.IMPORT", "Advance VAT (AT) Paid at Import", "Advance VAT paid at customs (7.5% commercial / 2% manufacturer) — decreasing adjustment in Mushak 9.1.", {
6322
+ taxType: "VAT",
6323
+ rate: .075,
6324
+ direction: "recoverable"
6325
+ })
6326
+ ];
6255
6327
  const ALL_TAX_ACCOUNTS = [
6256
6328
  ...VAT_LIABILITY_ACCOUNTS,
6257
6329
  ...VAT_ASSET_ACCOUNTS,
6258
6330
  ...TDS_LIABILITY_ACCOUNTS,
6259
- ...VDS_LIABILITY_ACCOUNTS
6331
+ ...VDS_LIABILITY_ACCOUNTS,
6332
+ ...TAX_RECEIVABLE_ACCOUNTS
6260
6333
  ];
6261
6334
  //#endregion
6262
6335
  //#region src/accounts/codes.ts
@@ -6320,6 +6393,10 @@ const BD_ACCOUNT_CODES = {
6320
6393
  INTER_BRANCH_RECEIVABLE: "1145",
6321
6394
  VAT_RECEIVABLE: "1150",
6322
6395
  ADVANCE_INCOME_TAX: "1151",
6396
+ /** 1152 — TDS Receivable. Income tax deducted at source by our customers/payers. */
6397
+ TDS_RECEIVABLE: "1152",
6398
+ /** 1200 — Advance Tax / VAT paid to government (offsettable at filing). */
6399
+ ADVANCE_TAX_PAID: "1200",
6323
6400
  /**
6324
6401
  * 1153 — VDS Receivable. The portion of output VAT withheld by a
6325
6402
  * designated buyer (govt entity / large corporate) and deposited to
@@ -6397,6 +6474,8 @@ const BD_ACCOUNT_CODES = {
6397
6474
  CUSTOMER_ADVANCE: "2191",
6398
6475
  INCOME_TAX_PAYABLE: "2131",
6399
6476
  VAT_OUTPUT_PAYABLE: "2132",
6477
+ /** 2133 — Supplementary Duty (SD) Payable on specified goods/services. */
6478
+ SD_OUTPUT_PAYABLE: "2133",
6400
6479
  TDS_PAYABLE: "2135",
6401
6480
  /**
6402
6481
  * 2136 — VDS Payable. Amount we must remit to NBR when we withhold VDS
@@ -6405,6 +6484,10 @@ const BD_ACCOUNT_CODES = {
6405
6484
  */
6406
6485
  VDS_PAYABLE: "2136",
6407
6486
  SALES_REVENUE: "4111",
6487
+ /** 4114 — Sales Returns & Allowances. Contra-revenue for customer returns. */
6488
+ SALES_RETURNS: "4114",
6489
+ /** 4115 — Sales Discount. Contra-revenue for cash / settlement discounts given. */
6490
+ SALES_DISCOUNT: "4115",
6408
6491
  /**
6409
6492
  * 4147 — Transport / Freight Revenue. When delivery is sold as a
6410
6493
  * line-item (Tk 60 delivery charge on the invoice) instead of being
@@ -6450,6 +6533,8 @@ const BD_ACCOUNT_CODES = {
6450
6533
  INVENTORY_GAIN: "4317",
6451
6534
  /** 5111 — Cost of Goods Sold — Raw Materials */
6452
6535
  COGS_MATERIALS: "5111",
6536
+ /** 5503 — Purchase Returns & Allowances. Contra-COGS for returns to vendors. */
6537
+ PURCHASE_RETURNS: "5503",
6453
6538
  /**
6454
6539
  * 5116 — Import Cost (duty + freight + insurance). Capitalized to
6455
6540
  * inventory at landed cost. Use this when a CIF/FOB import flow needs
@@ -6588,6 +6673,264 @@ const BD_ACCOUNT_CODES = {
6588
6673
  SHRINKAGE: "6711"
6589
6674
  };
6590
6675
  //#endregion
6676
+ //#region src/accounts/account-rules.ts
6677
+ /**
6678
+ * Bangladesh default account-resolution ruleset.
6679
+ *
6680
+ * Ships the "smart defaults" a BD deployment gets for free: which expense
6681
+ * account a bill line lands on from its description keywords or a picked
6682
+ * category, which cash/clearing account a payment method maps to, and which
6683
+ * inventory account a stock type uses. Consumed by `createAccountResolver`
6684
+ * (`@classytic/ledger`); the host layers DB-configured overrides on top with
6685
+ * `mergeAccountConfig`, and any line can still carry an explicit accountCode
6686
+ * that bypasses resolution entirely (the accountant escape hatch).
6687
+ *
6688
+ * These are DEFAULTS, not law — every rule is data a deployment can override
6689
+ * without a code change. The matcher is the primitives condition DSL, so a
6690
+ * keyword rule reads `keywords contains 'poster'`.
6691
+ *
6692
+ * Resolution CONTEXT the host is expected to pass (all optional):
6693
+ * - `keywords: string[]` — normalized tokens from the line description
6694
+ * - `category: string` — an explicit user-picked expense category
6695
+ * - `paymentMethod: string`— for the `cash` purpose (cash/card/bkash/bank…)
6696
+ * - `inventoryType: string`— for the `inventory` purpose
6697
+ */
6698
+ /**
6699
+ * An expense keyword rule: matches when the line's `keywords` array contains
6700
+ * ANY of `words`. Keyword rules sit at priority 10 — above category rules (5)
6701
+ * so a specific word ("poster") beats a broad category ("marketing").
6702
+ */
6703
+ function keywordExpense(id, words, use, label) {
6704
+ return {
6705
+ id,
6706
+ purpose: ACCOUNT_PURPOSE.EXPENSE,
6707
+ priority: 10,
6708
+ use,
6709
+ label,
6710
+ when: { any: words.map((w) => ({
6711
+ field: "keywords",
6712
+ op: "contains",
6713
+ value: w
6714
+ })) }
6715
+ };
6716
+ }
6717
+ /** A category rule: matches an explicit picked category (priority 5). */
6718
+ function categoryExpense(id, category, use, label) {
6719
+ return {
6720
+ id,
6721
+ purpose: ACCOUNT_PURPOSE.EXPENSE,
6722
+ priority: 5,
6723
+ use,
6724
+ label,
6725
+ when: {
6726
+ field: "category",
6727
+ op: "eq",
6728
+ value: category
6729
+ }
6730
+ };
6731
+ }
6732
+ const BD_ACCOUNT_RULES = {
6733
+ rules: [
6734
+ keywordExpense("bd-print", [
6735
+ "print",
6736
+ "printing",
6737
+ "poster",
6738
+ "card",
6739
+ "cards",
6740
+ "stationery",
6741
+ "flyer",
6742
+ "banner",
6743
+ "brochure",
6744
+ "invitation"
6745
+ ], "6301", "Printing & Stationery"),
6746
+ keywordExpense("bd-venue", [
6747
+ "hall",
6748
+ "venue",
6749
+ "event",
6750
+ "entertainment",
6751
+ "hospitality",
6752
+ "catering",
6753
+ "conference",
6754
+ "seminar",
6755
+ "reception"
6756
+ ], "6803", "Entertainment / Hospitality"),
6757
+ keywordExpense("bd-digital", [
6758
+ "facebook",
6759
+ "google",
6760
+ "seo",
6761
+ "digital",
6762
+ "social",
6763
+ "boost",
6764
+ "adwords",
6765
+ "meta"
6766
+ ], "6402", "Digital Marketing"),
6767
+ keywordExpense("bd-advert", [
6768
+ "advert",
6769
+ "advertisement",
6770
+ "publicity",
6771
+ "promo",
6772
+ "promotion",
6773
+ "campaign",
6774
+ "billboard",
6775
+ "signage"
6776
+ ], "6401", "Advertisement & Publicity"),
6777
+ keywordExpense("bd-rent", ["rent", "lease"], "6201", "Office Rent"),
6778
+ keywordExpense("bd-repair", [
6779
+ "repair",
6780
+ "maintenance",
6781
+ "servicing",
6782
+ "refurbish"
6783
+ ], "6207", "Office Repairs & Maintenance"),
6784
+ keywordExpense("bd-legal", [
6785
+ "legal",
6786
+ "lawyer",
6787
+ "professional",
6788
+ "consultant",
6789
+ "consulting",
6790
+ "audit",
6791
+ "accounting",
6792
+ "notary"
6793
+ ], "6309", "Legal Fee & Professional Charges"),
6794
+ keywordExpense("bd-travel", [
6795
+ "travel",
6796
+ "conveyance",
6797
+ "taxi",
6798
+ "uber",
6799
+ "pathao",
6800
+ "transport",
6801
+ "fare",
6802
+ "ticket"
6803
+ ], "6414", "Travel & Conveyance"),
6804
+ keywordExpense("bd-fuel", [
6805
+ "fuel",
6806
+ "petrol",
6807
+ "diesel",
6808
+ "octane",
6809
+ "lubricant"
6810
+ ], "6807", "Fuel & Lubricants"),
6811
+ categoryExpense("bd-cat-printing", "printing", "6301", "Printing & Stationery"),
6812
+ categoryExpense("bd-cat-venue", "venue", "6803", "Entertainment / Hospitality"),
6813
+ categoryExpense("bd-cat-marketing", "marketing", "6401", "Advertisement & Publicity"),
6814
+ categoryExpense("bd-cat-rent", "rent", "6201", "Office Rent"),
6815
+ categoryExpense("bd-cat-repairs", "repairs", "6207", "Office Repairs & Maintenance"),
6816
+ categoryExpense("bd-cat-professional", "professional", "6309", "Legal Fee & Professional Charges"),
6817
+ categoryExpense("bd-cat-travel", "travel", "6414", "Travel & Conveyance"),
6818
+ categoryExpense("bd-cat-fuel", "fuel", "6807", "Fuel & Lubricants"),
6819
+ {
6820
+ id: "bd-pay-cash",
6821
+ purpose: ACCOUNT_PURPOSE.CASH,
6822
+ priority: 10,
6823
+ use: BD_ACCOUNT_CODES.PETTY_CASH,
6824
+ label: "Cash in Hand",
6825
+ when: {
6826
+ field: "paymentMethod",
6827
+ op: "eq",
6828
+ value: "cash"
6829
+ }
6830
+ },
6831
+ {
6832
+ id: "bd-pay-card",
6833
+ purpose: ACCOUNT_PURPOSE.CASH,
6834
+ priority: 10,
6835
+ use: BD_ACCOUNT_CODES.GATEWAY_CLEARING,
6836
+ label: "Gateway Clearing",
6837
+ when: {
6838
+ field: "paymentMethod",
6839
+ op: "in",
6840
+ value: [
6841
+ "card",
6842
+ "stripe",
6843
+ "sslcommerz",
6844
+ "visa",
6845
+ "mastercard"
6846
+ ]
6847
+ }
6848
+ },
6849
+ {
6850
+ id: "bd-pay-mfs",
6851
+ purpose: ACCOUNT_PURPOSE.CASH,
6852
+ priority: 10,
6853
+ use: BD_ACCOUNT_CODES.MOBILE_MONEY_MERCHANT,
6854
+ label: "Mobile Money",
6855
+ when: {
6856
+ field: "paymentMethod",
6857
+ op: "in",
6858
+ value: [
6859
+ "bkash",
6860
+ "nagad",
6861
+ "rocket",
6862
+ "mfs",
6863
+ "mobile",
6864
+ "upay"
6865
+ ]
6866
+ }
6867
+ },
6868
+ {
6869
+ id: "bd-pay-bank",
6870
+ purpose: ACCOUNT_PURPOSE.CASH,
6871
+ priority: 10,
6872
+ use: BD_ACCOUNT_CODES.CASH,
6873
+ label: "Cash at Bank",
6874
+ when: {
6875
+ field: "paymentMethod",
6876
+ op: "in",
6877
+ value: [
6878
+ "bank",
6879
+ "bank_transfer",
6880
+ "cheque",
6881
+ "eft",
6882
+ "rtgs"
6883
+ ]
6884
+ }
6885
+ },
6886
+ {
6887
+ id: "bd-inv-raw",
6888
+ purpose: ACCOUNT_PURPOSE.INVENTORY,
6889
+ priority: 10,
6890
+ use: BD_ACCOUNT_CODES.RAW_MATERIALS,
6891
+ label: "Raw Materials",
6892
+ when: {
6893
+ field: "inventoryType",
6894
+ op: "eq",
6895
+ value: "raw_materials"
6896
+ }
6897
+ },
6898
+ {
6899
+ id: "bd-inv-finished",
6900
+ purpose: ACCOUNT_PURPOSE.INVENTORY,
6901
+ priority: 10,
6902
+ use: BD_ACCOUNT_CODES.FINISHED_GOODS,
6903
+ label: "Finished Goods",
6904
+ when: {
6905
+ field: "inventoryType",
6906
+ op: "eq",
6907
+ value: "finished_goods"
6908
+ }
6909
+ },
6910
+ {
6911
+ id: "bd-inv-merch",
6912
+ purpose: ACCOUNT_PURPOSE.INVENTORY,
6913
+ priority: 10,
6914
+ use: BD_ACCOUNT_CODES.MERCHANDISE,
6915
+ label: "Merchandise",
6916
+ when: {
6917
+ field: "inventoryType",
6918
+ op: "eq",
6919
+ value: "merchandise"
6920
+ }
6921
+ }
6922
+ ],
6923
+ defaults: {
6924
+ [ACCOUNT_PURPOSE.EXPENSE]: "6822",
6925
+ [ACCOUNT_PURPOSE.COGS]: BD_ACCOUNT_CODES.COGS_MATERIALS,
6926
+ [ACCOUNT_PURPOSE.REVENUE]: BD_ACCOUNT_CODES.SALES_REVENUE,
6927
+ [ACCOUNT_PURPOSE.RECEIVABLE]: BD_ACCOUNT_CODES.AR,
6928
+ [ACCOUNT_PURPOSE.PAYABLE]: BD_ACCOUNT_CODES.AP,
6929
+ [ACCOUNT_PURPOSE.CASH]: BD_ACCOUNT_CODES.CASH,
6930
+ [ACCOUNT_PURPOSE.INVENTORY]: BD_ACCOUNT_CODES.MERCHANDISE
6931
+ }
6932
+ };
6933
+ //#endregion
6591
6934
  //#region src/accounts/index.ts
6592
6935
  const A = "Balance Sheet-Asset";
6593
6936
  const L = "Balance Sheet-Liability";
@@ -6806,15 +7149,81 @@ const VAT_CODES = {
6806
7149
  description: "Reduced rate VAT at 5% — no input credit",
6807
7150
  active: true
6808
7151
  },
7152
+ "BD-VAT-4.5": {
7153
+ code: "BD-VAT-4.5",
7154
+ name: "VAT Reduced 4.5%",
7155
+ taxType: "VAT",
7156
+ rate: .045,
7157
+ direction: "collected",
7158
+ province: "National",
7159
+ reportLines: [20],
7160
+ description: "Third-Schedule rate at 4.5% (real estate >1,600 sqft) — no input credit",
7161
+ active: true
7162
+ },
7163
+ "BD-VAT-2.4": {
7164
+ code: "BD-VAT-2.4",
7165
+ name: "VAT Reduced 2.4%",
7166
+ taxType: "VAT",
7167
+ rate: .024,
7168
+ direction: "collected",
7169
+ province: "National",
7170
+ reportLines: [21],
7171
+ description: "Third-Schedule rate at 2.4% (medicine trading stage / pharmacies) — no input credit",
7172
+ active: true
7173
+ },
7174
+ "BD-VAT-2": {
7175
+ code: "BD-VAT-2",
7176
+ name: "VAT Reduced 2%",
7177
+ taxType: "VAT",
7178
+ rate: .02,
7179
+ direction: "collected",
7180
+ province: "National",
7181
+ reportLines: [22],
7182
+ description: "Third-Schedule rate at 2% (petroleum trading / real estate ≤1,600 sqft) — no input credit",
7183
+ active: true
7184
+ },
7185
+ "BD-VAT-1.5": {
7186
+ code: "BD-VAT-1.5",
7187
+ name: "VAT Reduced 1.5%",
7188
+ taxType: "VAT",
7189
+ rate: .015,
7190
+ direction: "collected",
7191
+ province: "National",
7192
+ reportLines: [23],
7193
+ description: "Third-Schedule rate at 1.5% (wholesale trading stage) — no input credit",
7194
+ active: true
7195
+ },
6809
7196
  "BD-TOT-4": {
6810
7197
  code: "BD-TOT-4",
6811
- name: "Turnover Tax 4%",
7198
+ name: "Turnover Tax 4% (historical)",
6812
7199
  taxType: "TOT",
6813
7200
  rate: .04,
6814
7201
  direction: "collected",
6815
7202
  province: "National",
6816
7203
  reportLines: [6],
6817
- description: "Turnover tax at 4% for small businesses (annual turnover < 50 lakh BDT)",
7204
+ description: "Percentage turnover tax at 4% in force through FY2025-26 (30 Jun 2026). Use BD-TOT-FIXED for FY2026-27+ postings.",
7205
+ active: true
7206
+ },
7207
+ "BD-TOT-FIXED": {
7208
+ code: "BD-TOT-FIXED",
7209
+ name: "Turnover Tax (Fixed Amount)",
7210
+ taxType: "TOT",
7211
+ rate: 0,
7212
+ direction: "collected",
7213
+ province: "National",
7214
+ reportLines: [6],
7215
+ description: "FY2026-27+ turnover tax: a government-assessed FIXED annual amount (by business profile/sector/region, capped Tk 2 lakh). Rate is 0 — post the assessed amount directly.",
7216
+ active: true
7217
+ },
7218
+ "BD-AT-IMP": {
7219
+ code: "BD-AT-IMP",
7220
+ name: "Advance Tax (AT) on Imports",
7221
+ taxType: "VAT",
7222
+ rate: .075,
7223
+ direction: "recoverable",
7224
+ province: "National",
7225
+ reportLines: [24],
7226
+ description: "Advance VAT paid at customs (7.5% commercial importers per FO2025; manufacturers 2% on raw materials). Recoverable — decreasing adjustment in Mushak 9.1.",
6818
7227
  active: true
6819
7228
  },
6820
7229
  "BD-VAT-0": {
@@ -6854,57 +7263,101 @@ const VAT_CODES = {
6854
7263
  const TDS_CODES = {
6855
7264
  "BD-TDS-CONT": {
6856
7265
  code: "BD-TDS-CONT",
6857
- name: "TDS on Contractors",
7266
+ name: "TDS on Contractors / Supply",
6858
7267
  taxType: "TDS",
6859
7268
  rate: .05,
6860
7269
  direction: "paid",
6861
7270
  province: "National",
6862
7271
  reportLines: [],
6863
- description: "Tax deducted at source on contractor payments (2-7%)",
7272
+ description: "TDS on contractor/supply/manufacturing payments — flat 5% (ITA 2023 s.89, slab system abolished)",
6864
7273
  active: true
6865
7274
  },
6866
7275
  "BD-TDS-PROF": {
6867
7276
  code: "BD-TDS-PROF",
6868
- name: "TDS on Professional Fees",
7277
+ name: "TDS on Professional Fees (Entities)",
7278
+ taxType: "TDS",
7279
+ rate: .075,
7280
+ direction: "paid",
7281
+ province: "National",
7282
+ reportLines: [],
7283
+ description: "TDS on professional/consultancy fees paid to entities — 7.5% (ITA 2023 s.90 as amended by FO2025). Natural persons: BD-TDS-PROF-IND.",
7284
+ active: true
7285
+ },
7286
+ "BD-TDS-PROF-IND": {
7287
+ code: "BD-TDS-PROF-IND",
7288
+ name: "TDS on Professional Fees (Natural Persons)",
7289
+ taxType: "TDS",
7290
+ rate: .15,
7291
+ direction: "paid",
7292
+ province: "National",
7293
+ reportLines: [],
7294
+ description: "TDS on professional/consultancy fees paid to natural persons — 15% (ITA 2023 s.90)",
7295
+ active: true
7296
+ },
7297
+ "BD-TDS-TECH": {
7298
+ code: "BD-TDS-TECH",
7299
+ name: "TDS on Technical Service Fees",
6869
7300
  taxType: "TDS",
6870
7301
  rate: .1,
6871
7302
  direction: "paid",
6872
7303
  province: "National",
6873
7304
  reportLines: [],
6874
- description: "Tax deducted at source on professional fees (10%)",
7305
+ description: "TDS on technical service / know-how fees 10% (ITA 2023 s.90)",
6875
7306
  active: true
6876
7307
  },
6877
7308
  "BD-TDS-RENT": {
6878
7309
  code: "BD-TDS-RENT",
6879
7310
  name: "TDS on Rent",
6880
7311
  taxType: "TDS",
6881
- rate: .05,
7312
+ rate: .1,
6882
7313
  direction: "paid",
6883
7314
  province: "National",
6884
7315
  reportLines: [],
6885
- description: "Tax deducted at source on rent payments (3-5%)",
7316
+ description: "TDS on rent of house property, machinery, or equipment — 10% (ITA 2023 s.109)",
6886
7317
  active: true
6887
7318
  },
6888
7319
  "BD-TDS-INT": {
6889
7320
  code: "BD-TDS-INT",
6890
- name: "TDS on Interest",
7321
+ name: "TDS on Interest (Companies)",
7322
+ taxType: "TDS",
7323
+ rate: .2,
7324
+ direction: "paid",
7325
+ province: "National",
7326
+ reportLines: [],
7327
+ description: "TDS on interest/profit on securities paid to companies — 20% (ITA 2023 s.102). Individuals: BD-TDS-INT-IND.",
7328
+ active: true
7329
+ },
7330
+ "BD-TDS-INT-IND": {
7331
+ code: "BD-TDS-INT-IND",
7332
+ name: "TDS on Interest (Individuals)",
6891
7333
  taxType: "TDS",
6892
7334
  rate: .1,
6893
7335
  direction: "paid",
6894
7336
  province: "National",
6895
7337
  reportLines: [],
6896
- description: "Tax deducted at source on interest payments (10%)",
7338
+ description: "TDS on interest paid to individuals 10% (ITA 2023 s.102)",
6897
7339
  active: true
6898
7340
  },
6899
7341
  "BD-TDS-DIV": {
6900
7342
  code: "BD-TDS-DIV",
6901
- name: "TDS on Dividends",
7343
+ name: "TDS on Dividends (Companies)",
7344
+ taxType: "TDS",
7345
+ rate: .2,
7346
+ direction: "paid",
7347
+ province: "National",
7348
+ reportLines: [],
7349
+ description: "TDS on dividends paid to companies — 20% (ITA 2023 s.117). Resident individuals: BD-TDS-DIV-IND (10%).",
7350
+ active: true
7351
+ },
7352
+ "BD-TDS-DIV-IND": {
7353
+ code: "BD-TDS-DIV-IND",
7354
+ name: "TDS on Dividends (Resident Individuals)",
6902
7355
  taxType: "TDS",
6903
7356
  rate: .1,
6904
7357
  direction: "paid",
6905
7358
  province: "National",
6906
7359
  reportLines: [],
6907
- description: "Tax deducted at source on dividend payments (10%)",
7360
+ description: "TDS on dividends paid to resident individuals 10% (ITA 2023 s.117)",
6908
7361
  active: true
6909
7362
  },
6910
7363
  "BD-TDS-COMM": {
@@ -6915,18 +7368,40 @@ const TDS_CODES = {
6915
7368
  direction: "paid",
6916
7369
  province: "National",
6917
7370
  reportLines: [],
6918
- description: "Tax deducted at source on commission payments (10%)",
7371
+ description: "TDS on commission/discount/fees 10% (ITA 2023 s.94)",
6919
7372
  active: true
6920
7373
  },
6921
7374
  "BD-TDS-ADV": {
6922
7375
  code: "BD-TDS-ADV",
6923
- name: "TDS on Advertising",
7376
+ name: "TDS on Media Advertising",
6924
7377
  taxType: "TDS",
6925
- rate: .04,
7378
+ rate: .05,
7379
+ direction: "paid",
7380
+ province: "National",
7381
+ reportLines: [],
7382
+ description: "TDS on media advertising bills (newspapers/TV/radio/websites, excl. media buying agents) — 5% (ITA 2023 s.92). Agency commission: BD-TDS-COMM.",
7383
+ active: true
7384
+ },
7385
+ "BD-TDS-TRANSPORT": {
7386
+ code: "BD-TDS-TRANSPORT",
7387
+ name: "TDS on Transport / Ride-Sharing",
7388
+ taxType: "TDS",
7389
+ rate: .02,
7390
+ direction: "paid",
7391
+ province: "National",
7392
+ reportLines: [],
7393
+ description: "TDS on transport, vehicle rental, ride-sharing and sharing-economy platforms — 2% from FY2026-27 (was 5%)",
7394
+ active: true
7395
+ },
7396
+ "BD-TDS-EXP": {
7397
+ code: "BD-TDS-EXP",
7398
+ name: "TDS on Export Proceeds",
7399
+ taxType: "TDS",
7400
+ rate: .01,
6926
7401
  direction: "paid",
6927
7402
  province: "National",
6928
7403
  reportLines: [],
6929
- description: "Tax deducted at source on advertising payments (3-4%)",
7404
+ description: "Withholding on export proceeds 1% (ITA 2023 s.123)",
6930
7405
  active: true
6931
7406
  },
6932
7407
  "BD-TDS-IMP": {
@@ -6937,7 +7412,7 @@ const TDS_CODES = {
6937
7412
  direction: "paid",
6938
7413
  province: "National",
6939
7414
  reportLines: [],
6940
- description: "Advance income tax on imports at customs stage (3-5%)",
7415
+ description: "Advance income tax at customs stage — 5% general (ITA 2023 s.120; industrial raw materials 4% from FY2026-27). Adjustable against assessed tax — post to 1151.",
6941
7416
  active: true
6942
7417
  },
6943
7418
  "BD-SD": {
@@ -6952,9 +7427,67 @@ const TDS_CODES = {
6952
7427
  active: true
6953
7428
  }
6954
7429
  };
7430
+ const VDS_CODES = {
7431
+ "BD-VDS-15": {
7432
+ code: "BD-VDS-15",
7433
+ name: "VDS 15% (Standard Services)",
7434
+ taxType: "VDS",
7435
+ rate: .15,
7436
+ direction: "paid",
7437
+ province: "National",
7438
+ reportLines: [25],
7439
+ description: "VDS at 15% of service value — most listed services (consultancy, security, cleaning, legal, event management, …)",
7440
+ active: true
7441
+ },
7442
+ "BD-VDS-10": {
7443
+ code: "BD-VDS-10",
7444
+ name: "VDS 10% (Construction / Procurement / Non-AC Hotel)",
7445
+ taxType: "VDS",
7446
+ rate: .1,
7447
+ direction: "paid",
7448
+ province: "National",
7449
+ reportLines: [25],
7450
+ description: "VDS at 10% of service value — construction firms (S004.00), procurement providers (S037.00), motor garages, non-AC hotels; also imported goods supplied by commercial importers",
7451
+ active: true
7452
+ },
7453
+ "BD-VDS-7.5": {
7454
+ code: "BD-VDS-7.5",
7455
+ name: "VDS 7.5% (Furniture)",
7456
+ taxType: "VDS",
7457
+ rate: .075,
7458
+ direction: "paid",
7459
+ province: "National",
7460
+ reportLines: [25],
7461
+ description: "VDS at 7.5% of service value — furniture sales channel (S024.00)",
7462
+ active: true
7463
+ },
7464
+ "BD-VDS-5": {
7465
+ code: "BD-VDS-5",
7466
+ name: "VDS 5% (ITES / Restaurant / Petroleum Transport)",
7467
+ taxType: "VDS",
7468
+ rate: .05,
7469
+ direction: "paid",
7470
+ province: "National",
7471
+ reportLines: [25],
7472
+ description: "VDS at 5% of service value — ITES (S099.10), restaurants (S001.20), petroleum transport (S048.00)",
7473
+ active: true
7474
+ },
7475
+ "BD-VDS-2": {
7476
+ code: "BD-VDS-2",
7477
+ name: "VDS 2% (Land / Small Real Estate)",
7478
+ taxType: "VDS",
7479
+ rate: .02,
7480
+ direction: "paid",
7481
+ province: "National",
7482
+ reportLines: [25],
7483
+ description: "VDS at 2% of service value — land development (S010.10), building construction ≤1,600 sqft (S010.20)",
7484
+ active: true
7485
+ }
7486
+ };
6955
7487
  const ALL_TAX_CODES = Object.freeze({
6956
7488
  ...VAT_CODES,
6957
- ...TDS_CODES
7489
+ ...TDS_CODES,
7490
+ ...VDS_CODES
6958
7491
  });
6959
7492
  /** Look up a tax code by its code string. e.g. getTaxCodeDetails('BD-VAT-15') */
6960
7493
  function getTaxCodeDetails(code) {
@@ -7000,8 +7533,8 @@ const MUSHAK_LINES = Object.freeze({
7000
7533
  },
7001
7534
  6: {
7002
7535
  line: 6,
7003
- name: "Turnover Tax (4%)",
7004
- description: "Turnover tax for small businesses",
7536
+ name: "Turnover Tax",
7537
+ description: "Turnover tax for enlisted small businesses (4% of turnover through FY2025-26; fixed assessed amount capped Tk 2 lakh/yr from FY2026-27)",
7005
7538
  type: "input",
7006
7539
  section: "Output VAT"
7007
7540
  },
@@ -7022,10 +7555,10 @@ const MUSHAK_LINES = Object.freeze({
7022
7555
  9: {
7023
7556
  line: 9,
7024
7557
  name: "Total Output VAT / Tax",
7025
- description: "Sum of all output VAT and turnover tax (Lines 2+3+4+5+6)",
7558
+ description: "Sum of all output VAT and turnover tax (Lines 2+3+4+5+6+20+21+22+23)",
7026
7559
  type: "calculated",
7027
7560
  section: "Output VAT",
7028
- calculate: (d) => (d[2] || 0) + (d[3] || 0) + (d[4] || 0) + (d[5] || 0) + (d[6] || 0)
7561
+ calculate: (d) => (d[2] || 0) + (d[3] || 0) + (d[4] || 0) + (d[5] || 0) + (d[6] || 0) + (d[20] || 0) + (d[21] || 0) + (d[22] || 0) + (d[23] || 0)
7029
7562
  },
7030
7563
  10: {
7031
7564
  line: 10,
@@ -7081,10 +7614,10 @@ const MUSHAK_LINES = Object.freeze({
7081
7614
  17: {
7082
7615
  line: 17,
7083
7616
  name: "Total VAT/SD Payable",
7084
- description: "Total payable: Net VAT + SD + Adjustments (Line 12 + Line 13 + Line 16)",
7617
+ description: "Total payable: Net VAT + SD + Adjustments + VDS withheld − AT credit (Line 12 + 13 + 16 + 25 − 24)",
7085
7618
  type: "calculated",
7086
7619
  section: "Total Payable",
7087
- calculate: (d) => (d[12] || 0) + (d[13] || 0) + (d[16] || 0)
7620
+ calculate: (d) => (d[12] || 0) + (d[13] || 0) + (d[16] || 0) + (d[25] || 0) - (d[24] || 0)
7088
7621
  },
7089
7622
  18: {
7090
7623
  line: 18,
@@ -7100,6 +7633,48 @@ const MUSHAK_LINES = Object.freeze({
7100
7633
  type: "calculated",
7101
7634
  section: "Balance",
7102
7635
  calculate: (d) => (d[17] || 0) - (d[18] || 0)
7636
+ },
7637
+ 20: {
7638
+ line: 20,
7639
+ name: "VAT on Sales at 4.5%",
7640
+ description: "VAT collected at 4.5% (real estate >1,600 sqft)",
7641
+ type: "input",
7642
+ section: "Output VAT"
7643
+ },
7644
+ 21: {
7645
+ line: 21,
7646
+ name: "VAT on Sales at 2.4%",
7647
+ description: "VAT collected at 2.4% (medicine trading stage / pharmacies)",
7648
+ type: "input",
7649
+ section: "Output VAT"
7650
+ },
7651
+ 22: {
7652
+ line: 22,
7653
+ name: "VAT on Sales at 2%",
7654
+ description: "VAT collected at 2% (petroleum trading / real estate ≤1,600 sqft)",
7655
+ type: "input",
7656
+ section: "Output VAT"
7657
+ },
7658
+ 23: {
7659
+ line: 23,
7660
+ name: "VAT on Sales at 1.5%",
7661
+ description: "VAT collected at 1.5% (wholesale trading stage)",
7662
+ type: "input",
7663
+ section: "Output VAT"
7664
+ },
7665
+ 24: {
7666
+ line: 24,
7667
+ name: "Advance Tax (AT) Credit on Imports",
7668
+ description: "Advance VAT paid at customs stage — decreasing adjustment against output VAT",
7669
+ type: "input",
7670
+ section: "Adjustments"
7671
+ },
7672
+ 25: {
7673
+ line: 25,
7674
+ name: "VDS Increasing Adjustment (Withheld from Suppliers)",
7675
+ description: "VAT deducted at source from supplier payments, settled through this return (VDS Rules 2025 — registered withholders)",
7676
+ type: "input",
7677
+ section: "Adjustments"
7103
7678
  }
7104
7679
  });
7105
7680
  const CALC_ORDER = [
@@ -7146,7 +7721,13 @@ const ALL_VAT_CODES = [
7146
7721
  "BD-VAT-10",
7147
7722
  "BD-VAT-7.5",
7148
7723
  "BD-VAT-5",
7724
+ "BD-VAT-4.5",
7725
+ "BD-VAT-2.4",
7726
+ "BD-VAT-2",
7727
+ "BD-VAT-1.5",
7149
7728
  "BD-TOT-4",
7729
+ "BD-TOT-FIXED",
7730
+ "BD-AT-IMP",
7150
7731
  "BD-VAT-0",
7151
7732
  "BD-EXEMPT",
7152
7733
  "BD-VIN-15"
@@ -7154,15 +7735,32 @@ const ALL_VAT_CODES = [
7154
7735
  const ALL_TDS_CODES = [
7155
7736
  "BD-TDS-CONT",
7156
7737
  "BD-TDS-PROF",
7738
+ "BD-TDS-PROF-IND",
7739
+ "BD-TDS-TECH",
7157
7740
  "BD-TDS-RENT",
7158
7741
  "BD-TDS-INT",
7742
+ "BD-TDS-INT-IND",
7159
7743
  "BD-TDS-DIV",
7744
+ "BD-TDS-DIV-IND",
7160
7745
  "BD-TDS-COMM",
7161
7746
  "BD-TDS-ADV",
7747
+ "BD-TDS-TRANSPORT",
7748
+ "BD-TDS-EXP",
7162
7749
  "BD-TDS-IMP",
7163
7750
  "BD-SD"
7164
7751
  ];
7165
- const ALL_CODES = [...ALL_VAT_CODES, ...ALL_TDS_CODES];
7752
+ const ALL_VDS_CODES = [
7753
+ "BD-VDS-15",
7754
+ "BD-VDS-10",
7755
+ "BD-VDS-7.5",
7756
+ "BD-VDS-5",
7757
+ "BD-VDS-2"
7758
+ ];
7759
+ const ALL_CODES = [
7760
+ ...ALL_VAT_CODES,
7761
+ ...ALL_TDS_CODES,
7762
+ ...ALL_VDS_CODES
7763
+ ];
7166
7764
  /**
7167
7765
  * Tax codes by division — Bangladesh has a national VAT/TDS system,
7168
7766
  * so all divisions share the same codes. This mapping exists for
@@ -7267,4 +7865,4 @@ const bangladeshPack = defineCountryPack({
7267
7865
  ]
7268
7866
  });
7269
7867
  //#endregion
7270
- export { ADMIN_EXPENSES, ALL_DIVISIONS, ALL_TAX_ACCOUNTS, ASSETS, BANKING_REVENUE, BD_ACCOUNT_CODES, BD_ACCOUNT_TYPES, BD_DIVISIONS, COGS, COST_OF_SERVICES, CURRENT_ASSETS, CURRENT_LIABILITIES, DEPRECIATION, DIRECT_LABOR, DIRECT_MATERIALS, DIVISIONS, EMPLOYEE_COSTS, EQUITY, EXPENSES, FINANCIAL_EXPENSES, INDUSTRY_REVENUE, LIABILITIES, MANUFACTURING_OVERHEAD, NGO_REVENUE, NON_CURRENT_ASSETS, NON_CURRENT_LIABILITIES, OTHER_INCOME, OTHER_OPERATING, PREMISES_COSTS, PROVISIONS, PURCHASES, REVENUE, SALES_REVENUE, SELLING_DISTRIBUTION, ALL_TAX_CODES as TAX_CODES, TAX_CODES_BY_DIVISION, TAX_EXPENSE, TDS_LIABILITY_ACCOUNTS, VAT_ASSET_ACCOUNTS, VAT_LIABILITY_ACCOUNTS, VDS_LIABILITY_ACCOUNTS, bangladeshPack, getTaxCodeDetails, mushakReturnTemplate };
7868
+ export { ADMIN_EXPENSES, ALL_DIVISIONS, ALL_TAX_ACCOUNTS, ASSETS, BANKING_REVENUE, BD_ACCOUNT_CODES, BD_ACCOUNT_RULES, BD_ACCOUNT_TYPES, BD_DIVISIONS, COGS, COST_OF_SERVICES, CURRENT_ASSETS, CURRENT_LIABILITIES, DEPRECIATION, DIRECT_LABOR, DIRECT_MATERIALS, DIVISIONS, EMPLOYEE_COSTS, EQUITY, EXPENSES, FINANCIAL_EXPENSES, INDUSTRY_REVENUE, LIABILITIES, MANUFACTURING_OVERHEAD, NGO_REVENUE, NON_CURRENT_ASSETS, NON_CURRENT_LIABILITIES, OTHER_INCOME, OTHER_OPERATING, PREMISES_COSTS, PROVISIONS, PURCHASES, REVENUE, SALES_REVENUE, SELLING_DISTRIBUTION, ALL_TAX_CODES as TAX_CODES, TAX_CODES_BY_DIVISION, TAX_EXPENSE, TAX_RECEIVABLE_ACCOUNTS, TDS_LIABILITY_ACCOUNTS, VAT_ASSET_ACCOUNTS, VAT_LIABILITY_ACCOUNTS, VDS_LIABILITY_ACCOUNTS, bangladeshPack, getTaxCodeDetails, mushakReturnTemplate };