Skip to content

Commit

Permalink
fix: Negatif perhitungan pajak di bulan desember
Browse files Browse the repository at this point in the history
  • Loading branch information
pipinfitriadi committed Feb 4, 2024
1 parent cca2521 commit 45b0052
Showing 1 changed file with 10 additions and 7 deletions.
17 changes: 10 additions & 7 deletions src/index.html
Original file line number Diff line number Diff line change
Expand Up @@ -328,14 +328,17 @@ <h1 class="text-center">Kalkulator Pajak</h1>
elem.penghasilanBrutoBulanan >= gajiGross
),
pajakJanNov = Math.round(gajiGross * foundElem.tarifPajak),
pajakDes = Math.round(
pajakPenghasilanPasal21(
gajiGross * 12
- penghasilanTidakKenaPajak[
form.elements.statusKawinTanggungan.value
]
pajakDes = Math.max(
0,
Math.round(
pajakPenghasilanPasal21(
gajiGross * 12
- penghasilanTidakKenaPajak[
form.elements.statusKawinTanggungan.value
]
)
- pajakJanNov * 11
)
- pajakJanNov * 11
),
gajiNettJanNov = gajiGross - pajakJanNov,
gajiNettDes = gajiGross - pajakDes;
Expand Down

0 comments on commit 45b0052

Please sign in to comment.