ausgagben im gehaltscheck formatiert

This commit is contained in:
Fabian Wessels
2020-08-02 17:21:47 +02:00
parent f88640f222
commit 1f7b271048

View File

@@ -91,37 +91,40 @@ export default function (globalData: IGlobalData) {
paycheckMenu.AddItem(item); paycheckMenu.AddItem(item);
item = new UIMenuItem("Sonstige Einkünfte"); item = new UIMenuItem("Sonstige Einkünfte");
item.SetRightLabel("~g~+ $" + moneyFormat(p.otheramount)); item.SetRightLabel("~g~+ $" + moneyFormat(Number(p.otheramount.toFixed(2))));
paycheckMenu.AddItem(item); paycheckMenu.AddItem(item);
item = new UIMenuItem("Finanzhilfe"); item = new UIMenuItem("Finanzhilfe");
item.SetRightLabel("~g~+ $" + moneyFormat(p.financialHelp)); item.SetRightLabel("~g~+ $" + moneyFormat(Number(p.financialHelp.toFixed(2))));
paycheckMenu.AddItem(item); paycheckMenu.AddItem(item);
if (p.factionMoney) { if (p.factionMoney) {
item = new UIMenuItem("Fraktionsgeld"); item = new UIMenuItem("Fraktionsgeld");
item.SetRightLabel("~g~+ $" + moneyFormat(p.factionMoney)); item.SetRightLabel("~g~+ $" + moneyFormat(Number(p.factionMoney.toFixed(2))));
paycheckMenu.AddItem(item); paycheckMenu.AddItem(item);
} }
item = new UIMenuItem("Fahrzeugsteuer"); item = new UIMenuItem("Fahrzeugsteuer");
item.SetRightLabel("~r~- $" + moneyFormat(p.vehicleTaxation)); item.SetRightLabel("~r~- $" + moneyFormat(Number(p.vehicleTaxation.toFixed(2))));
paycheckMenu.AddItem(item); paycheckMenu.AddItem(item);
item = new UIMenuItem("Grundsteuer"); item = new UIMenuItem("Grundsteuer");
item.SetRightLabel("~r~- $" + moneyFormat(p.propertyTaxation)); item.SetRightLabel("~r~- $" + moneyFormat(Number(p.propertyTaxation.toFixed(2))));
paycheckMenu.AddItem(item); paycheckMenu.AddItem(item);
item = new UIMenuItem("Mietkosten"); item = new UIMenuItem("Mietkosten");
item.SetRightLabel("~r~- $" + moneyFormat(p.rentalFees)); item.SetRightLabel("~r~- $" + moneyFormat(Number(p.rentalFees.toFixed(2))));
paycheckMenu.AddItem(item); paycheckMenu.AddItem(item);
item = new UIMenuItem("Krankenkasse"); item = new UIMenuItem("Krankenkasse");
item.SetRightLabel("~r~- $" + moneyFormat(p.healthInsurance)); item.SetRightLabel("~r~- $" + moneyFormat(Number(p.healthInsurance.toFixed(2))));
paycheckMenu.AddItem(item); paycheckMenu.AddItem(item);
item = new UIMenuItem("Einkommensteuer"); item = new UIMenuItem("Einkommensteuer");
item.SetRightLabel((p.financialInterest * 100).toString() + "%");
//var numb = Number(p.financialInterest * 100).toFixed(3);
//var numb_format = moneyFormat(Number(numb));
item.SetRightLabel(moneyFormat(Number((p.financialInterest * 100).toFixed(3))) + "%");
paycheckMenu.AddItem(item); paycheckMenu.AddItem(item);
menu.AddItem(paycheckItem); menu.AddItem(paycheckItem);