fix(bookkeeping): drop non-standard account 2012, book EF F-skatt on 2013 (#1409) (#1489)

Primary-source check against bas.se (BAS 2026 v2): the official kontoplan
has no account 2012; the enskild firma equity block is 2010, 2011, 2013,
2017, 2018, 2019. 2012 'Avräkning för skatter och avgifter' is a program
convention (Visma, Bokio, Björn Lundén), not standard BAS, and a
non-standard account in BAS_REFERENCE leaks via the backfill into charts,
SIE export and SRU filing.

- remove 2012 from class-2-equity-liabilities.ts, with a tombstone comment
- migration retargets 'Preliminär F-skatt (EF)' lines 2012 -> 2013
  (system row plus any clones still carrying the seeded shape)
- pin 2012's absence in bas-ef-equity-accounts.test.ts (2113 precedent)
- correct the swedish-year-end-closing references that motivated #1388,
  regenerate atom seed migration

Companies whose charts already got 2012 backfilled keep it: existing
history stays valid; only future template use books 2013.

Closes #1409

Co-authored-by: Jakob Wennberg <311770904+jakobwennberg-oss@users.noreply.github.com>
Co-authored-by: Claude Fable 5 <noreply@anthropic.com>
This commit is contained in:
Jakob Wennberg
2026-08-10 14:04:08 +02:00
committed by GitHub
co-authored by Jakob Wennberg Claude Fable 5
parent 3ff12faa77
commit fe1ff8649b
11 changed files with 17631 additions and 46 deletions
@@ -23,21 +23,11 @@ export const CLASS_2_ACCOUNTS: BASReferenceAccount[] = [
sru_code: '7221',
k2_excluded: false,
},
{
account_number: '2012',
account_name: 'Avräkning för skatter och avgifter',
account_class: 2,
account_group: '20',
account_type: 'equity',
normal_balance: 'debit',
description:
'Enskild firma: ägarens egna skatter och avgifter (t.ex. preliminär F-skatt) som betalas ' +
'av företaget. Ett eget uttag, inte en företagskostnad. Nollas mot 2010 Eget kapital vid ' +
'nytt räkenskapsår. Ska inte förväxlas med 1630 Avräkning för skatter och avgifter ' +
'(skattekonto), som är tillgångssidans saldo mot Skatteverket.',
sru_code: '7221',
k2_excluded: false,
},
// 2012 is deliberately absent: the official BAS kontoplan (bas.se, BAS 2026 v2)
// has no 2012; the enskild firma equity block runs 2010, 2011, 2013, 2017,
// 2018, 2019. "Avräkning för skatter och avgifter" as 2012 is a program
// convention (Visma, Bokio, Björn Lundén), not standard BAS; owner taxes are
// booked as eget uttag on 2013. Verified against the primary source in #1409.
{
account_number: '2013',
account_name: 'Övriga egna uttag',