Fix/build (#1041)
* fix(bookkeeping): harden correction account changes * feat(tax): enhance tax deadline generation with new settings and filing methods - Added new company settings: tax_turnover_over_40m, vat_has_eu_trade, vat_filing_method, periodisk_sammanstallning_enabled, and periodisk_sammanstallning_filing_method. - Updated deadline generation logic to accommodate new settings affecting VAT and employer declaration deadlines. - Implemented tests for new functionality, ensuring that completed obligations are preserved and not replaced by new pending rows. - Introduced a cron job to backfill missing tax deadlines for companies with settings but no upcoming deadlines. - Updated API routes for generating tax deadlines and handling cron jobs. - Modified database schema to include new columns for tax filing profiles and constraints for filing methods. * fix(invoices): record credit note reconciliation guard * fix(tax): correct automatic deadline settings * fix(tax): key AGI deadline to VAT taxable base and add storforetag payment deadline The 26th filing day for the skattedeklaration (AGI and VAT together) hinges on one statutory measure, a VAT taxable base above SEK 40 million (SFL 26 kap.), not a separate employer turnover. Drop employer_turnover_over_40m and derive the AGI schedule from vat_registered plus vat_taxable_base_over_40m, so a non-VAT-reporting employer is never shown the 26th when its binding date is the 12th. Also: - add a skatteinbetalning deadline row (12th, 17 January) for storforetag, whose deducted tax and employer contributions are due before the 26th filing date - normalize legally incoherent over-40m flag combinations to the earlier small-company schedule in a follow-up migration - replace hardcoded 27 December dates with the banking-day adjustment - extend the 40m help text to cover the SKV-decided early filing election and the payment-still-on-the-12th rule - document the regeneration race repaired by the daily backfill cron Co-Authored-By: Claude Fable 5 <noreply@anthropic.com> * feat(migrations): add AGI and VAT filing logic with employer column removal * feat(settings): implement VAT registration logic and update related flags; enhance deadline handling --------- Co-authored-by: Claude Fable 5 <noreply@anthropic.com>
This commit is contained in:
co-authored by
Claude Fable 5
parent
1443235cec
commit
a5e37d3510
+17
-2
@@ -511,7 +511,7 @@
|
||||
"retry": "Please try again.",
|
||||
"overdue_invoices": "{count} overdue invoices",
|
||||
"no_system_deadlines_title": "Automatic tax deadlines missing.",
|
||||
"no_system_deadlines_description": "Deadlines for VAT, employer declarations and F-tax are generated from your company's tax settings — make sure they are filled in.",
|
||||
"no_system_deadlines_description": "Deadlines for VAT, employer declarations and F-tax are generated from your company's tax settings. Make sure they are filled in.",
|
||||
"generate_action": "Generate now",
|
||||
"generate_open_settings": "Open tax settings",
|
||||
"generate_success_title": "Tax deadlines created",
|
||||
@@ -1739,8 +1739,20 @@
|
||||
"period_quarterly": "Quarterly",
|
||||
"period_yearly": "Yearly",
|
||||
"moms_period_help": "Per decision from Skatteverket.",
|
||||
"vat_taxable_base_over_40m_label": "VAT taxable base above SEK 40 million per year",
|
||||
"vat_taxable_base_over_40m_help": "Requires monthly VAT reporting and moves the filing day for both the VAT and employer declarations to the 26th. Deducted tax and employer contributions must still be paid by the 12th. Also select this if Skatteverket has decided that the company files on these dates despite a lower taxable base.",
|
||||
"vat_has_eu_trade_label": "Trade with other EU countries",
|
||||
"vat_has_eu_trade_help": "EU purchases or sales affect the yearly VAT deadline.",
|
||||
"vat_filing_method_label": "How is the VAT return filed?",
|
||||
"vat_filing_method_help": "For limited companies with yearly VAT and no EU trade, the date depends on the filing method.",
|
||||
"filing_method_electronic": "Electronically",
|
||||
"filing_method_paper": "On a paper form",
|
||||
"periodisk_enabled_label": "Files EU sales lists",
|
||||
"periodisk_enabled_help": "Applies to VAT-exempt sales of goods or certain services to VAT-registered businesses in other EU countries.",
|
||||
"periodisk_label": "EU sales list reporting period",
|
||||
"periodisk_help": "EU goods sales must normally be reported monthly (35 ch. 2 § SFL). Quarterly requires approval from Skatteverket and only applies to services.",
|
||||
"periodisk_help": "EU goods sales are normally reported monthly (35 ch. 2 § SFL). Services-only sales are reported quarterly by default; quarterly reporting of goods sales requires a decision from Skatteverket.",
|
||||
"periodisk_filing_method_label": "Filing method",
|
||||
"periodisk_filing_method_help": "Electronic filing is normally due on the 25th, while paper filing is due on the 20th.",
|
||||
"tax_contact_heading": "Tax matters contact",
|
||||
"tax_contact_help": "Used as sender on files to Skatteverket (EU sales list, etc.).",
|
||||
"tax_contact_name_label": "Name",
|
||||
@@ -2333,6 +2345,9 @@
|
||||
"preview_truncated": "+ {remaining} more lines on booking",
|
||||
"col_account": "Account",
|
||||
"col_description": "Description",
|
||||
"accounts_loading": "Loading chart of accounts...",
|
||||
"accounts_load_failed": "The chart of accounts could not be loaded. Try again to change the account.",
|
||||
"accounts_retry": "Try again",
|
||||
"col_debit": "Debit",
|
||||
"col_credit": "Credit",
|
||||
"total_label": "Total",
|
||||
|
||||
+17
-2
@@ -511,7 +511,7 @@
|
||||
"retry": "Försök igen.",
|
||||
"overdue_invoices": "{count} förfallna fakturor",
|
||||
"no_system_deadlines_title": "Automatiska skattedeadlines saknas.",
|
||||
"no_system_deadlines_description": "Deadlines för moms, arbetsgivardeklaration och F-skatt skapas från företagets skatteinställningar — kontrollera att de är ifyllda.",
|
||||
"no_system_deadlines_description": "Deadlines för moms, arbetsgivardeklaration och F-skatt skapas från företagets skatteinställningar. Kontrollera att de är ifyllda.",
|
||||
"generate_action": "Generera nu",
|
||||
"generate_open_settings": "Öppna skatteinställningar",
|
||||
"generate_success_title": "Skattedeadlines skapade",
|
||||
@@ -1739,8 +1739,20 @@
|
||||
"period_quarterly": "Kvartal",
|
||||
"period_yearly": "År",
|
||||
"moms_period_help": "Enligt beslut från Skatteverket.",
|
||||
"vat_taxable_base_over_40m_label": "Beskattningsunderlag för moms över 40 miljoner kronor per år",
|
||||
"vat_taxable_base_over_40m_help": "Kräver månadsmoms och flyttar deklarationsdagen för både moms och arbetsgivardeklaration till den 26:e. Avdragen skatt och arbetsgivaravgifter ska ändå vara betalda den 12:e. Markera även rutan om Skatteverket har beslutat att företaget ska deklarera enligt dessa tidpunkter trots lägre underlag.",
|
||||
"vat_has_eu_trade_label": "Handel med andra EU-länder",
|
||||
"vat_has_eu_trade_help": "Köp eller försäljning inom EU påverkar datumet för årsmoms.",
|
||||
"vat_filing_method_label": "Hur lämnas momsdeklarationen?",
|
||||
"vat_filing_method_help": "För aktiebolag med årsmoms utan EU-handel beror datumet på inlämningssättet.",
|
||||
"filing_method_electronic": "Digitalt",
|
||||
"filing_method_paper": "På pappersblankett",
|
||||
"periodisk_enabled_label": "Lämnar periodisk sammanställning",
|
||||
"periodisk_enabled_help": "Gäller vid momsfri försäljning av varor eller vissa tjänster till momsregistrerade företag i andra EU-länder.",
|
||||
"periodisk_label": "Period för periodisk sammanställning",
|
||||
"periodisk_help": "Varuförsäljning till EU ska normalt rapporteras månadsvis (35 kap. 2 § SFL). Kvartal kräver tillstånd från Skatteverket och gäller endast tjänsteförsäljning.",
|
||||
"periodisk_help": "Varuförsäljning till EU rapporteras normalt månadsvis (35 kap. 2 § SFL). Enbart tjänsteförsäljning rapporteras kvartalsvis som standard; kvartalsrapportering av varuförsäljning kräver beslut från Skatteverket.",
|
||||
"periodisk_filing_method_label": "Inlämningssätt",
|
||||
"periodisk_filing_method_help": "Digital inlämning har normalt den 25:e som sista dag, pappersblankett den 20:e.",
|
||||
"tax_contact_heading": "Kontaktperson för skatteärenden",
|
||||
"tax_contact_help": "Används som avsändare på filer till Skatteverket (periodisk sammanställning m.m.).",
|
||||
"tax_contact_name_label": "Namn",
|
||||
@@ -2333,6 +2345,9 @@
|
||||
"preview_truncated": "+ {remaining} fler rader visas vid bokföring",
|
||||
"col_account": "Konto",
|
||||
"col_description": "Beskrivning",
|
||||
"accounts_loading": "Laddar kontoplan...",
|
||||
"accounts_load_failed": "Kontoplanen kunde inte laddas. Försök igen för att ändra konto.",
|
||||
"accounts_retry": "Försök igen",
|
||||
"col_debit": "Debet",
|
||||
"col_credit": "Kredit",
|
||||
"total_label": "Totalt",
|
||||
|
||||
Reference in New Issue
Block a user