Commit 98390e97 authored by r.kurnia's avatar r.kurnia

tp

parent 70e72354
...@@ -274,74 +274,74 @@ export default class TaxPlanning extends Component { ...@@ -274,74 +274,74 @@ export default class TaxPlanning extends Component {
item_report_id: i[4], item_report_id: i[4],
january: { january: {
tbc: i[1] === 3 && i[9].tbc === "" ? "0" : i[1] === 5 || i[1] === 6 || i[1] === 7 ? String(i[9].tbc.value) : String(i[9].tbc), tbc: i[1] === 3 && i[9].tbc === "" ? "0" : i[1] === 5 || i[1] === 6 || i[1] === 7 ? String(i[9].tbc.value) : String(i[9].tbc),
fcp: i[2] === 3 && i[9].fcp === "" ? "0" : i[2] === 5 || i[2] === 6 || i[2] === 7 ? String(i[9].fcp.value) : String(i[9].fcp), fcp: i[2] === 3 && i[9].fcp === "" ? "0" : i[2] === 5 || i[2] === 6 || i[2] === 7 ? String(i[9].fcp.value) : String(i[8]).toLocaleUpperCase() == "CORPORATE INCOME TAX" ? String(Number(i[9].fcp).toFixed(2)) : String(Number(i[9].fcp).toFixed(1)) ,
tbf: i[3] === 3 && i[9].tbf === "" ? "0" : i[3] === 5 || i[3] === 6 || i[3] === 7 ? String(i[9].tbf.value) : String(i[9].tbf) tbf: i[3] === 3 && i[9].tbf === "" ? "0" : i[3] === 5 || i[3] === 6 || i[3] === 7 ? String(i[9].tbf.value) : String(i[8]).toLocaleUpperCase() == "CORPORATE INCOME TAX" ? String(Number(i[9].tbf).toFixed(2)) : String(Number(i[9].tbf).toFixed(1))
}, },
february: { february: {
tbc: i[1] === 3 && i[10].tbc === "" ? "0" : i[1] === 5 || i[1] === 6 || i[1] === 7 ? String(i[10].tbc.value) : String(i[10].tbc), tbc: i[1] === 3 && i[10].tbc === "" ? "0" : i[1] === 5 || i[1] === 6 || i[1] === 7 ? String(i[10].tbc.value) : String(i[10].tbc),
fcp: i[2] === 3 && i[10].fcp === "" ? "0" : i[2] === 5 || i[2] === 6 || i[2] === 7 ? String(i[10].fcp.value) : String(i[10].fcp), fcp: i[2] === 3 && i[10].fcp === "" ? "0" : i[2] === 5 || i[2] === 6 || i[2] === 7 ? String(i[10].fcp.value) : String(i[8]).toLocaleUpperCase() == "CORPORATE INCOME TAX" ? String(Number(i[10].fcp).toFixed(2)) : String(Number(i[10].fcp).toFixed(1)),
tbf: i[3] === 3 && i[10].tbf === "" ? "0" : i[3] === 5 || i[3] === 6 || i[3] === 7 ? String(i[10].tbf.value) : String(i[10].tbf) tbf: i[3] === 3 && i[10].tbf === "" ? "0" : i[3] === 5 || i[3] === 6 || i[3] === 7 ? String(i[10].tbf.value) : String(i[8]).toLocaleUpperCase() == "CORPORATE INCOME TAX" ? String(Number(i[10].tbf).toFixed(2)) : String(Number(i[10].tbf).toFixed(1))
}, },
march: { march: {
tbc: i[1] === 3 && i[11].tbc === "" ? "0" : i[1] === 5 || i[1] === 6 || i[1] === 7 ? String(i[11].tbc.value) : String(i[11].tbc), tbc: i[1] === 3 && i[11].tbc === "" ? "0" : i[1] === 5 || i[1] === 6 || i[1] === 7 ? String(i[11].tbc.value) : String(i[11].tbc),
fcp: i[2] === 3 && i[11].fcp === "" ? "0" : i[2] === 5 || i[2] === 6 || i[2] === 7 ? String(i[11].fcp.value) : String(i[11].fcp), fcp: i[2] === 3 && i[11].fcp === "" ? "0" : i[2] === 5 || i[2] === 6 || i[2] === 7 ? String(i[11].fcp.value) : String(i[8]).toLocaleUpperCase() == "CORPORATE INCOME TAX" ? String(Number(i[11].fcp).toFixed(2)) : String(Number(i[11].fcp).toFixed(1)),
tbf: i[3] === 3 && i[11].tbf === "" ? "0" : i[3] === 5 || i[3] === 6 || i[3] === 7 ? String(i[11].tbf.value) : String(i[11].tbf) tbf: i[3] === 3 && i[11].tbf === "" ? "0" : i[3] === 5 || i[3] === 6 || i[3] === 7 ? String(i[11].tbf.value) : String(i[8]).toLocaleUpperCase() == "CORPORATE INCOME TAX" ? String(Number(i[11].tbf).toFixed(2)) : String(Number(i[11].tbf).toFixed(1))
}, },
april: { april: {
tbc: i[1] === 3 && i[12].tbc === "" ? "0" : i[1] === 5 || i[1] === 6 || i[1] === 7 ? String(i[12].tbc.value) : String(i[12].tbc), tbc: i[1] === 3 && i[12].tbc === "" ? "0" : i[1] === 5 || i[1] === 6 || i[1] === 7 ? String(i[12].tbc.value) : String(i[12].tbc),
fcp: i[2] === 3 && i[12].fcp === "" ? "0" : i[2] === 5 || i[2] === 6 || i[2] === 7 ? String(i[12].fcp.value) : String(i[12].fcp), fcp: i[2] === 3 && i[12].fcp === "" ? "0" : i[2] === 5 || i[2] === 6 || i[2] === 7 ? String(i[12].fcp.value) : String(i[8]).toLocaleUpperCase() == "CORPORATE INCOME TAX" ? String(Number(i[12].fcp).toFixed(2)) : String(Number(i[12].fcp).toFixed(1)),
tbf: i[3] === 3 && i[12].tbf === "" ? "0" : i[3] === 5 || i[3] === 6 || i[3] === 7 ? String(i[12].tbf.value) : String(i[12].tbf) tbf: i[3] === 3 && i[12].tbf === "" ? "0" : i[3] === 5 || i[3] === 6 || i[3] === 7 ? String(i[12].tbf.value) : String(i[8]).toLocaleUpperCase() == "CORPORATE INCOME TAX" ? String(Number(i[12].tbf).toFixed(2)) : String(Number(i[12].tbf).toFixed(1))
}, },
may: { may: {
tbc: i[1] === 3 && i[13].tbc === "" ? "0" : i[1] === 5 || i[1] === 6 || i[1] === 7 ? String(i[13].tbc.value) : String(i[13].tbc), tbc: i[1] === 3 && i[13].tbc === "" ? "0" : i[1] === 5 || i[1] === 6 || i[1] === 7 ? String(i[13].tbc.value) : String(i[13].tbc),
fcp: i[2] === 3 && i[13].fcp === "" ? "0" : i[2] === 5 || i[2] === 6 || i[2] === 7 ? String(i[13].fcp.value) : String(i[13].fcp), fcp: i[2] === 3 && i[13].fcp === "" ? "0" : i[2] === 5 || i[2] === 6 || i[2] === 7 ? String(i[13].fcp.value) : String(i[8]).toLocaleUpperCase() == "CORPORATE INCOME TAX" ? String(Number(i[13].fcp).toFixed(2)) : String(Number(i[13].fcp).toFixed(1)),
tbf: i[3] === 3 && i[13].tbf === "" ? "0" : i[3] === 5 || i[3] === 6 || i[3] === 7 ? String(i[13].tbf.value) : String(i[13].tbf) tbf: i[3] === 3 && i[13].tbf === "" ? "0" : i[3] === 5 || i[3] === 6 || i[3] === 7 ? String(i[13].tbf.value) : String(i[8]).toLocaleUpperCase() == "CORPORATE INCOME TAX" ? String(Number(i[13].tbf).toFixed(2)) : String(Number(i[13].tbf).toFixed(1))
}, },
june: { june: {
tbc: i[1] === 3 && i[14].tbc === "" ? "0" : i[1] === 5 || i[1] === 6 || i[1] === 7 ? String(i[14].tbc.value) : String(i[14].tbc), tbc: i[1] === 3 && i[14].tbc === "" ? "0" : i[1] === 5 || i[1] === 6 || i[1] === 7 ? String(i[14].tbc.value) : String(i[14].tbc),
fcp: i[2] === 3 && i[14].fcp === "" ? "0" : i[2] === 5 || i[2] === 6 || i[2] === 7 ? String(i[14].fcp.value) : String(i[14].fcp), fcp: i[2] === 3 && i[14].fcp === "" ? "0" : i[2] === 5 || i[2] === 6 || i[2] === 7 ? String(i[14].fcp.value) : String(i[8]).toLocaleUpperCase() == "CORPORATE INCOME TAX" ? String(Number(i[14].fcp).toFixed(2)) : String(Number(i[14].fcp).toFixed(1)),
tbf: i[3] === 3 && i[14].tbc === "" ? "0" : i[3] === 5 || i[3] === 6 || i[3] === 7 ? String(i[14].tbf.value) : String(i[14].tbf) tbf: i[3] === 3 && i[14].tbc === "" ? "0" : i[3] === 5 || i[3] === 6 || i[3] === 7 ? String(i[14].tbf.value) : String(i[8]).toLocaleUpperCase() == "CORPORATE INCOME TAX" ? String(Number(i[14].tbf).toFixed(2)) : String(Number(i[14].tbf).toFixed(1))
}, },
july: { july: {
tbc: i[1] === 3 && i[15].tbc === "" ? "0" : i[1] === 5 || i[1] === 6 || i[1] === 7 ? String(i[15].tbc.value) : String(i[15].tbc), tbc: i[1] === 3 && i[15].tbc === "" ? "0" : i[1] === 5 || i[1] === 6 || i[1] === 7 ? String(i[15].tbc.value) : String(i[15].tbc),
fcp: i[2] === 3 && i[15].fcp === "" ? "0" : i[2] === 5 || i[2] === 6 || i[2] === 7 ? String(i[15].fcp.value) : String(i[15].fcp), fcp: i[2] === 3 && i[15].fcp === "" ? "0" : i[2] === 5 || i[2] === 6 || i[2] === 7 ? String(i[15].fcp.value) : String(i[8]).toLocaleUpperCase() == "CORPORATE INCOME TAX" ? String(Number(i[15].fcp).toFixed(2)) : String(Number(i[15].fcp).toFixed(1)),
tbf: i[3] === 3 && i[15].tbf === "" ? "0" : i[3] === 5 || i[3] === 6 || i[3] === 7 ? String(i[15].tbf.value) : String(i[15].tbf) tbf: i[3] === 3 && i[15].tbf === "" ? "0" : i[3] === 5 || i[3] === 6 || i[3] === 7 ? String(i[15].tbf.value) : String(i[8]).toLocaleUpperCase() == "CORPORATE INCOME TAX" ? String(Number(i[15].tbf).toFixed(2)) : String(Number(i[15].tbf).toFixed(1))
}, },
august: { august: {
tbc: i[1] === 3 && i[16].tbc === "" ? "0" : i[1] === 5 || i[1] === 6 || i[1] === 7 ? String(i[16].tbc.value) : String(i[16].tbc), tbc: i[1] === 3 && i[16].tbc === "" ? "0" : i[1] === 5 || i[1] === 6 || i[1] === 7 ? String(i[16].tbc.value) : String(i[16].tbc),
fcp: i[2] === 3 && i[16].fcp === "" ? "0" : i[2] === 5 || i[2] === 6 || i[2] === 7 ? String(i[16].fcp.value) : String(i[16].fcp), fcp: i[2] === 3 && i[16].fcp === "" ? "0" : i[2] === 5 || i[2] === 6 || i[2] === 7 ? String(i[16].fcp.value) : String(i[8]).toLocaleUpperCase() == "CORPORATE INCOME TAX" ? String(Number(i[16].fcp).toFixed(2)) : String(Number(i[16].fcp).toFixed(1)),
tbf: i[3] === 3 && i[16].tbf === "" ? "0" : i[3] === 5 || i[3] === 6 || i[3] === 7 ? String(i[16].tbf.value) : String(i[16].tbf) tbf: i[3] === 3 && i[16].tbf === "" ? "0" : i[3] === 5 || i[3] === 6 || i[3] === 7 ? String(i[16].tbf.value) : String(i[8]).toLocaleUpperCase() == "CORPORATE INCOME TAX" ? String(Number(i[16].tbf).toFixed(2)) : String(Number(i[16].tbf).toFixed(1))
}, },
september: { september: {
tbc: i[1] === 3 && i[17].tbc === "" ? "0" : i[1] === 5 || i[1] === 6 || i[1] === 7 ? String(i[17].tbc.value) : String(i[17].tbc), tbc: i[1] === 3 && i[17].tbc === "" ? "0" : i[1] === 5 || i[1] === 6 || i[1] === 7 ? String(i[17].tbc.value) : String(i[17].tbc),
fcp: i[2] === 3 && i[17].fcp === "" ? "0" : i[2] === 5 || i[2] === 6 || i[2] === 7 ? String(i[17].fcp.value) : String(i[17].fcp), fcp: i[2] === 3 && i[17].fcp === "" ? "0" : i[2] === 5 || i[2] === 6 || i[2] === 7 ? String(i[17].fcp.value) : String(i[8]).toLocaleUpperCase() == "CORPORATE INCOME TAX" ? String(Number(i[17].fcp).toFixed(2)) : String(Number(i[17].fcp).toFixed(1)),
tbf: i[3] === 3 && i[17].tbf === "" ? "0" : i[3] === 5 || i[3] === 6 || i[3] === 7 ? String(i[17].tbf.value) : String(i[17].tbf) tbf: i[3] === 3 && i[17].tbf === "" ? "0" : i[3] === 5 || i[3] === 6 || i[3] === 7 ? String(i[17].tbf.value) : String(i[8]).toLocaleUpperCase() == "CORPORATE INCOME TAX" ? String(Number(i[17].tbf).toFixed(2)) : String(Number(i[17].tbf).toFixed(1))
}, },
october: { october: {
tbc: i[1] === 3 && i[18].tbc === "" ? "0" : i[1] === 5 || i[1] === 6 || i[1] === 7 ? String(i[18].tbc.value) : String(i[18].tbc), tbc: i[1] === 3 && i[18].tbc === "" ? "0" : i[1] === 5 || i[1] === 6 || i[1] === 7 ? String(i[18].tbc.value) : String(i[18].tbc),
fcp: i[2] === 3 && i[18].fcp === "" ? "0" : i[2] === 5 || i[2] === 6 || i[2] === 7 ? String(i[18].fcp.value) : String(i[18].fcp), fcp: i[2] === 3 && i[18].fcp === "" ? "0" : i[2] === 5 || i[2] === 6 || i[2] === 7 ? String(i[18].fcp.value) : String(i[8]).toLocaleUpperCase() == "CORPORATE INCOME TAX" ? String(Number(i[18].fcp).toFixed(2)) : String(Number(i[18].fcp).toFixed(1)),
tbf: i[3] === 3 && i[18].tbf === "" ? "0" : i[3] === 5 || i[3] === 6 || i[3] === 7 ? String(i[18].tbf.value) : String(i[18].tbf) tbf: i[3] === 3 && i[18].tbf === "" ? "0" : i[3] === 5 || i[3] === 6 || i[3] === 7 ? String(i[18].tbf.value) : String(i[8]).toLocaleUpperCase() == "CORPORATE INCOME TAX" ? String(Number(i[18].tbf).toFixed(2)) : String(Number(i[18].tbf).toFixed(1))
}, },
november: { november: {
tbc: i[1] === 3 && i[19].tbc === "" ? "0" : i[1] === 5 || i[1] === 6 || i[1] === 7 ? String(i[19].tbc.value) : String(i[19].tbc), tbc: i[1] === 3 && i[19].tbc === "" ? "0" : i[1] === 5 || i[1] === 6 || i[1] === 7 ? String(i[19].tbc.value) : String(i[19].tbc),
fcp: i[2] === 3 && i[19].fcp === "" ? "0" : i[2] === 5 || i[2] === 6 || i[2] === 7 ? String(i[19].fcp.value) : String(i[19].fcp), fcp: i[2] === 3 && i[19].fcp === "" ? "0" : i[2] === 5 || i[2] === 6 || i[2] === 7 ? String(i[19].fcp.value) : String(i[8]).toLocaleUpperCase() == "CORPORATE INCOME TAX" ? String(Number(i[19].fcp).toFixed(2)) : String(Number(i[19].fcp).toFixed(1)),
tbf: i[3] === 3 && i[19].tbf === "" ? "0" : i[3] === 5 || i[3] === 6 || i[3] === 7 ? String(i[19].tbf.value) : String(i[19].tbf) tbf: i[3] === 3 && i[19].tbf === "" ? "0" : i[3] === 5 || i[3] === 6 || i[3] === 7 ? String(i[19].tbf.value) : String(i[8]).toLocaleUpperCase() == "CORPORATE INCOME TAX" ? String(Number(i[19].tbf).toFixed(2)) : String(Number(i[19].tbf).toFixed(1))
}, },
december: { december: {
tbc: i[1] === 3 && i[20].tbc === "" ? "0" : i[1] === 5 || i[1] === 6 || i[1] === 7 ? String(i[20].tbc.value) : String(i[20].tbc), tbc: i[1] === 3 && i[20].tbc === "" ? "0" : i[1] === 5 || i[1] === 6 || i[1] === 7 ? String(i[20].tbc.value) : String(i[20].tbc),
fcp: i[2] === 3 && i[20].fcp === "" ? "0" : i[2] === 5 || i[2] === 6 || i[2] === 7 ? String(i[20].fcp.value) : String(i[20].fcp), fcp: i[2] === 3 && i[20].fcp === "" ? "0" : i[2] === 5 || i[2] === 6 || i[2] === 7 ? String(i[20].fcp.value) : String(i[8]).toLocaleUpperCase() == "CORPORATE INCOME TAX" ? String(Number(i[20].fcp).toFixed(2)) : String(Number(i[20].fcp).toFixed(1)),
tbf: i[3] === 3 && i[20].tbf === "" ? "0" : i[3] === 5 || i[3] === 6 || i[3] === 7 ? String(i[20].tbf.value) : String(i[20].tbf) tbf: i[3] === 3 && i[20].tbf === "" ? "0" : i[3] === 5 || i[3] === 6 || i[3] === 7 ? String(i[20].tbf.value) : String(i[8]).toLocaleUpperCase() == "CORPORATE INCOME TAX" ? String(Number(i[20].tbf).toFixed(2)) : String(Number(i[20].tbf).toFixed(1))
}, },
total_current_year: String(Number(i[21]).toFixed(1)), total_current_year: String(i[8]).toLocaleUpperCase() == "CORPORATE INCOME TAX" ? String(Number(i[21]).toFixed(2)) : String(Number(i[21]).toFixed(1)),
total_next_year: { total_next_year: {
tbc: String(Number(i[22].tbc).toFixed(1)), tbc: String(Number(i[22].tbc).toFixed(1)),
fcp: String(i[8]).toLocaleUpperCase() == "CORPORATE INCOME TAX" ? String(Number(i[22].fcp).toFixed(2)) : String(Number(i[22].fcp).toFixed(1)), fcp: String(i[8]).toLocaleUpperCase() == "CORPORATE INCOME TAX" ? String(Number(i[22].fcp).toFixed(2)) : String(Number(i[22].fcp).toFixed(1)),
tbf: String(i[8]).toLocaleUpperCase() == "CORPORATE INCOME TAX" ? String(Number(i[22].tbf).toFixed(2)) : String(Number(i[22].tbf).toFixed(1)), tbf: String(i[8]).toLocaleUpperCase() == "CORPORATE INCOME TAX" ? String(Number(i[22].tbf).toFixed(2)) : String(Number(i[22].tbf).toFixed(1))
}, },
total_more_year: { total_more_year: {
tbc: String(Number(i[23].tbc).toFixed(1)), tbc: String(Number(i[23].tbc).toFixed(1)),
fcp: String(i[8]).toLocaleUpperCase() == "CORPORATE INCOME TAX" ? String(Number(i[23].fcp).toFixed(2)) : String(Number(i[23].fcp).toFixed(1)), fcp: String(i[8]).toLocaleUpperCase() == "CORPORATE INCOME TAX" ? String(Number(i[23].fcp).toFixed(2)) : String(Number(i[23].fcp).toFixed(1)),
tbf: String(i[8]).toLocaleUpperCase() == "CORPORATE INCOME TAX" ? String(Number(i[23].tbf).toFixed(2)) : String(Number(i[23].tbf).toFixed(1)), tbf: String(i[8]).toLocaleUpperCase() == "CORPORATE INCOME TAX" ? String(Number(i[23].tbf).toFixed(2)) : String(Number(i[23].tbf).toFixed(1))
} }
}) })
}) })
...@@ -463,8 +463,9 @@ export default class TaxPlanning extends Component { ...@@ -463,8 +463,9 @@ export default class TaxPlanning extends Component {
checkUpload() { checkUpload() {
api.create().checkUploadMB(this.state.payload).then(response => { api.create().checkUploadMB(this.state.payload).then(response => {
// console.log(this.state.payload); console.log(this.state.payload);
// console.log(response) console.log(JSON.stringify(this.state.payload));
console.log(response)
if (response.data) { if (response.data) {
if (response.data.status === 'success') { if (response.data.status === 'success') {
this.setState({ visibleUpload: false, visibleTP: false, loading: true }) this.setState({ visibleUpload: false, visibleTP: false, loading: true })
...@@ -481,28 +482,28 @@ export default class TaxPlanning extends Component { ...@@ -481,28 +482,28 @@ export default class TaxPlanning extends Component {
// {tbc: item.formula.tbc, fcp: item.formula.fcp, tbf: item.formula.tbf}, // {tbc: item.formula.tbc, fcp: item.formula.fcp, tbf: item.formula.tbf},
item.level, item.level,
item.item_report, item.item_report,
{ tbc: item.type_report_id.tbc == 5 || item.type_report_id.tbc == 6 || item.type_report_id.tbc == 7 ? { value: item.january.tbc, formula: item.january_formula } : Number(item.january.tbc).toFixed(1), fcp: item.type_report_id.fcp == 5 || item.type_report_id.fcp == 6 || item.type_report_id.fcp == 7 || item.type_report_id.fcp == 7 ? { value: item.january.fcp, formula: item.january_formula } : Number(item.january.fcp).toFixed(1), tbf: item.type_report_id.tbf == 5 || item.type_report_id.tbf == 6 || item.type_report_id.tbf == 7 || item.type_report_id.tbf == 7 ? { value: item.january.tbf, formula: item.january_formula } : Number(item.january.tbf).toFixed(1) }, { tbc: item.type_report_id.tbc == 5 || item.type_report_id.tbc == 6 || item.type_report_id.tbc == 7 ? { value: item.january.tbc, formula: item.january_formula } : Number(item.january.tbc).toFixed(1), fcp: item.type_report_id.fcp == 5 || item.type_report_id.fcp == 6 || item.type_report_id.fcp == 7 || item.type_report_id.fcp == 7 ? { value: item.january.fcp, formula: item.january_formula } : String(item.item_report).toLocaleUpperCase() == "CORPORATE INCOME TAX" ? Number(item.january.fcp).toFixed(2) : Number(item.january.fcp).toFixed(1), tbf: item.type_report_id.tbf == 5 || item.type_report_id.tbf == 6 || item.type_report_id.tbf == 7 || item.type_report_id.tbf == 7 ? { value: item.january.tbf, formula: item.january_formula } : String(item.item_report).toLocaleUpperCase() == "CORPORATE INCOME TAX" ? Number(item.january.tbf).toFixed(2) : Number(item.january.tbf).toFixed(1) },
{ tbc: item.type_report_id.tbc == 5 || item.type_report_id.tbc == 6 || item.type_report_id.tbc == 7 ? { value: item.february.tbc, formula: item.february_formula } : Number(item.february.tbc).toFixed(1), fcp: item.type_report_id.fcp == 5 || item.type_report_id.fcp == 6 || item.type_report_id.fcp == 7 ? { value: item.february.fcp, formula: item.february_formula } : Number(item.february.fcp).toFixed(1), tbf: item.type_report_id.tbf == 5 || item.type_report_id.tbf == 6 || item.type_report_id.tbf == 7 ? { value: item.february.tbf, formula: item.february_formula } : Number(item.february.tbf).toFixed(1) }, { tbc: item.type_report_id.tbc == 5 || item.type_report_id.tbc == 6 || item.type_report_id.tbc == 7 ? { value: item.february.tbc, formula: item.february_formula } : Number(item.february.tbc).toFixed(1), fcp: item.type_report_id.fcp == 5 || item.type_report_id.fcp == 6 || item.type_report_id.fcp == 7 ? { value: item.february.fcp, formula: item.february_formula } : String(item.item_report).toLocaleUpperCase() == "CORPORATE INCOME TAX" ? Number(item.february.fcp).toFixed(2) : Number(item.february.fcp).toFixed(1), tbf: item.type_report_id.tbf == 5 || item.type_report_id.tbf == 6 || item.type_report_id.tbf == 7 ? { value: item.february.tbf, formula: item.february_formula } : String(item.item_report).toLocaleUpperCase() == "CORPORATE INCOME TAX" ? Number(item.february.tbf).toFixed(2) : Number(item.february.tbf).toFixed(1) },
{ tbc: item.type_report_id.tbc == 5 || item.type_report_id.tbc == 6 || item.type_report_id.tbc == 7 ? { value: item.march.tbc, formula: item.march_formula } : Number(item.march.tbc).toFixed(1), fcp: item.type_report_id.fcp == 5 || item.type_report_id.fcp == 6 || item.type_report_id.fcp == 7 ? { value: item.march.fcp, formula: item.march_formula } : Number(item.march.fcp).toFixed(1), tbf: item.type_report_id.tbf == 5 || item.type_report_id.tbf == 6 || item.type_report_id.tbf == 7 ? { value: item.march.tbf, formula: item.march_formula } : Number(item.march.tbf).toFixed(1) }, { tbc: item.type_report_id.tbc == 5 || item.type_report_id.tbc == 6 || item.type_report_id.tbc == 7 ? { value: item.march.tbc, formula: item.march_formula } : Number(item.march.tbc).toFixed(1), fcp: item.type_report_id.fcp == 5 || item.type_report_id.fcp == 6 || item.type_report_id.fcp == 7 ? { value: item.march.fcp, formula: item.march_formula } : String(item.item_report).toLocaleUpperCase() == "CORPORATE INCOME TAX" ? Number(item.march.fcp).toFixed(2) : Number(item.march.fcp).toFixed(1), tbf: item.type_report_id.tbf == 5 || item.type_report_id.tbf == 6 || item.type_report_id.tbf == 7 ? { value: item.march.tbf, formula: item.march_formula } : String(item.item_report).toLocaleUpperCase() == "CORPORATE INCOME TAX" ? Number(item.march.tbf).toFixed(2) : Number(item.march.tbf).toFixed(1) },
{ tbc: item.type_report_id.tbc == 5 || item.type_report_id.tbc == 6 || item.type_report_id.tbc == 7 ? { value: item.april.tbc, formula: item.april_formula } : Number(item.april.tbc).toFixed(1), fcp: item.type_report_id.fcp == 5 || item.type_report_id.fcp == 6 || item.type_report_id.fcp == 7 ? { value: item.april.fcp, formula: item.april_formula } : Number(item.april.fcp).toFixed(1), tbf: item.type_report_id.tbf == 5 || item.type_report_id.tbf == 6 || item.type_report_id.tbf == 7 ? { value: item.april.tbf, formula: item.april_formula } : Number(item.april.tbf).toFixed(1) }, { tbc: item.type_report_id.tbc == 5 || item.type_report_id.tbc == 6 || item.type_report_id.tbc == 7 ? { value: item.april.tbc, formula: item.april_formula } : Number(item.april.tbc).toFixed(1), fcp: item.type_report_id.fcp == 5 || item.type_report_id.fcp == 6 || item.type_report_id.fcp == 7 ? { value: item.april.fcp, formula: item.april_formula } : String(item.item_report).toLocaleUpperCase() == "CORPORATE INCOME TAX" ? Number(item.april.fcp).toFixed(2) : Number(item.april.fcp).toFixed(1), tbf: item.type_report_id.tbf == 5 || item.type_report_id.tbf == 6 || item.type_report_id.tbf == 7 ? { value: item.april.tbf, formula: item.april_formula } : String(item.item_report).toLocaleUpperCase() == "CORPORATE INCOME TAX" ? Number(item.april.tbf).toFixed(2) : Number(item.april.tbf).toFixed(1) },
{ tbc: item.type_report_id.tbc == 5 || item.type_report_id.tbc == 6 || item.type_report_id.tbc == 7 ? { value: item.may.tbc, formula: item.may_formula } : Number(item.may.tbc).toFixed(1), fcp: item.type_report_id.fcp == 5 || item.type_report_id.fcp == 6 || item.type_report_id.fcp == 7 ? { value: item.may.fcp, formula: item.may_formula } : Number(item.may.fcp).toFixed(1), tbf: item.type_report_id.tbf == 5 || item.type_report_id.tbf == 6 || item.type_report_id.tbf == 7 ? { value: item.may.tbf, formula: item.may_formula } : Number(item.may.tbf).toFixed(1) }, { tbc: item.type_report_id.tbc == 5 || item.type_report_id.tbc == 6 || item.type_report_id.tbc == 7 ? { value: item.may.tbc, formula: item.may_formula } : Number(item.may.tbc).toFixed(1), fcp: item.type_report_id.fcp == 5 || item.type_report_id.fcp == 6 || item.type_report_id.fcp == 7 ? { value: item.may.fcp, formula: item.may_formula } : String(item.item_report).toLocaleUpperCase() == "CORPORATE INCOME TAX" ? Number(item.may.fcp).toFixed(2) : Number(item.may.fcp).toFixed(1), tbf: item.type_report_id.tbf == 5 || item.type_report_id.tbf == 6 || item.type_report_id.tbf == 7 ? { value: item.may.tbf, formula: item.may_formula } : String(item.item_report).toLocaleUpperCase() == "CORPORATE INCOME TAX" ? Number(item.may.tbf).toFixed(2) : Number(item.may.tbf).toFixed(1) },
{ tbc: item.type_report_id.tbc == 5 || item.type_report_id.tbc == 6 || item.type_report_id.tbc == 7 ? { value: item.june.tbc, formula: item.june_formula } : Number(item.june.tbc).toFixed(1), fcp: item.type_report_id.fcp == 5 || item.type_report_id.fcp == 6 || item.type_report_id.fcp == 7 ? { value: item.june.fcp, formula: item.june_formula } : Number(item.june.fcp).toFixed(1), tbf: item.type_report_id.tbf == 5 || item.type_report_id.tbf == 6 || item.type_report_id.tbf == 7 ? { value: item.june.tbf, formula: item.june_formula } : Number(item.june.tbf).toFixed(1) }, { tbc: item.type_report_id.tbc == 5 || item.type_report_id.tbc == 6 || item.type_report_id.tbc == 7 ? { value: item.june.tbc, formula: item.june_formula } : Number(item.june.tbc).toFixed(1), fcp: item.type_report_id.fcp == 5 || item.type_report_id.fcp == 6 || item.type_report_id.fcp == 7 ? { value: item.june.fcp, formula: item.june_formula } : String(item.item_report).toLocaleUpperCase() == "CORPORATE INCOME TAX" ? Number(item.june.fcp).toFixed(2) : Number(item.june.fcp).toFixed(1), tbf: item.type_report_id.tbf == 5 || item.type_report_id.tbf == 6 || item.type_report_id.tbf == 7 ? { value: item.june.tbf, formula: item.june_formula } : String(item.item_report).toLocaleUpperCase() == "CORPORATE INCOME TAX" ? Number(item.june.tbf).toFixed(2) : Number(item.june.tbf).toFixed(1) },
{ tbc: item.type_report_id.tbc == 5 || item.type_report_id.tbc == 6 || item.type_report_id.tbc == 7 ? { value: item.july.tbc, formula: item.july_formula } : Number(item.july.tbc).toFixed(1), fcp: item.type_report_id.fcp == 5 || item.type_report_id.fcp == 6 || item.type_report_id.fcp == 7 ? { value: item.july.fcp, formula: item.july_formula } : Number(item.july.fcp).toFixed(1), tbf: item.type_report_id.tbf == 5 || item.type_report_id.tbf == 6 || item.type_report_id.tbf == 7 ? { value: item.july.tbf, formula: item.july_formula } : Number(item.july.tbf).toFixed(1) }, { tbc: item.type_report_id.tbc == 5 || item.type_report_id.tbc == 6 || item.type_report_id.tbc == 7 ? { value: item.july.tbc, formula: item.july_formula } : Number(item.july.tbc).toFixed(1), fcp: item.type_report_id.fcp == 5 || item.type_report_id.fcp == 6 || item.type_report_id.fcp == 7 ? { value: item.july.fcp, formula: item.july_formula } : String(item.item_report).toLocaleUpperCase() == "CORPORATE INCOME TAX" ? Number(item.july.fcp).toFixed(2) : Number(item.july.fcp).toFixed(1), tbf: item.type_report_id.tbf == 5 || item.type_report_id.tbf == 6 || item.type_report_id.tbf == 7 ? { value: item.july.tbf, formula: item.july_formula } : String(item.item_report).toLocaleUpperCase() == "CORPORATE INCOME TAX" ? Number(item.july.tbf).toFixed(2) : Number(item.july.tbf).toFixed(1) },
{ tbc: item.type_report_id.tbc == 5 || item.type_report_id.tbc == 6 || item.type_report_id.tbc == 7 ? { value: item.august.tbc, formula: item.august_formula } : item.august.tbc === null ? "0" : item.august.tbc === "" ? "0" : Number(item.august.tbc).toFixed(1), fcp: item.type_report_id.fcp == 5 || item.type_report_id.fcp == 6 || item.type_report_id.fcp == 7 ? { value: item.august.fcp, formula: item.august_formula } : Number(item.august.fcp).toFixed(1), tbf: item.type_report_id.tbf == 5 || item.type_report_id.tbf == 6 || item.type_report_id.tbf == 7 ? { value: item.august.tbf, formula: item.august_formula } : Number(item.august.tbf).toFixed(1) }, { tbc: item.type_report_id.tbc == 5 || item.type_report_id.tbc == 6 || item.type_report_id.tbc == 7 ? { value: item.august.tbc, formula: item.august_formula } : item.august.tbc === null ? "0" : item.august.tbc === "" ? "0" : Number(item.august.tbc).toFixed(1), fcp: item.type_report_id.fcp == 5 || item.type_report_id.fcp == 6 || item.type_report_id.fcp == 7 ? { value: item.august.fcp, formula: item.august_formula } : String(item.item_report).toLocaleUpperCase() == "CORPORATE INCOME TAX" ? Number(item.august.fcp).toFixed(2) : Number(item.august.fcp).toFixed(1), tbf: item.type_report_id.tbf == 5 || item.type_report_id.tbf == 6 || item.type_report_id.tbf == 7 ? { value: item.august.tbf, formula: item.august_formula } : String(item.item_report).toLocaleUpperCase() == "CORPORATE INCOME TAX" ? Number(item.august.tbf).toFixed(2) : Number(item.august.tbf).toFixed(1) },
{ tbc: item.type_report_id.tbc == 5 || item.type_report_id.tbc == 6 || item.type_report_id.tbc == 7 ? { value: item.september.tbc, formula: item.september_formula } : Number(item.september.tbc).toFixed(1), fcp: item.type_report_id.fcp == 5 || item.type_report_id.fcp == 6 || item.type_report_id.fcp == 7 ? { value: item.september.fcp, formula: item.september_formula } : Number(item.september.fcp).toFixed(1), tbf: item.type_report_id.tbf == 5 || item.type_report_id.tbf == 6 || item.type_report_id.tbf == 7 ? { value: item.september.tbf, formula: item.september_formula } : Number(item.september.tbf).toFixed(1) }, { tbc: item.type_report_id.tbc == 5 || item.type_report_id.tbc == 6 || item.type_report_id.tbc == 7 ? { value: item.september.tbc, formula: item.september_formula } : Number(item.september.tbc).toFixed(1), fcp: item.type_report_id.fcp == 5 || item.type_report_id.fcp == 6 || item.type_report_id.fcp == 7 ? { value: item.september.fcp, formula: item.september_formula } : String(item.item_report).toLocaleUpperCase() == "CORPORATE INCOME TAX" ? Number(item.september.fcp).toFixed(2) : Number(item.september.fcp).toFixed(1), tbf: item.type_report_id.tbf == 5 || item.type_report_id.tbf == 6 || item.type_report_id.tbf == 7 ? { value: item.september.tbf, formula: item.september_formula } : String(item.item_report).toLocaleUpperCase() == "CORPORATE INCOME TAX" ? Number(item.september.tbf).toFixed(2) : Number(item.september.tbf).toFixed(1) },
{ tbc: item.type_report_id.tbc == 5 || item.type_report_id.tbc == 6 || item.type_report_id.tbc == 7 ? { value: item.october.tbc, formula: item.october_formula } : Number(item.october.tbc).toFixed(1), fcp: item.type_report_id.fcp == 5 || item.type_report_id.fcp == 6 || item.type_report_id.fcp == 7 ? { value: item.october.fcp, formula: item.october_formula } : Number(item.october.fcp).toFixed(1), tbf: item.type_report_id.tbf == 5 || item.type_report_id.tbf == 6 || item.type_report_id.tbf == 7 ? { value: item.october.tbf, formula: item.october_formula } : Number(item.october.tbf).toFixed(1) }, { tbc: item.type_report_id.tbc == 5 || item.type_report_id.tbc == 6 || item.type_report_id.tbc == 7 ? { value: item.october.tbc, formula: item.october_formula } : Number(item.october.tbc).toFixed(1), fcp: item.type_report_id.fcp == 5 || item.type_report_id.fcp == 6 || item.type_report_id.fcp == 7 ? { value: item.october.fcp, formula: item.october_formula } : String(item.item_report).toLocaleUpperCase() == "CORPORATE INCOME TAX" ? Number(item.october.fcp).toFixed(2) : Number(item.october.fcp).toFixed(1), tbf: item.type_report_id.tbf == 5 || item.type_report_id.tbf == 6 || item.type_report_id.tbf == 7 ? { value: item.october.tbf, formula: item.october_formula } : String(item.item_report).toLocaleUpperCase() == "CORPORATE INCOME TAX" ? Number(item.october.tbf).toFixed(2) : Number(item.october.tbf).toFixed(1) },
{ tbc: item.type_report_id.tbc == 5 || item.type_report_id.tbc == 6 || item.type_report_id.tbc == 7 ? { value: item.november.tbc, formula: item.november_formula } : Number(item.november.tbc).toFixed(1), fcp: item.type_report_id.fcp == 5 || item.type_report_id.fcp == 6 || item.type_report_id.fcp == 7 ? { value: item.november.fcp, formula: item.november_formula } : Number(item.november.fcp).toFixed(1), tbf: item.type_report_id.tbf == 5 || item.type_report_id.tbf == 6 || item.type_report_id.tbf == 7 ? { value: item.november.tbf, formula: item.november_formula } : Number(item.november.tbf).toFixed(1) }, { tbc: item.type_report_id.tbc == 5 || item.type_report_id.tbc == 6 || item.type_report_id.tbc == 7 ? { value: item.november.tbc, formula: item.november_formula } : Number(item.november.tbc).toFixed(1), fcp: item.type_report_id.fcp == 5 || item.type_report_id.fcp == 6 || item.type_report_id.fcp == 7 ? { value: item.november.fcp, formula: item.november_formula } : String(item.item_report).toLocaleUpperCase() == "CORPORATE INCOME TAX" ? Number(item.november.fcp).toFixed(2) : Number(item.november.fcp).toFixed(1), tbf: item.type_report_id.tbf == 5 || item.type_report_id.tbf == 6 || item.type_report_id.tbf == 7 ? { value: item.november.tbf, formula: item.november_formula } : String(item.item_report).toLocaleUpperCase() == "CORPORATE INCOME TAX" ? Number(item.november.tbf).toFixed(2) : Number(item.november.tbf).toFixed(1) },
{ tbc: item.type_report_id.tbc == 5 || item.type_report_id.tbc == 6 || item.type_report_id.tbc == 7 ? { value: item.december.tbc, formula: item.december_formula } : Number(item.december.tbc).toFixed(1), fcp: item.type_report_id.fcp == 5 || item.type_report_id.fcp == 6 || item.type_report_id.fcp == 7 ? { value: item.december.fcp, formula: item.december_formula } : Number(item.december.fcp).toFixed(1), tbf: item.type_report_id.tbf == 5 || item.type_report_id.tbf == 6 || item.type_report_id.tbf == 7 ? { value: item.december.tbf, formula: item.december_formula } : Number(item.december.tbf).toFixed(1) }, { tbc: item.type_report_id.tbc == 5 || item.type_report_id.tbc == 6 || item.type_report_id.tbc == 7 ? { value: item.december.tbc, formula: item.december_formula } : Number(item.december.tbc).toFixed(1), fcp: item.type_report_id.fcp == 5 || item.type_report_id.fcp == 6 || item.type_report_id.fcp == 7 ? { value: item.december.fcp, formula: item.december_formula } : String(item.item_report).toLocaleUpperCase() == "CORPORATE INCOME TAX" ? Number(item.december.fcp).toFixed(2) : Number(item.december.fcp).toFixed(1), tbf: item.type_report_id.tbf == 5 || item.type_report_id.tbf == 6 || item.type_report_id.tbf == 7 ? { value: item.december.tbf, formula: item.december_formula } : String(item.item_report).toLocaleUpperCase() == "CORPORATE INCOME TAX" ? Number(item.december.tbf).toFixed(2) : Number(item.december.tbf).toFixed(1) },
item.total_current_year, String(item.item_report).toLocaleUpperCase() == "CORPORATE INCOME TAX" ? Number(item.total_current_year).toFixed(2) : Number(item.total_current_year).toFixed(1),
{ {
tbc: Number(item.type_report_id.tbc) === 3 && item.total_next_year.tbc === "" ? "0" : item.total_next_year.tbc, tbc: Number(item.type_report_id.tbc) === 3 && item.total_next_year.tbc === "" ? "0" : String(item.item_report).toLocaleUpperCase() == "CORPORATE INCOME TAX" ? Number(item.total_next_year.tbc).toFixed(2) : Number(item.total_next_year.tbc).toFixed(1),
fcp: Number(item.type_report_id.fcp) === 3 && item.total_next_year.fcp === "" ? "0" : item.total_next_year.fcp, fcp: Number(item.type_report_id.fcp) === 3 && item.total_next_year.fcp === "" ? "0" : String(item.item_report).toLocaleUpperCase() == "CORPORATE INCOME TAX" ? Number(item.total_next_year.fcp).toFixed(2) : Number(item.total_next_year.fcp).toFixed(1),
tbf: Number(item.type_report_id.tbf) === 3 && item.total_next_year.tbf === "" ? "0" : item.total_next_year.tbf tbf: Number(item.type_report_id.tbf) === 3 && item.total_next_year.tbf === "" ? "0" : String(item.item_report).toLocaleUpperCase() == "CORPORATE INCOME TAX" ? Number(item.total_next_year.tbf).toFixed(2) : Number(item.total_next_year.tbf).toFixed(1)
}, },
{ {
tbc: Number(item.type_report_id.tbc) === 3 && item.total_more_year.tbc === "" ? "0" : item.total_more_year.tbc, tbc: Number(item.type_report_id.tbc) === 3 && item.total_more_year.tbc === "" ? "0" : String(item.item_report).toLocaleUpperCase() == "CORPORATE INCOME TAX" ? Number(item.total_more_year.tbc).toFixed(2) : Number(item.total_more_year.tbc).toFixed(1),
fcp: Number(item.type_report_id.fcp) === 3 && item.total_more_year.fcp === "" ? "0" : item.total_more_year.fcp, fcp: Number(item.type_report_id.fcp) === 3 && item.total_more_year.fcp === "" ? "0" : String(item.item_report).toLocaleUpperCase() == "CORPORATE INCOME TAX" ? Number(item.total_more_year.fcp).toFixed(2) : Number(item.total_more_year.fcp).toFixed(1),
tbf: Number(item.type_report_id.tbf) === 3 && item.total_more_year.tbf === "" ? "0" : item.total_more_year.tbf tbf: Number(item.type_report_id.tbf) === 3 && item.total_more_year.tbf === "" ? "0" : String(item.item_report).toLocaleUpperCase() == "CORPORATE INCOME TAX" ? Number(item.total_more_year.tbf).toFixed(2) : Number(item.total_more_year.tbf).toFixed(1)
}, },
item.orders, item.orders,
{ tbc: item.condition_it_should_be.tbc, fcp: item.condition_it_should_be.fcp, tbf: item.condition_it_should_be.tbf }, { tbc: item.condition_it_should_be.tbc, fcp: item.condition_it_should_be.fcp, tbf: item.condition_it_should_be.tbf },
...@@ -534,65 +535,65 @@ export default class TaxPlanning extends Component { ...@@ -534,65 +535,65 @@ export default class TaxPlanning extends Component {
item_report_id: i[4], item_report_id: i[4],
january: { january: {
tbc: i[1] === 3 && i[9].tbc === "" ? "0" : i[1] === 5 || i[1] === 6 || i[1] === 7 ? String(i[9].tbc.value) : String(i[9].tbc), tbc: i[1] === 3 && i[9].tbc === "" ? "0" : i[1] === 5 || i[1] === 6 || i[1] === 7 ? String(i[9].tbc.value) : String(i[9].tbc),
fcp: i[2] === 3 && i[9].fcp === "" ? "0" : i[2] === 5 || i[2] === 6 || i[2] === 7 ? String(i[9].fcp.value) : String(i[9].fcp), fcp: i[2] === 3 && i[9].fcp === "" ? "0" : i[2] === 5 || i[2] === 6 || i[2] === 7 ? String(i[9].fcp.value) : String(i[8]).toLocaleUpperCase() == "CORPORATE INCOME TAX" ? String(Number(i[9].fcp).toFixed(2)) : String(Number(i[9].fcp).toFixed(1)) ,
tbf: i[3] === 3 && i[9].tbf === "" ? "0" : i[3] === 5 || i[3] === 6 || i[3] === 7 ? String(i[9].tbf.value) : String(i[9].tbf) tbf: i[3] === 3 && i[9].tbf === "" ? "0" : i[3] === 5 || i[3] === 6 || i[3] === 7 ? String(i[9].tbf.value) : String(i[8]).toLocaleUpperCase() == "CORPORATE INCOME TAX" ? String(Number(i[9].tbf).toFixed(2)) : String(Number(i[9].tbf).toFixed(1))
}, },
february: { february: {
tbc: i[1] === 3 && i[10].tbc === "" ? "0" : i[1] === 5 || i[1] === 6 || i[1] === 7 ? String(i[10].tbc.value) : String(i[10].tbc), tbc: i[1] === 3 && i[10].tbc === "" ? "0" : i[1] === 5 || i[1] === 6 || i[1] === 7 ? String(i[10].tbc.value) : String(i[10].tbc),
fcp: i[2] === 3 && i[10].fcp === "" ? "0" : i[2] === 5 || i[2] === 6 || i[2] === 7 ? String(i[10].fcp.value) : String(i[10].fcp), fcp: i[2] === 3 && i[10].fcp === "" ? "0" : i[2] === 5 || i[2] === 6 || i[2] === 7 ? String(i[10].fcp.value) : String(i[8]).toLocaleUpperCase() == "CORPORATE INCOME TAX" ? String(Number(i[10].fcp).toFixed(2)) : String(Number(i[10].fcp).toFixed(1)),
tbf: i[3] === 3 && i[10].tbf === "" ? "0" : i[3] === 5 || i[3] === 6 || i[3] === 7 ? String(i[10].tbf.value) : String(i[10].tbf) tbf: i[3] === 3 && i[10].tbf === "" ? "0" : i[3] === 5 || i[3] === 6 || i[3] === 7 ? String(i[10].tbf.value) : String(i[8]).toLocaleUpperCase() == "CORPORATE INCOME TAX" ? String(Number(i[10].tbf).toFixed(2)) : String(Number(i[10].tbf).toFixed(1))
}, },
march: { march: {
tbc: i[1] === 3 && i[11].tbc === "" ? "0" : i[1] === 5 || i[1] === 6 || i[1] === 7 ? String(i[11].tbc.value) : String(i[11].tbc), tbc: i[1] === 3 && i[11].tbc === "" ? "0" : i[1] === 5 || i[1] === 6 || i[1] === 7 ? String(i[11].tbc.value) : String(i[11].tbc),
fcp: i[2] === 3 && i[11].fcp === "" ? "0" : i[2] === 5 || i[2] === 6 || i[2] === 7 ? String(i[11].fcp.value) : String(i[11].fcp), fcp: i[2] === 3 && i[11].fcp === "" ? "0" : i[2] === 5 || i[2] === 6 || i[2] === 7 ? String(i[11].fcp.value) : String(i[8]).toLocaleUpperCase() == "CORPORATE INCOME TAX" ? String(Number(i[11].fcp).toFixed(2)) : String(Number(i[11].fcp).toFixed(1)),
tbf: i[3] === 3 && i[11].tbf === "" ? "0" : i[3] === 5 || i[3] === 6 || i[3] === 7 ? String(i[11].tbf.value) : String(i[11].tbf) tbf: i[3] === 3 && i[11].tbf === "" ? "0" : i[3] === 5 || i[3] === 6 || i[3] === 7 ? String(i[11].tbf.value) : String(i[8]).toLocaleUpperCase() == "CORPORATE INCOME TAX" ? String(Number(i[11].tbf).toFixed(2)) : String(Number(i[11].tbf).toFixed(1))
}, },
april: { april: {
tbc: i[1] === 3 && i[12].tbc === "" ? "0" : i[1] === 5 || i[1] === 6 || i[1] === 7 ? String(i[12].tbc.value) : String(i[12].tbc), tbc: i[1] === 3 && i[12].tbc === "" ? "0" : i[1] === 5 || i[1] === 6 || i[1] === 7 ? String(i[12].tbc.value) : String(i[12].tbc),
fcp: i[2] === 3 && i[12].fcp === "" ? "0" : i[2] === 5 || i[2] === 6 || i[2] === 7 ? String(i[12].fcp.value) : String(i[12].fcp), fcp: i[2] === 3 && i[12].fcp === "" ? "0" : i[2] === 5 || i[2] === 6 || i[2] === 7 ? String(i[12].fcp.value) : String(i[8]).toLocaleUpperCase() == "CORPORATE INCOME TAX" ? String(Number(i[12].fcp).toFixed(2)) : String(Number(i[12].fcp).toFixed(1)),
tbf: i[3] === 3 && i[12].tbf === "" ? "0" : i[3] === 5 || i[3] === 6 || i[3] === 7 ? String(i[12].tbf.value) : String(i[12].tbf) tbf: i[3] === 3 && i[12].tbf === "" ? "0" : i[3] === 5 || i[3] === 6 || i[3] === 7 ? String(i[12].tbf.value) : String(i[8]).toLocaleUpperCase() == "CORPORATE INCOME TAX" ? String(Number(i[12].tbf).toFixed(2)) : String(Number(i[12].tbf).toFixed(1))
}, },
may: { may: {
tbc: i[1] === 3 && i[13].tbc === "" ? "0" : i[1] === 5 || i[1] === 6 || i[1] === 7 ? String(i[13].tbc.value) : String(i[13].tbc), tbc: i[1] === 3 && i[13].tbc === "" ? "0" : i[1] === 5 || i[1] === 6 || i[1] === 7 ? String(i[13].tbc.value) : String(i[13].tbc),
fcp: i[2] === 3 && i[13].fcp === "" ? "0" : i[2] === 5 || i[2] === 6 || i[2] === 7 ? String(i[13].fcp.value) : String(i[13].fcp), fcp: i[2] === 3 && i[13].fcp === "" ? "0" : i[2] === 5 || i[2] === 6 || i[2] === 7 ? String(i[13].fcp.value) : String(i[8]).toLocaleUpperCase() == "CORPORATE INCOME TAX" ? String(Number(i[13].fcp).toFixed(2)) : String(Number(i[13].fcp).toFixed(1)),
tbf: i[3] === 3 && i[13].tbf === "" ? "0" : i[3] === 5 || i[3] === 6 || i[3] === 7 ? String(i[13].tbf.value) : String(i[13].tbf) tbf: i[3] === 3 && i[13].tbf === "" ? "0" : i[3] === 5 || i[3] === 6 || i[3] === 7 ? String(i[13].tbf.value) : String(i[8]).toLocaleUpperCase() == "CORPORATE INCOME TAX" ? String(Number(i[13].tbf).toFixed(2)) : String(Number(i[13].tbf).toFixed(1))
}, },
june: { june: {
tbc: i[1] === 3 && i[14].tbc === "" ? "0" : i[1] === 5 || i[1] === 6 || i[1] === 7 ? String(i[14].tbc.value) : String(i[14].tbc), tbc: i[1] === 3 && i[14].tbc === "" ? "0" : i[1] === 5 || i[1] === 6 || i[1] === 7 ? String(i[14].tbc.value) : String(i[14].tbc),
fcp: i[2] === 3 && i[14].fcp === "" ? "0" : i[2] === 5 || i[2] === 6 || i[2] === 7 ? String(i[14].fcp.value) : String(i[14].fcp), fcp: i[2] === 3 && i[14].fcp === "" ? "0" : i[2] === 5 || i[2] === 6 || i[2] === 7 ? String(i[14].fcp.value) : String(i[8]).toLocaleUpperCase() == "CORPORATE INCOME TAX" ? String(Number(i[14].fcp).toFixed(2)) : String(Number(i[14].fcp).toFixed(1)),
tbf: i[3] === 3 && i[14].tbc === "" ? "0" : i[3] === 5 || i[3] === 6 || i[3] === 7 ? String(i[14].tbf.value) : String(i[14].tbf) tbf: i[3] === 3 && i[14].tbc === "" ? "0" : i[3] === 5 || i[3] === 6 || i[3] === 7 ? String(i[14].tbf.value) : String(i[8]).toLocaleUpperCase() == "CORPORATE INCOME TAX" ? String(Number(i[14].tbf).toFixed(2)) : String(Number(i[14].tbf).toFixed(1))
}, },
july: { july: {
tbc: i[1] === 3 && i[15].tbc === "" ? "0" : i[1] === 5 || i[1] === 6 || i[1] === 7 ? String(i[15].tbc.value) : String(i[15].tbc), tbc: i[1] === 3 && i[15].tbc === "" ? "0" : i[1] === 5 || i[1] === 6 || i[1] === 7 ? String(i[15].tbc.value) : String(i[15].tbc),
fcp: i[2] === 3 && i[15].fcp === "" ? "0" : i[2] === 5 || i[2] === 6 || i[2] === 7 ? String(i[15].fcp.value) : String(i[15].fcp), fcp: i[2] === 3 && i[15].fcp === "" ? "0" : i[2] === 5 || i[2] === 6 || i[2] === 7 ? String(i[15].fcp.value) : String(i[8]).toLocaleUpperCase() == "CORPORATE INCOME TAX" ? String(Number(i[15].fcp).toFixed(2)) : String(Number(i[15].fcp).toFixed(1)),
tbf: i[3] === 3 && i[15].tbf === "" ? "0" : i[3] === 5 || i[3] === 6 || i[3] === 7 ? String(i[15].tbf.value) : String(i[15].tbf) tbf: i[3] === 3 && i[15].tbf === "" ? "0" : i[3] === 5 || i[3] === 6 || i[3] === 7 ? String(i[15].tbf.value) : String(i[8]).toLocaleUpperCase() == "CORPORATE INCOME TAX" ? String(Number(i[15].tbf).toFixed(2)) : String(Number(i[15].tbf).toFixed(1))
}, },
august: { august: {
tbc: i[1] === 3 && i[16].tbc === "" ? "0" : i[1] === 5 || i[1] === 6 || i[1] === 7 ? String(i[16].tbc.value) : String(i[16].tbc), tbc: i[1] === 3 && i[16].tbc === "" ? "0" : i[1] === 5 || i[1] === 6 || i[1] === 7 ? String(i[16].tbc.value) : String(i[16].tbc),
fcp: i[2] === 3 && i[16].fcp === "" ? "0" : i[2] === 5 || i[2] === 6 || i[2] === 7 ? String(i[16].fcp.value) : String(i[16].fcp), fcp: i[2] === 3 && i[16].fcp === "" ? "0" : i[2] === 5 || i[2] === 6 || i[2] === 7 ? String(i[16].fcp.value) : String(i[8]).toLocaleUpperCase() == "CORPORATE INCOME TAX" ? String(Number(i[16].fcp).toFixed(2)) : String(Number(i[16].fcp).toFixed(1)),
tbf: i[3] === 3 && i[16].tbf === "" ? "0" : i[3] === 5 || i[3] === 6 || i[3] === 7 ? String(i[16].tbf.value) : String(i[16].tbf) tbf: i[3] === 3 && i[16].tbf === "" ? "0" : i[3] === 5 || i[3] === 6 || i[3] === 7 ? String(i[16].tbf.value) : String(i[8]).toLocaleUpperCase() == "CORPORATE INCOME TAX" ? String(Number(i[16].tbf).toFixed(2)) : String(Number(i[16].tbf).toFixed(1))
}, },
september: { september: {
tbc: i[1] === 3 && i[17].tbc === "" ? "0" : i[1] === 5 || i[1] === 6 || i[1] === 7 ? String(i[17].tbc.value) : String(i[17].tbc), tbc: i[1] === 3 && i[17].tbc === "" ? "0" : i[1] === 5 || i[1] === 6 || i[1] === 7 ? String(i[17].tbc.value) : String(i[17].tbc),
fcp: i[2] === 3 && i[17].fcp === "" ? "0" : i[2] === 5 || i[2] === 6 || i[2] === 7 ? String(i[17].fcp.value) : String(i[17].fcp), fcp: i[2] === 3 && i[17].fcp === "" ? "0" : i[2] === 5 || i[2] === 6 || i[2] === 7 ? String(i[17].fcp.value) : String(i[8]).toLocaleUpperCase() == "CORPORATE INCOME TAX" ? String(Number(i[17].fcp).toFixed(2)) : String(Number(i[17].fcp).toFixed(1)),
tbf: i[3] === 3 && i[17].tbf === "" ? "0" : i[3] === 5 || i[3] === 6 || i[3] === 7 ? String(i[17].tbf.value) : String(i[17].tbf) tbf: i[3] === 3 && i[17].tbf === "" ? "0" : i[3] === 5 || i[3] === 6 || i[3] === 7 ? String(i[17].tbf.value) : String(i[8]).toLocaleUpperCase() == "CORPORATE INCOME TAX" ? String(Number(i[17].tbf).toFixed(2)) : String(Number(i[17].tbf).toFixed(1))
}, },
october: { october: {
tbc: i[1] === 3 && i[18].tbc === "" ? "0" : i[1] === 5 || i[1] === 6 || i[1] === 7 ? String(i[18].tbc.value) : String(i[18].tbc), tbc: i[1] === 3 && i[18].tbc === "" ? "0" : i[1] === 5 || i[1] === 6 || i[1] === 7 ? String(i[18].tbc.value) : String(i[18].tbc),
fcp: i[2] === 3 && i[18].fcp === "" ? "0" : i[2] === 5 || i[2] === 6 || i[2] === 7 ? String(i[18].fcp.value) : String(i[18].fcp), fcp: i[2] === 3 && i[18].fcp === "" ? "0" : i[2] === 5 || i[2] === 6 || i[2] === 7 ? String(i[18].fcp.value) : String(i[8]).toLocaleUpperCase() == "CORPORATE INCOME TAX" ? String(Number(i[18].fcp).toFixed(2)) : String(Number(i[18].fcp).toFixed(1)),
tbf: i[3] === 3 && i[18].tbf === "" ? "0" : i[3] === 5 || i[3] === 6 || i[3] === 7 ? String(i[18].tbf.value) : String(i[18].tbf) tbf: i[3] === 3 && i[18].tbf === "" ? "0" : i[3] === 5 || i[3] === 6 || i[3] === 7 ? String(i[18].tbf.value) : String(i[8]).toLocaleUpperCase() == "CORPORATE INCOME TAX" ? String(Number(i[18].tbf).toFixed(2)) : String(Number(i[18].tbf).toFixed(1))
}, },
november: { november: {
tbc: i[1] === 3 && i[19].tbc === "" ? "0" : i[1] === 5 || i[1] === 6 || i[1] === 7 ? String(i[19].tbc.value) : String(i[19].tbc), tbc: i[1] === 3 && i[19].tbc === "" ? "0" : i[1] === 5 || i[1] === 6 || i[1] === 7 ? String(i[19].tbc.value) : String(i[19].tbc),
fcp: i[2] === 3 && i[19].fcp === "" ? "0" : i[2] === 5 || i[2] === 6 || i[2] === 7 ? String(i[19].fcp.value) : String(i[19].fcp), fcp: i[2] === 3 && i[19].fcp === "" ? "0" : i[2] === 5 || i[2] === 6 || i[2] === 7 ? String(i[19].fcp.value) : String(i[8]).toLocaleUpperCase() == "CORPORATE INCOME TAX" ? String(Number(i[19].fcp).toFixed(2)) : String(Number(i[19].fcp).toFixed(1)),
tbf: i[3] === 3 && i[19].tbf === "" ? "0" : i[3] === 5 || i[3] === 6 || i[3] === 7 ? String(i[19].tbf.value) : String(i[19].tbf) tbf: i[3] === 3 && i[19].tbf === "" ? "0" : i[3] === 5 || i[3] === 6 || i[3] === 7 ? String(i[19].tbf.value) : String(i[8]).toLocaleUpperCase() == "CORPORATE INCOME TAX" ? String(Number(i[19].tbf).toFixed(2)) : String(Number(i[19].tbf).toFixed(1))
}, },
december: { december: {
tbc: i[1] === 3 && i[20].tbc === "" ? "0" : i[1] === 5 || i[1] === 6 || i[1] === 7 ? String(i[20].tbc.value) : String(i[20].tbc), tbc: i[1] === 3 && i[20].tbc === "" ? "0" : i[1] === 5 || i[1] === 6 || i[1] === 7 ? String(i[20].tbc.value) : String(i[20].tbc),
fcp: i[2] === 3 && i[20].fcp === "" ? "0" : i[2] === 5 || i[2] === 6 || i[2] === 7 ? String(i[20].fcp.value) : String(i[20].fcp), fcp: i[2] === 3 && i[20].fcp === "" ? "0" : i[2] === 5 || i[2] === 6 || i[2] === 7 ? String(i[20].fcp.value) : String(i[8]).toLocaleUpperCase() == "CORPORATE INCOME TAX" ? String(Number(i[20].fcp).toFixed(2)) : String(Number(i[20].fcp).toFixed(1)),
tbf: i[3] === 3 && i[20].tbf === "" ? "0" : i[3] === 5 || i[3] === 6 || i[3] === 7 ? String(i[20].tbf.value) : String(i[20].tbf) tbf: i[3] === 3 && i[20].tbf === "" ? "0" : i[3] === 5 || i[3] === 6 || i[3] === 7 ? String(i[20].tbf.value) : String(i[8]).toLocaleUpperCase() == "CORPORATE INCOME TAX" ? String(Number(i[20].tbf).toFixed(2)) : String(Number(i[20].tbf).toFixed(1))
}, },
total_current_year: String(Number(i[21]).toFixed(1)), total_current_year: String(i[8]).toLocaleUpperCase() == "CORPORATE INCOME TAX" ? String(Number(i[21]).toFixed(2)) : String(Number(i[21]).toFixed(1)),
total_next_year: { total_next_year: {
tbc: String(Number(i[22].tbc).toFixed(1)), tbc: String(Number(i[22].tbc).toFixed(1)),
fcp: String(i[8]).toLocaleUpperCase() == "CORPORATE INCOME TAX" ? String(Number(i[22].fcp).toFixed(2)) : String(Number(i[22].fcp).toFixed(1)), fcp: String(i[8]).toLocaleUpperCase() == "CORPORATE INCOME TAX" ? String(Number(i[22].fcp).toFixed(2)) : String(Number(i[22].fcp).toFixed(1)),
...@@ -645,75 +646,75 @@ export default class TaxPlanning extends Component { ...@@ -645,75 +646,75 @@ export default class TaxPlanning extends Component {
data.push({ data.push({
item_report_id: i[4], item_report_id: i[4],
january: { january: {
tbc: i[1] === 3 && i[9].tbc === "" ? "0.0" : i[1] === 5 || i[1] === 6 || i[1] === 7 ? String(Number(i[9].tbc.value).toFixed(1)) : String(Number(i[9].tbc).toFixed(1)), tbc: i[1] === 3 && i[9].tbc === "" ? "0" : i[1] === 5 || i[1] === 6 || i[1] === 7 ? String(i[9].tbc.value) : String(i[9].tbc),
fcp: i[2] === 3 && i[9].fcp === "" ? "0.0" : i[2] === 5 || i[2] === 6 || i[2] === 7 ? String(Number(i[9].fcp.value).toFixed(1)) : String(Number(i[9].fcp).toFixed(1)), fcp: i[2] === 3 && i[9].fcp === "" ? "0" : i[2] === 5 || i[2] === 6 || i[2] === 7 ? String(i[9].fcp.value) : String(i[8]).toLocaleUpperCase() == "CORPORATE INCOME TAX" ? String(Number(i[9].fcp).toFixed(2)) : String(Number(i[9].fcp).toFixed(1)) ,
tbf: i[3] === 3 && i[9].tbf === "" ? "0.0" : i[3] === 5 || i[3] === 6 || i[3] === 7 ? String(Number(i[9].tbf.value).toFixed(1)) : String(Number(i[9].tbf).toFixed(1)) tbf: i[3] === 3 && i[9].tbf === "" ? "0" : i[3] === 5 || i[3] === 6 || i[3] === 7 ? String(i[9].tbf.value) : String(i[8]).toLocaleUpperCase() == "CORPORATE INCOME TAX" ? String(Number(i[9].tbf).toFixed(2)) : String(Number(i[9].tbf).toFixed(1))
}, },
february: { february: {
tbc: i[1] === 3 && i[10].tbc === "" ? "0.0" : i[1] === 5 || i[1] === 6 || i[1] === 7 ? String(Number(i[10].tbc.value).toFixed(1)) : String(Number(i[10].tbc).toFixed(1)), tbc: i[1] === 3 && i[10].tbc === "" ? "0" : i[1] === 5 || i[1] === 6 || i[1] === 7 ? String(i[10].tbc.value) : String(i[10].tbc),
fcp: i[2] === 3 && i[10].fcp === "" ? "0.0" : i[2] === 5 || i[2] === 6 || i[2] === 7 ? String(Number(i[10].fcp.value).toFixed(1)) : String(Number(i[10].fcp).toFixed(1)), fcp: i[2] === 3 && i[10].fcp === "" ? "0" : i[2] === 5 || i[2] === 6 || i[2] === 7 ? String(i[10].fcp.value) : String(i[8]).toLocaleUpperCase() == "CORPORATE INCOME TAX" ? String(Number(i[10].fcp).toFixed(2)) : String(Number(i[10].fcp).toFixed(1)),
tbf: i[3] === 3 && i[10].tbf === "" ? "0.0" : i[3] === 5 || i[3] === 6 || i[3] === 7 ? String(Number(i[10].tbf.value).toFixed(1)) : String(Number(i[10].tbf).toFixed(1)) tbf: i[3] === 3 && i[10].tbf === "" ? "0" : i[3] === 5 || i[3] === 6 || i[3] === 7 ? String(i[10].tbf.value) : String(i[8]).toLocaleUpperCase() == "CORPORATE INCOME TAX" ? String(Number(i[10].tbf).toFixed(2)) : String(Number(i[10].tbf).toFixed(1))
}, },
march: { march: {
tbc: i[1] === 3 && i[11].tbc === "" ? "0.0" : i[1] === 5 || i[1] === 6 || i[1] === 7 ? String(Number(i[11].tbc.value).toFixed(1)) : String(Number(i[11].tbc).toFixed(1)), tbc: i[1] === 3 && i[11].tbc === "" ? "0" : i[1] === 5 || i[1] === 6 || i[1] === 7 ? String(i[11].tbc.value) : String(i[11].tbc),
fcp: i[2] === 3 && i[11].fcp === "" ? "0.0" : i[2] === 5 || i[2] === 6 || i[2] === 7 ? String(Number(i[11].fcp.value).toFixed(1)) : String(Number(i[11].fcp).toFixed(1)), fcp: i[2] === 3 && i[11].fcp === "" ? "0" : i[2] === 5 || i[2] === 6 || i[2] === 7 ? String(i[11].fcp.value) : String(i[8]).toLocaleUpperCase() == "CORPORATE INCOME TAX" ? String(Number(i[11].fcp).toFixed(2)) : String(Number(i[11].fcp).toFixed(1)),
tbf: i[3] === 3 && i[11].tbf === "" ? "0.0" : i[3] === 5 || i[3] === 6 || i[3] === 7 ? String(Number(i[11].tbf.value).toFixed(1)) : String(Number(i[11].tbf).toFixed(1)) tbf: i[3] === 3 && i[11].tbf === "" ? "0" : i[3] === 5 || i[3] === 6 || i[3] === 7 ? String(i[11].tbf.value) : String(i[8]).toLocaleUpperCase() == "CORPORATE INCOME TAX" ? String(Number(i[11].tbf).toFixed(2)) : String(Number(i[11].tbf).toFixed(1))
}, },
april: { april: {
tbc: i[1] === 3 && i[12].tbc === "" ? "0.0" : i[1] === 5 || i[1] === 6 || i[1] === 7 ? String(Number(i[12].tbc.value).toFixed(1)) : String(Number(i[12].tbc).toFixed(1)), tbc: i[1] === 3 && i[12].tbc === "" ? "0" : i[1] === 5 || i[1] === 6 || i[1] === 7 ? String(i[12].tbc.value) : String(i[12].tbc),
fcp: i[2] === 3 && i[12].fcp === "" ? "0.0" : i[2] === 5 || i[2] === 6 || i[2] === 7 ? String(Number(i[12].fcp.value).toFixed(1)) : String(Number(i[12].fcp).toFixed(1)), fcp: i[2] === 3 && i[12].fcp === "" ? "0" : i[2] === 5 || i[2] === 6 || i[2] === 7 ? String(i[12].fcp.value) : String(i[8]).toLocaleUpperCase() == "CORPORATE INCOME TAX" ? String(Number(i[12].fcp).toFixed(2)) : String(Number(i[12].fcp).toFixed(1)),
tbf: i[3] === 3 && i[12].tbf === "" ? "0.0" : i[3] === 5 || i[3] === 6 || i[3] === 7 ? String(Number(i[12].tbf.value).toFixed(1)) : String(Number(i[12].tbf).toFixed(1)) tbf: i[3] === 3 && i[12].tbf === "" ? "0" : i[3] === 5 || i[3] === 6 || i[3] === 7 ? String(i[12].tbf.value) : String(i[8]).toLocaleUpperCase() == "CORPORATE INCOME TAX" ? String(Number(i[12].tbf).toFixed(2)) : String(Number(i[12].tbf).toFixed(1))
}, },
may: { may: {
tbc: i[1] === 3 && i[13].tbc === "" ? "0.0" : i[1] === 5 || i[1] === 6 || i[1] === 7 ? String(Number(i[13].tbc.value).toFixed(1)) : String(Number(i[13].tbc).toFixed(1)), tbc: i[1] === 3 && i[13].tbc === "" ? "0" : i[1] === 5 || i[1] === 6 || i[1] === 7 ? String(i[13].tbc.value) : String(i[13].tbc),
fcp: i[2] === 3 && i[13].fcp === "" ? "0.0" : i[2] === 5 || i[2] === 6 || i[2] === 7 ? String(Number(i[13].fcp.value).toFixed(1)) : String(Number(i[13].fcp).toFixed(1)), fcp: i[2] === 3 && i[13].fcp === "" ? "0" : i[2] === 5 || i[2] === 6 || i[2] === 7 ? String(i[13].fcp.value) : String(i[8]).toLocaleUpperCase() == "CORPORATE INCOME TAX" ? String(Number(i[13].fcp).toFixed(2)) : String(Number(i[13].fcp).toFixed(1)),
tbf: i[3] === 3 && i[13].tbf === "" ? "0.0" : i[3] === 5 || i[3] === 6 || i[3] === 7 ? String(Number(i[13].tbf.value).toFixed(1)) : String(Number(i[13].tbf).toFixed(1)) tbf: i[3] === 3 && i[13].tbf === "" ? "0" : i[3] === 5 || i[3] === 6 || i[3] === 7 ? String(i[13].tbf.value) : String(i[8]).toLocaleUpperCase() == "CORPORATE INCOME TAX" ? String(Number(i[13].tbf).toFixed(2)) : String(Number(i[13].tbf).toFixed(1))
}, },
june: { june: {
tbc: i[1] === 3 && i[14].tbc === "" ? "0.0" : i[1] === 5 || i[1] === 6 || i[1] === 7 ? String(Number(i[14].tbc.value).toFixed(1)) : String(Number(i[14].tbc).toFixed(1)), tbc: i[1] === 3 && i[14].tbc === "" ? "0" : i[1] === 5 || i[1] === 6 || i[1] === 7 ? String(i[14].tbc.value) : String(i[14].tbc),
fcp: i[2] === 3 && i[14].fcp === "" ? "0.0" : i[2] === 5 || i[2] === 6 || i[2] === 7 ? String(Number(i[14].fcp.value).toFixed(1)) : String(Number(i[14].fcp).toFixed(1)), fcp: i[2] === 3 && i[14].fcp === "" ? "0" : i[2] === 5 || i[2] === 6 || i[2] === 7 ? String(i[14].fcp.value) : String(i[8]).toLocaleUpperCase() == "CORPORATE INCOME TAX" ? String(Number(i[14].fcp).toFixed(2)) : String(Number(i[14].fcp).toFixed(1)),
tbf: i[3] === 3 && i[14].tbc === "" ? "0.0" : i[3] === 5 || i[3] === 6 || i[3] === 7 ? String(Number(i[14].tbf.value).toFixed(1)) : String(Number(i[14].tbf).toFixed(1)) tbf: i[3] === 3 && i[14].tbc === "" ? "0" : i[3] === 5 || i[3] === 6 || i[3] === 7 ? String(i[14].tbf.value) : String(i[8]).toLocaleUpperCase() == "CORPORATE INCOME TAX" ? String(Number(i[14].tbf).toFixed(2)) : String(Number(i[14].tbf).toFixed(1))
}, },
july: { july: {
tbc: i[1] === 3 && i[15].tbc === "" ? "0.0" : i[1] === 5 || i[1] === 6 || i[1] === 7 ? String(Number(i[15].tbc.value).toFixed(1)) : String(Number(i[15].tbc).toFixed(1)), tbc: i[1] === 3 && i[15].tbc === "" ? "0" : i[1] === 5 || i[1] === 6 || i[1] === 7 ? String(i[15].tbc.value) : String(i[15].tbc),
fcp: i[2] === 3 && i[15].fcp === "" ? "0.0" : i[2] === 5 || i[2] === 6 || i[2] === 7 ? String(Number(i[15].fcp.value).toFixed(1)) : String(Number(i[15].fcp).toFixed(1)), fcp: i[2] === 3 && i[15].fcp === "" ? "0" : i[2] === 5 || i[2] === 6 || i[2] === 7 ? String(i[15].fcp.value) : String(i[8]).toLocaleUpperCase() == "CORPORATE INCOME TAX" ? String(Number(i[15].fcp).toFixed(2)) : String(Number(i[15].fcp).toFixed(1)),
tbf: i[3] === 3 && i[15].tbf === "" ? "0.0" : i[3] === 5 || i[3] === 6 || i[3] === 7 ? String(Number(i[15].tbf.value).toFixed(1)) : String(Number(i[15].tbf).toFixed(1)) tbf: i[3] === 3 && i[15].tbf === "" ? "0" : i[3] === 5 || i[3] === 6 || i[3] === 7 ? String(i[15].tbf.value) : String(i[8]).toLocaleUpperCase() == "CORPORATE INCOME TAX" ? String(Number(i[15].tbf).toFixed(2)) : String(Number(i[15].tbf).toFixed(1))
}, },
august: { august: {
tbc: i[1] === 3 && i[16].tbc === "" ? "0.0" : i[1] === 5 || i[1] === 6 || i[1] === 7 ? String(Number(i[16].tbc.value).toFixed(1)) : String(Number(i[16].tbc).toFixed(1)), tbc: i[1] === 3 && i[16].tbc === "" ? "0" : i[1] === 5 || i[1] === 6 || i[1] === 7 ? String(i[16].tbc.value) : String(i[16].tbc),
fcp: i[2] === 3 && i[16].fcp === "" ? "0.0" : i[2] === 5 || i[2] === 6 || i[2] === 7 ? String(Number(i[16].fcp.value).toFixed(1)) : String(Number(i[16].fcp).toFixed(1)), fcp: i[2] === 3 && i[16].fcp === "" ? "0" : i[2] === 5 || i[2] === 6 || i[2] === 7 ? String(i[16].fcp.value) : String(i[8]).toLocaleUpperCase() == "CORPORATE INCOME TAX" ? String(Number(i[16].fcp).toFixed(2)) : String(Number(i[16].fcp).toFixed(1)),
tbf: i[3] === 3 && i[16].tbf === "" ? "0.0" : i[3] === 5 || i[3] === 6 || i[3] === 7 ? String(Number(i[16].tbf.value).toFixed(1)) : String(Number(i[16].tbf).toFixed(1)) tbf: i[3] === 3 && i[16].tbf === "" ? "0" : i[3] === 5 || i[3] === 6 || i[3] === 7 ? String(i[16].tbf.value) : String(i[8]).toLocaleUpperCase() == "CORPORATE INCOME TAX" ? String(Number(i[16].tbf).toFixed(2)) : String(Number(i[16].tbf).toFixed(1))
}, },
september: { september: {
tbc: i[1] === 3 && i[17].tbc === "" ? "0.0" : i[1] === 5 || i[1] === 6 || i[1] === 7 ? String(Number(i[17].tbc.value).toFixed(1)) : String(Number(i[17].tbc).toFixed(1)), tbc: i[1] === 3 && i[17].tbc === "" ? "0" : i[1] === 5 || i[1] === 6 || i[1] === 7 ? String(i[17].tbc.value) : String(i[17].tbc),
fcp: i[2] === 3 && i[17].fcp === "" ? "0.0" : i[2] === 5 || i[2] === 6 || i[2] === 7 ? String(Number(i[17].fcp.value).toFixed(1)) : String(Number(i[17].fcp).toFixed(1)), fcp: i[2] === 3 && i[17].fcp === "" ? "0" : i[2] === 5 || i[2] === 6 || i[2] === 7 ? String(i[17].fcp.value) : String(i[8]).toLocaleUpperCase() == "CORPORATE INCOME TAX" ? String(Number(i[17].fcp).toFixed(2)) : String(Number(i[17].fcp).toFixed(1)),
tbf: i[3] === 3 && i[17].tbf === "" ? "0.0" : i[3] === 5 || i[3] === 6 || i[3] === 7 ? String(Number(i[17].tbf.value).toFixed(1)) : String(Number(i[17].tbf).toFixed(1)) tbf: i[3] === 3 && i[17].tbf === "" ? "0" : i[3] === 5 || i[3] === 6 || i[3] === 7 ? String(i[17].tbf.value) : String(i[8]).toLocaleUpperCase() == "CORPORATE INCOME TAX" ? String(Number(i[17].tbf).toFixed(2)) : String(Number(i[17].tbf).toFixed(1))
}, },
october: { october: {
tbc: i[1] === 3 && i[18].tbc === "" ? "0.0" : i[1] === 5 || i[1] === 6 || i[1] === 7 ? String(Number(i[18].tbc.value).toFixed(1)) : String(Number(i[18].tbc).toFixed(1)), tbc: i[1] === 3 && i[18].tbc === "" ? "0" : i[1] === 5 || i[1] === 6 || i[1] === 7 ? String(i[18].tbc.value) : String(i[18].tbc),
fcp: i[2] === 3 && i[18].fcp === "" ? "0.0" : i[2] === 5 || i[2] === 6 || i[2] === 7 ? String(Number(i[18].fcp.value).toFixed(1)) : String(Number(i[18].fcp).toFixed(1)), fcp: i[2] === 3 && i[18].fcp === "" ? "0" : i[2] === 5 || i[2] === 6 || i[2] === 7 ? String(i[18].fcp.value) : String(i[8]).toLocaleUpperCase() == "CORPORATE INCOME TAX" ? String(Number(i[18].fcp).toFixed(2)) : String(Number(i[18].fcp).toFixed(1)),
tbf: i[3] === 3 && i[18].tbf === "" ? "0.0" : i[3] === 5 || i[3] === 6 || i[3] === 7 ? String(Number(i[18].tbf.value).toFixed(1)) : String(Number(i[18].tbf).toFixed(1)) tbf: i[3] === 3 && i[18].tbf === "" ? "0" : i[3] === 5 || i[3] === 6 || i[3] === 7 ? String(i[18].tbf.value) : String(i[8]).toLocaleUpperCase() == "CORPORATE INCOME TAX" ? String(Number(i[18].tbf).toFixed(2)) : String(Number(i[18].tbf).toFixed(1))
}, },
november: { november: {
tbc: i[1] === 3 && i[19].tbc === "" ? "0.0" : i[1] === 5 || i[1] === 6 || i[1] === 7 ? String(Number(i[19].tbc.value).toFixed(1)) : String(Number(i[19].tbc).toFixed(1)), tbc: i[1] === 3 && i[19].tbc === "" ? "0" : i[1] === 5 || i[1] === 6 || i[1] === 7 ? String(i[19].tbc.value) : String(i[19].tbc),
fcp: i[2] === 3 && i[19].fcp === "" ? "0.0" : i[2] === 5 || i[2] === 6 || i[2] === 7 ? String(Number(i[19].fcp.value).toFixed(1)) : String(Number(i[19].fcp).toFixed(1)), fcp: i[2] === 3 && i[19].fcp === "" ? "0" : i[2] === 5 || i[2] === 6 || i[2] === 7 ? String(i[19].fcp.value) : String(i[8]).toLocaleUpperCase() == "CORPORATE INCOME TAX" ? String(Number(i[19].fcp).toFixed(2)) : String(Number(i[19].fcp).toFixed(1)),
tbf: i[3] === 3 && i[19].tbf === "" ? "0.0" : i[3] === 5 || i[3] === 6 || i[3] === 7 ? String(Number(i[19].tbf.value).toFixed(1)) : String(Number(i[19].tbf).toFixed(1)) tbf: i[3] === 3 && i[19].tbf === "" ? "0" : i[3] === 5 || i[3] === 6 || i[3] === 7 ? String(i[19].tbf.value) : String(i[8]).toLocaleUpperCase() == "CORPORATE INCOME TAX" ? String(Number(i[19].tbf).toFixed(2)) : String(Number(i[19].tbf).toFixed(1))
}, },
december: { december: {
tbc: i[1] === 3 && i[20].tbc === "" ? "0.0" : i[1] === 5 || i[1] === 6 || i[1] === 7 ? String(Number(i[20].tbc.value).toFixed(1)) : String(Number(i[20].tbc).toFixed(1)), tbc: i[1] === 3 && i[20].tbc === "" ? "0" : i[1] === 5 || i[1] === 6 || i[1] === 7 ? String(i[20].tbc.value) : String(i[20].tbc),
fcp: i[2] === 3 && i[20].fcp === "" ? "0.0" : i[2] === 5 || i[2] === 6 || i[2] === 7 ? String(Number(i[20].fcp.value).toFixed(1)) : String(Number(i[20].fcp).toFixed(1)), fcp: i[2] === 3 && i[20].fcp === "" ? "0" : i[2] === 5 || i[2] === 6 || i[2] === 7 ? String(i[20].fcp.value) : String(i[8]).toLocaleUpperCase() == "CORPORATE INCOME TAX" ? String(Number(i[20].fcp).toFixed(2)) : String(Number(i[20].fcp).toFixed(1)),
tbf: i[3] === 3 && i[20].tbf === "" ? "0.0" : i[3] === 5 || i[3] === 6 || i[3] === 7 ? String(Number(i[20].tbf.value).toFixed(1)) : String(Number(i[20].tbf).toFixed(1)) tbf: i[3] === 3 && i[20].tbf === "" ? "0" : i[3] === 5 || i[3] === 6 || i[3] === 7 ? String(i[20].tbf.value) : String(i[8]).toLocaleUpperCase() == "CORPORATE INCOME TAX" ? String(Number(i[20].tbf).toFixed(2)) : String(Number(i[20].tbf).toFixed(1))
}, },
total_current_year: i[2] === 3 && i[21] === "" ? "0.0" : String(Number(i[21]).toFixed(1)), total_current_year: String(i[8]).toLocaleUpperCase() == "CORPORATE INCOME TAX" ? String(Number(i[21]).toFixed(2)) : String(Number(i[21]).toFixed(1)),
total_next_year: { total_next_year: {
tbc: i[1] === 3 && i[22].tbc === "" ? "0.0" : String(Number(i[22].tbc).toFixed(1)), tbc: String(Number(i[22].tbc).toFixed(1)),
fcp: i[2] === 3 && i[22].fcp === "" ? "0.0" : String(Number(i[22].fcp).toFixed(1)), fcp: String(i[8]).toLocaleUpperCase() == "CORPORATE INCOME TAX" ? String(Number(i[22].fcp).toFixed(2)) : String(Number(i[22].fcp).toFixed(1)),
tbf: i[3] === 3 && i[22].tbf === "" ? "0.0" : String(Number(i[22].tbf).toFixed(1)) tbf: String(i[8]).toLocaleUpperCase() == "CORPORATE INCOME TAX" ? String(Number(i[22].tbf).toFixed(2)) : String(Number(i[22].tbf).toFixed(1))
}, },
total_more_year: { total_more_year: {
tbc: i[1] === 3 && i[23].tbc === "" ? "0.0" : String(Number(i[23].tbc).toFixed(1)), tbc: String(Number(i[23].tbc).toFixed(1)),
fcp: i[2] === 3 && i[23].fcp === "" ? "0.0" : String(Number(i[23].fcp).toFixed(1)), fcp: String(i[8]).toLocaleUpperCase() == "CORPORATE INCOME TAX" ? String(Number(i[23].fcp).toFixed(2)) : String(Number(i[23].fcp).toFixed(1)),
tbf: i[3] === 3 && i[23].tbf === "" ? "0.0" : String(Number(i[23].tbf).toFixed(1)) tbf: String(i[8]).toLocaleUpperCase() == "CORPORATE INCOME TAX" ? String(Number(i[23].tbf).toFixed(2)) : String(Number(i[23].tbf).toFixed(1))
} }
}) })
}) })
...@@ -1282,15 +1283,8 @@ export default class TaxPlanning extends Component { ...@@ -1282,15 +1283,8 @@ export default class TaxPlanning extends Component {
}) })
} }
if (String(tableMeta.rowData[8]).toLocaleUpperCase() == "CORPORATE INCOME TAX") { dataTable2[tableMeta.rowIndex][21] = Number(total).toFixed(1)
dataTable2[tableMeta.rowIndex][21] = Number(total).toFixed(2) return total
console.log(dataTable2[tableMeta.rowIndex][21])
console.log(total)
return total
} else {
dataTable2[tableMeta.rowIndex][21] = Number(total).toFixed(1)
return total
}
} }
const handleValue = (data) => { const handleValue = (data) => {
let total = 0 let total = 0
...@@ -7526,7 +7520,7 @@ export default class TaxPlanning extends Component { ...@@ -7526,7 +7520,7 @@ export default class TaxPlanning extends Component {
/> />
</div> </div>
: :
tableMeta.rowData[24] === 83 ? tableMeta.rowData[8] === "Taxable Income" ?
<div style={{ flex: 1 }}> <div style={{ flex: 1 }}>
<FormControlLabel <FormControlLabel
style={{ margin: 0 }} style={{ margin: 0 }}
...@@ -7544,7 +7538,7 @@ export default class TaxPlanning extends Component { ...@@ -7544,7 +7538,7 @@ export default class TaxPlanning extends Component {
/> />
</div> </div>
: :
tableMeta.rowData[24] === 87 ? tableMeta.rowData[8] === "Corporate Income Tax" ?
<div style={{ flex: 1 }}> <div style={{ flex: 1 }}>
<FormControlLabel <FormControlLabel
style={{ margin: 0 }} style={{ margin: 0 }}
...@@ -7562,7 +7556,7 @@ export default class TaxPlanning extends Component { ...@@ -7562,7 +7556,7 @@ export default class TaxPlanning extends Component {
/> />
</div> </div>
: :
tableMeta.rowData[24] === 89 ? tableMeta.rowData[8] === "Corporate Income Tax after adjustment" ?
<div style={{ flex: 1 }}> <div style={{ flex: 1 }}>
<FormControlLabel <FormControlLabel
style={{ margin: 0 }} style={{ margin: 0 }}
...@@ -7580,7 +7574,7 @@ export default class TaxPlanning extends Component { ...@@ -7580,7 +7574,7 @@ export default class TaxPlanning extends Component {
/> />
</div> </div>
: :
tableMeta.rowData[24] === 96 ? tableMeta.rowData[8] === "Under payment /(Over Payment ) Income Tax Art. 29" ?
<div style={{ flex: 1 }}> <div style={{ flex: 1 }}>
<FormControlLabel <FormControlLabel
style={{ margin: 0 }} style={{ margin: 0 }}
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment