Skip to content

Commit

Permalink
fix typo
Browse files Browse the repository at this point in the history
  • Loading branch information
MarekVigas committed Oct 23, 2023
1 parent c1b3ef8 commit 5e7be64
Show file tree
Hide file tree
Showing 2 changed files with 8 additions and 8 deletions.
8 changes: 4 additions & 4 deletions src/lib/calculation.ts
Original file line number Diff line number Diff line change
Expand Up @@ -34,8 +34,8 @@ export const CHILD_RATE_FIFTEEN_AND_OLDER_FROM_JULY = 40

const ZIVOTNE_MINIMUM_44_NASOBOK = 9638.25

export const SPODNA_ZADZBA_PRE_PREDDAVKY = 5000
export const VRCHNA_ZADZBA_PRE_PREDDAVKY = 16600
export const SPODNA_SADZBA_PRE_PREDDAVKY = 5000
export const VRCHNA_SADZBA_PRE_PREDDAVKY = 16600

const POCET_KVARTALOV = 4
const POCET_MESIACOV = 12
Expand Down Expand Up @@ -912,9 +912,9 @@ export const donateOnly3Percent = (form: TaxForm): boolean => {
}

export const countPreddavky = (form: TaxForm): Number => {
if (Number(form.r135_dan_na_uhradu) > VRCHNA_ZADZBA_PRE_PREDDAVKY) {
if (Number(form.r135_dan_na_uhradu) > VRCHNA_SADZBA_PRE_PREDDAVKY) {
return Number(round((form.r055.mul(DAN_Z_PRIJMU_SADZBA).div(POCET_MESIACOV))))
} else if (Number(form.r135_dan_na_uhradu) > SPODNA_ZADZBA_PRE_PREDDAVKY) {
} else if (Number(form.r135_dan_na_uhradu) > SPODNA_SADZBA_PRE_PREDDAVKY) {
return Number(round((form.r055.mul(DAN_Z_PRIJMU_SADZBA).div(POCET_KVARTALOV))))
}
}
8 changes: 4 additions & 4 deletions src/pages/vysledky.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -10,8 +10,8 @@ import { buildSummary } from '../lib/calculation'
import { countPreddavky } from '../lib/calculation'
import {
TAX_YEAR,
SPODNA_ZADZBA_PRE_PREDDAVKY,
VRCHNA_ZADZBA_PRE_PREDDAVKY,
SPODNA_SADZBA_PRE_PREDDAVKY,
VRCHNA_SADZBA_PRE_PREDDAVKY,
} from '../lib/calculation'


Expand Down Expand Up @@ -121,7 +121,7 @@ const Vysledky: Page<Partial<TaxFormUserInput>> = ({
},
]

if (Number(summary.danNaUhradu) > VRCHNA_ZADZBA_PRE_PREDDAVKY && Number(summary.zaplatenePreddavky) == 0) {
if (Number(summary.danNaUhradu) > VRCHNA_SADZBA_PRE_PREDDAVKY && Number(summary.zaplatenePreddavky) == 0) {
return (
<>
<BackLink href={previousRoute} />
Expand All @@ -146,7 +146,7 @@ const Vysledky: Page<Partial<TaxFormUserInput>> = ({
</Link>
</>
)
} else if (Number(summary.danNaUhradu) > SPODNA_ZADZBA_PRE_PREDDAVKY && Number(summary.zaplatenePreddavky) == 0) {
} else if (Number(summary.danNaUhradu) > SPODNA_SADZBA_PRE_PREDDAVKY && Number(summary.zaplatenePreddavky) == 0) {
return (
<>
<BackLink href={previousRoute} />
Expand Down

0 comments on commit 5e7be64

Please sign in to comment.