Commit 70e72354 authored by r.kurnia's avatar r.kurnia

tp

parent 77f5899b
......@@ -217,7 +217,7 @@ export default class TaxPlanning extends Component {
}
}
})
// console.log(dataTable)
console.log(dataTable)
this.setState({ dataTable, loading: false, buttonError: true, editable: true })
} else {
this.setState({ loading: false, alert: true, messageAlert: response.data.message, tipeAlert: 'warning' }, () => {
......@@ -336,14 +336,12 @@ export default class TaxPlanning extends Component {
total_next_year: {
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(Number(i[22].fcp).toFixed(1)),
tbf: 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: {
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(Number(i[23].fcp).toFixed(1)),
tbf: 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)),
}
})
})
......@@ -381,73 +379,73 @@ export default class TaxPlanning extends Component {
january: {
tbc: i[2] === undefined ? "0" : reg.test(String(i[2])) === false ? "0" : String(i[2]).trim(),
fcp: i[3] === undefined ? "0" : reg.test(String(i[3])) === false ? "0" : String(i[1]).toLocaleUpperCase() == "CORPORATE INCOME TAX" ? String(Number(String(i[3]).trim()).toFixed(2)) : String(Number(String(i[3]).trim()).toFixed(1)),
tbf: i[4] === undefined ? "0" : reg.test(String(i[4])) === false ? "0" : String(i[4]).trim(),
tbf: i[4] === undefined ? "0" : reg.test(String(i[4])) === false ? "0" : String(i[1]).toLocaleUpperCase() == "CORPORATE INCOME TAX" ? String(Number(String(i[4]).trim()).toFixed(2)) : String(Number(String(i[4]).trim()).toFixed(1)),
},
february: {
tbc: i[5] === undefined ? "0" : reg.test(String(i[5])) === false ? "0" : String(i[5]).trim(),
fcp: i[6] === undefined ? "0" : reg.test(String(i[6])) === false ? "0" : String(i[1]).toLocaleUpperCase() == "CORPORATE INCOME TAX" ? String(Number(String(i[6]).trim()).toFixed(2)) : String(Number(String(i[6]).trim()).toFixed(1)),
tbf: i[7] === undefined ? "0" : reg.test(String(i[7])) === false ? "0" : String(i[7]).trim(),
tbf: i[7] === undefined ? "0" : reg.test(String(i[7])) === false ? "0" : String(i[1]).toLocaleUpperCase() == "CORPORATE INCOME TAX" ? String(Number(String(i[7]).trim()).toFixed(2)) : String(Number(String(i[7]).trim()).toFixed(1)),
},
march: {
tbc: i[8] === undefined ? "0" : reg.test(String(i[8])) === false ? "0" : String(i[8]).trim(),
fcp: i[9] === undefined ? "0" : reg.test(String(i[9])) === false ? "0" : String(i[1]).toLocaleUpperCase() == "CORPORATE INCOME TAX" ? String(Number(String(i[9]).trim()).toFixed(2)) : String(Number(String(i[9]).trim()).toFixed(1)),
tbf: i[10] === undefined ? "0" : reg.test(String(i[10])) === false ? "0" : String(i[10]).trim(),
tbf: i[10] === undefined ? "0" : reg.test(String(i[10])) === false ? "0" : String(i[1]).toLocaleUpperCase() == "CORPORATE INCOME TAX" ? String(Number(String(i[10]).trim()).toFixed(2)) : String(Number(String(i[10]).trim()).toFixed(1)),
},
april: {
tbc: i[11] === undefined ? "0" : reg.test(String(i[11])) === false ? "0" : String(i[11]).trim(),
fcp: i[12] === undefined ? "0" : reg.test(String(i[12])) === false ? "0" : String(i[1]).toLocaleUpperCase() == "CORPORATE INCOME TAX" ? String(Number(String(i[12]).trim()).toFixed(2)) : String(Number(String(i[12]).trim()).toFixed(1)),
tbf: i[13] === undefined ? "0" : reg.test(String(i[13])) === false ? "0" : String(i[13]).trim(),
tbf: i[13] === undefined ? "0" : reg.test(String(i[13])) === false ? "0" : String(i[1]).toLocaleUpperCase() == "CORPORATE INCOME TAX" ? String(Number(String(i[13]).trim()).toFixed(2)) : String(Number(String(i[13]).trim()).toFixed(1)),
},
may: {
tbc: i[14] === undefined ? "0" : reg.test(String(i[14])) === false ? "0" : String(i[14]).trim(),
fcp: i[15] === undefined ? "0" : reg.test(String(i[15])) === false ? "0" : String(i[1]).toLocaleUpperCase() == "CORPORATE INCOME TAX" ? String(Number(String(i[15]).trim()).toFixed(2)) : String(Number(String(i[15]).trim()).toFixed(1)),
tbf: i[16] === undefined ? "0" : reg.test(String(i[16])) === false ? "0" : String(i[16]).trim(),
tbf: i[16] === undefined ? "0" : reg.test(String(i[16])) === false ? "0" : String(i[1]).toLocaleUpperCase() == "CORPORATE INCOME TAX" ? String(Number(String(i[16]).trim()).toFixed(2)) : String(Number(String(i[16]).trim()).toFixed(1)),
},
june: {
tbc: i[17] === undefined ? "0" : reg.test(String(i[17])) === false ? "0" : String(i[17]).trim(),
fcp: i[18] === undefined ? "0" : reg.test(String(i[18])) === false ? "0" : String(i[1]).toLocaleUpperCase() == "CORPORATE INCOME TAX" ? String(Number(String(i[18]).trim()).toFixed(2)) : String(Number(String(i[18]).trim()).toFixed(1)),
tbf: i[19] === undefined ? "0" : reg.test(String(i[19])) === false ? "0" : String(i[19]).trim(),
tbf: i[19] === undefined ? "0" : reg.test(String(i[19])) === false ? "0" : String(i[1]).toLocaleUpperCase() == "CORPORATE INCOME TAX" ? String(Number(String(i[19]).trim()).toFixed(2)) : String(Number(String(i[19]).trim()).toFixed(1)),
},
july: {
tbc: i[20] === undefined ? "0" : reg.test(String(i[20])) === false ? "0" : String(i[20]).trim(),
fcp: i[21] === undefined ? "0" : reg.test(String(i[21])) === false ? "0" : String(i[1]).toLocaleUpperCase() == "CORPORATE INCOME TAX" ? String(Number(String(i[21]).trim()).toFixed(2)) : String(Number(String(i[21]).trim()).toFixed(1)),
tbf: i[22] === undefined ? "0" : reg.test(String(i[22])) === false ? "0" : String(i[22]).trim(),
tbf: i[22] === undefined ? "0" : reg.test(String(i[22])) === false ? "0" : String(i[1]).toLocaleUpperCase() == "CORPORATE INCOME TAX" ? String(Number(String(i[22]).trim()).toFixed(2)) : String(Number(String(i[22]).trim()).toFixed(1)),
},
august: {
tbc: i[23] === undefined ? "0" : reg.test(String(i[23])) === false ? "0" : String(i[23]).trim(),
fcp: i[24] === undefined ? "0" : reg.test(String(i[24])) === false ? "0" : String(i[1]).toLocaleUpperCase() == "CORPORATE INCOME TAX" ? String(Number(String(i[24]).trim()).toFixed(2)) : String(Number(String(i[24]).trim()).toFixed(1)),
tbf: i[25] === undefined ? "0" : reg.test(String(i[25])) === false ? "0" : String(i[25]).trim(),
tbf: i[25] === undefined ? "0" : reg.test(String(i[25])) === false ? "0" : String(i[1]).toLocaleUpperCase() == "CORPORATE INCOME TAX" ? String(Number(String(i[25]).trim()).toFixed(2)) : String(Number(String(i[25]).trim()).toFixed(1)),
},
september: {
tbc: i[26] === undefined ? "0" : reg.test(String(i[26])) === false ? "0" : String(i[26]).trim(),
fcp: i[27] === undefined ? "0" : reg.test(String(i[27])) === false ? "0" : String(i[1]).toLocaleUpperCase() == "CORPORATE INCOME TAX" ? String(Number(String(i[27]).trim()).toFixed(2)) : String(Number(String(i[27]).trim()).toFixed(1)),
tbf: i[28] === undefined ? "0" : reg.test(String(i[28])) === false ? "0" : String(i[28]).trim(),
tbf: i[28] === undefined ? "0" : reg.test(String(i[28])) === false ? "0" : String(i[1]).toLocaleUpperCase() == "CORPORATE INCOME TAX" ? String(Number(String(i[28]).trim()).toFixed(2)) : String(Number(String(i[28]).trim()).toFixed(1)),
},
october: {
tbc: i[29] === undefined ? "0" : reg.test(String(i[29])) === false ? "0" : String(i[29]).trim(),
fcp: i[30] === undefined ? "0" : reg.test(String(i[30])) === false ? "0" : String(i[1]).toLocaleUpperCase() == "CORPORATE INCOME TAX" ? String(Number(String(i[30]).trim()).toFixed(2)) : String(Number(String(i[30]).trim()).toFixed(1)),
tbf: i[31] === undefined ? "0" : reg.test(String(i[31])) === false ? "0" : String(i[31]).trim(),
tbf: i[31] === undefined ? "0" : reg.test(String(i[31])) === false ? "0" : String(i[1]).toLocaleUpperCase() == "CORPORATE INCOME TAX" ? String(Number(String(i[31]).trim()).toFixed(2)) : String(Number(String(i[31]).trim()).toFixed(1)),
},
november: {
tbc: i[32] === undefined ? "0" : reg.test(String(i[32])) === false ? "0" : String(i[32]).trim(),
fcp: i[33] === undefined ? "0" : reg.test(String(i[33])) === false ? "0" : String(i[1]).toLocaleUpperCase() == "CORPORATE INCOME TAX" ? String(Number(String(i[33]).trim()).toFixed(2)) : String(Number(String(i[33]).trim()).toFixed(1)),
tbf: i[34] === undefined ? "0" : reg.test(String(i[34])) === false ? "0" : String(i[34]).trim(),
tbf: i[34] === undefined ? "0" : reg.test(String(i[34])) === false ? "0" : String(i[1]).toLocaleUpperCase() == "CORPORATE INCOME TAX" ? String(Number(String(i[34]).trim()).toFixed(2)) : String(Number(String(i[34]).trim()).toFixed(1)),
},
december: {
tbc: i[35] === undefined ? "0" : reg.test(String(i[35])) === false ? "0" : String(i[35]).trim(),
fcp: i[36] === undefined ? "0" : reg.test(String(i[36])) === false ? "0" : String(i[1]).toLocaleUpperCase() == "CORPORATE INCOME TAX" ? String(Number(String(i[36]).trim()).toFixed(2)) : String(Number(String(i[36]).trim()).toFixed(1)),
tbf: i[37] === undefined ? "0" : reg.test(String(i[37])) === false ? "0" : String(i[37]).trim(),
tbf: i[37] === undefined ? "0" : reg.test(String(i[37])) === false ? "0" : String(i[1]).toLocaleUpperCase() == "CORPORATE INCOME TAX" ? String(Number(String(i[37]).trim()).toFixed(2)) : String(Number(String(i[37]).trim()).toFixed(1)),
},
total_current_year: i[38] === undefined ? "" : String(i[38]).trim(),
total_next_year: {
tbc: i[39] === undefined ? "0" : reg.test(String(i[39])) === false ? "0" : String(i[39]).trim(),
fcp: i[40] === undefined ? "0" : reg.test(String(i[40])) === false ? "0" : String(i[1]).toLocaleUpperCase() == "CORPORATE INCOME TAX" ? String(Number(String(i[40]).trim()).toFixed(2)) : String(Number(String(i[40]).trim()).toFixed(1)),
tbf: i[41] === undefined ? "0" : reg.test(String(i[41])) === false ? "0" : String(i[41]).trim(),
tbf: i[41] === undefined ? "0" : reg.test(String(i[41])) === false ? "0" : String(i[1]).toLocaleUpperCase() == "CORPORATE INCOME TAX" ? String(Number(String(i[41]).trim()).toFixed(2)) : String(Number(String(i[41]).trim()).toFixed(1)),
},
total_more_year: {
tbc: i[42] === undefined ? "0" : reg.test(String(i[42])) === false ? "0" : String(i[42]).trim(),
fcp: i[43] === undefined ? "0" : reg.test(String(i[43])) === false ? "0" : String(i[1]).toLocaleUpperCase() == "CORPORATE INCOME TAX" ? String(Number(String(i[43]).trim()).toFixed(2)) : String(Number(String(i[43]).trim()).toFixed(1)),
tbf: i[44] === undefined ? "0" : reg.test(String(i[44])) === false ? "0" : String(i[44]).trim(),
tbf: i[44] === undefined ? "0" : reg.test(String(i[44])) === false ? "0" : String(i[1]).toLocaleUpperCase() == "CORPORATE INCOME TAX" ? String(Number(String(i[44]).trim()).toFixed(2)) : String(Number(String(i[44]).trim()).toFixed(1)),
}
})
}
......@@ -598,12 +596,12 @@ export default class TaxPlanning extends Component {
total_next_year: {
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)),
tbf: 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: {
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)),
tbf: 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))
}
})
})
......@@ -946,10 +944,15 @@ export default class TaxPlanning extends Component {
}
// console.log(tableMeta.rowData[8], baru, anjay, total);
total = R.equals(total, NaN) ? "0.0" : Number(total).toFixed(1)
dataTable2[tableMeta.rowIndex][tableMeta.columnIndex] = total
return total
if (String(tableMeta.rowData[8]).toLocaleUpperCase() == "CORPORATE INCOME TAX") {
total = R.equals(total, NaN) ? "0.00" : Number(total).toFixed(2)
dataTable2[tableMeta.rowIndex][tableMeta.columnIndex] = total
return total
} else {
total = R.equals(total, NaN) ? "0.0" : Number(total).toFixed(1)
dataTable2[tableMeta.rowIndex][tableMeta.columnIndex] = total
return total
}
}
const handleValueFormula = (value, tableMeta, dex, xntd, forecast, periode) => {
......@@ -1278,8 +1281,16 @@ export default class TaxPlanning extends Component {
}
})
}
dataTable2[tableMeta.rowIndex][21] = Number(total).toFixed(1)
return total
if (String(tableMeta.rowData[8]).toLocaleUpperCase() == "CORPORATE INCOME TAX") {
dataTable2[tableMeta.rowIndex][21] = Number(total).toFixed(2)
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) => {
let total = 0
......@@ -1775,7 +1786,7 @@ export default class TaxPlanning extends Component {
value={String(tableMeta.rowData[8]).toLocaleUpperCase() == "CORPORATE INCOME TAX" ? Number(value.fcp).toFixed(2) : Number(value.fcp).toFixed(1)}
onBlur={(event) => {
handleChange(event.target.value, tableMeta, 1)
// console.log(dataTable2)
console.log(dataTable2)
}}
/>
}
......@@ -1993,7 +2004,7 @@ export default class TaxPlanning extends Component {
type="text"
placeholder=""
disabled={true}
value={Number(handleValueFormula(value, tableMeta, 3)).toFixed(1)}
value={String(tableMeta.rowData[8]).toLocaleUpperCase() == "CORPORATE INCOME TAX" ? Number(handleValueFormula(value, tableMeta, 3)).toFixed(2) : Number(handleValueFormula(value, tableMeta, 3)).toFixed(1)}
/>
:
tableMeta.rowData[3] === 5 ?
......@@ -2473,14 +2484,14 @@ export default class TaxPlanning extends Component {
null
:
tableMeta.rowData[3] === 6 ?
<NumberFormat
thousandSeparator={true}
style={{ fontSize: 12, textAlign: 'right', borderColor: 'transparent', margin: 0, width: 96, backgroundColor: 'transparent' }}
type="text"
placeholder=""
disabled={true}
value={Number(handleValueFormula(value, tableMeta, 3)).toFixed(1)}
/>
<NumberFormat
thousandSeparator={true}
style={{ fontSize: 12, textAlign: 'right', borderColor: 'transparent', margin: 0, width: 96, backgroundColor: 'transparent' }}
type="text"
placeholder=""
disabled={true}
value={String(tableMeta.rowData[8]).toLocaleUpperCase() == "CORPORATE INCOME TAX" ? Number(handleValueFormula(value, tableMeta, 3)).toFixed(2) : Number(handleValueFormula(value, tableMeta, 3)).toFixed(1)}
/>
:
tableMeta.rowData[3] === 5 ?
<NumberFormat
......@@ -2962,14 +2973,14 @@ export default class TaxPlanning extends Component {
null
:
tableMeta.rowData[3] === 6 ?
<NumberFormat
thousandSeparator={true}
style={{ fontSize: 12, textAlign: 'right', borderColor: 'transparent', margin: 0, width: 96, backgroundColor: 'transparent' }}
type="text"
placeholder=""
disabled={true}
value={Number(handleValueFormula(value, tableMeta, 3)).toFixed(1)}
/>
<NumberFormat
thousandSeparator={true}
style={{ fontSize: 12, textAlign: 'right', borderColor: 'transparent', margin: 0, width: 96, backgroundColor: 'transparent' }}
type="text"
placeholder=""
disabled={true}
value={String(tableMeta.rowData[8]).toLocaleUpperCase() == "CORPORATE INCOME TAX" ? Number(handleValueFormula(value, tableMeta, 3)).toFixed(2) : Number(handleValueFormula(value, tableMeta, 3)).toFixed(1)}
/>
:
tableMeta.rowData[3] === 5 ?
<NumberFormat
......@@ -3450,14 +3461,14 @@ export default class TaxPlanning extends Component {
null
:
tableMeta.rowData[3] === 6 ?
<NumberFormat
thousandSeparator={true}
style={{ fontSize: 12, textAlign: 'right', borderColor: 'transparent', margin: 0, width: 96, backgroundColor: 'transparent' }}
type="text"
placeholder=""
disabled={true}
value={Number(handleValueFormula(value, tableMeta, 3)).toFixed(1)}
/>
<NumberFormat
thousandSeparator={true}
style={{ fontSize: 12, textAlign: 'right', borderColor: 'transparent', margin: 0, width: 96, backgroundColor: 'transparent' }}
type="text"
placeholder=""
disabled={true}
value={String(tableMeta.rowData[8]).toLocaleUpperCase() == "CORPORATE INCOME TAX" ? Number(handleValueFormula(value, tableMeta, 3)).toFixed(2) : Number(handleValueFormula(value, tableMeta, 3)).toFixed(1)}
/>
:
tableMeta.rowData[3] === 5 ?
<NumberFormat
......@@ -3940,14 +3951,14 @@ export default class TaxPlanning extends Component {
null
:
tableMeta.rowData[3] === 6 ?
<NumberFormat
thousandSeparator={true}
style={{ fontSize: 12, textAlign: 'right', borderColor: 'transparent', margin: 0, width: 96, backgroundColor: 'transparent' }}
type="text"
placeholder=""
disabled={true}
value={Number(handleValueFormula(value, tableMeta, 3)).toFixed(1)}
/>
<NumberFormat
thousandSeparator={true}
style={{ fontSize: 12, textAlign: 'right', borderColor: 'transparent', margin: 0, width: 96, backgroundColor: 'transparent' }}
type="text"
placeholder=""
disabled={true}
value={String(tableMeta.rowData[8]).toLocaleUpperCase() == "CORPORATE INCOME TAX" ? Number(handleValueFormula(value, tableMeta, 3)).toFixed(2) : Number(handleValueFormula(value, tableMeta, 3)).toFixed(1)}
/>
:
tableMeta.rowData[3] === 5 ?
<NumberFormat
......@@ -4430,14 +4441,14 @@ export default class TaxPlanning extends Component {
null
:
tableMeta.rowData[3] === 6 ?
<NumberFormat
thousandSeparator={true}
style={{ fontSize: 12, textAlign: 'right', borderColor: 'transparent', margin: 0, width: 96, backgroundColor: 'transparent' }}
type="text"
placeholder=""
disabled={true}
value={Number(handleValueFormula(value, tableMeta, 3)).toFixed(1)}
/>
<NumberFormat
thousandSeparator={true}
style={{ fontSize: 12, textAlign: 'right', borderColor: 'transparent', margin: 0, width: 96, backgroundColor: 'transparent' }}
type="text"
placeholder=""
disabled={true}
value={String(tableMeta.rowData[8]).toLocaleUpperCase() == "CORPORATE INCOME TAX" ? Number(handleValueFormula(value, tableMeta, 3)).toFixed(2) : Number(handleValueFormula(value, tableMeta, 3)).toFixed(1)}
/>
:
tableMeta.rowData[3] === 5 ?
<NumberFormat
......@@ -4920,14 +4931,14 @@ export default class TaxPlanning extends Component {
null
:
tableMeta.rowData[3] === 6 ?
<NumberFormat
thousandSeparator={true}
style={{ fontSize: 12, textAlign: 'right', borderColor: 'transparent', margin: 0, width: 96, backgroundColor: 'transparent' }}
type="text"
placeholder=""
disabled={true}
value={Number(handleValueFormula(value, tableMeta, 3)).toFixed(1)}
/>
<NumberFormat
thousandSeparator={true}
style={{ fontSize: 12, textAlign: 'right', borderColor: 'transparent', margin: 0, width: 96, backgroundColor: 'transparent' }}
type="text"
placeholder=""
disabled={true}
value={String(tableMeta.rowData[8]).toLocaleUpperCase() == "CORPORATE INCOME TAX" ? Number(handleValueFormula(value, tableMeta, 3)).toFixed(2) : Number(handleValueFormula(value, tableMeta, 3)).toFixed(1)}
/>
:
tableMeta.rowData[3] === 5 ?
<NumberFormat
......@@ -5410,14 +5421,14 @@ export default class TaxPlanning extends Component {
null
:
tableMeta.rowData[3] === 6 ?
<NumberFormat
thousandSeparator={true}
style={{ fontSize: 12, textAlign: 'right', borderColor: 'transparent', margin: 0, width: 96, backgroundColor: 'transparent' }}
type="text"
placeholder=""
disabled={true}
value={Number(handleValueFormula(value, tableMeta, 3)).toFixed(1)}
/>
<NumberFormat
thousandSeparator={true}
style={{ fontSize: 12, textAlign: 'right', borderColor: 'transparent', margin: 0, width: 96, backgroundColor: 'transparent' }}
type="text"
placeholder=""
disabled={true}
value={String(tableMeta.rowData[8]).toLocaleUpperCase() == "CORPORATE INCOME TAX" ? Number(handleValueFormula(value, tableMeta, 3)).toFixed(2) : Number(handleValueFormula(value, tableMeta, 3)).toFixed(1)}
/>
:
tableMeta.rowData[3] === 5 ?
<NumberFormat
......@@ -5900,14 +5911,14 @@ export default class TaxPlanning extends Component {
null
:
tableMeta.rowData[3] === 6 ?
<NumberFormat
thousandSeparator={true}
style={{ fontSize: 12, textAlign: 'right', borderColor: 'transparent', margin: 0, width: 96, backgroundColor: 'transparent' }}
type="text"
placeholder=""
disabled={true}
value={Number(handleValueFormula(value, tableMeta, 3)).toFixed(1)}
/>
<NumberFormat
thousandSeparator={true}
style={{ fontSize: 12, textAlign: 'right', borderColor: 'transparent', margin: 0, width: 96, backgroundColor: 'transparent' }}
type="text"
placeholder=""
disabled={true}
value={String(tableMeta.rowData[8]).toLocaleUpperCase() == "CORPORATE INCOME TAX" ? Number(handleValueFormula(value, tableMeta, 3)).toFixed(2) : Number(handleValueFormula(value, tableMeta, 3)).toFixed(1)}
/>
:
tableMeta.rowData[3] === 5 ?
<NumberFormat
......@@ -6390,14 +6401,14 @@ export default class TaxPlanning extends Component {
null
:
tableMeta.rowData[3] === 6 ?
<NumberFormat
thousandSeparator={true}
style={{ fontSize: 12, textAlign: 'right', borderColor: 'transparent', margin: 0, width: 96, backgroundColor: 'transparent' }}
type="text"
placeholder=""
disabled={true}
value={Number(handleValueFormula(value, tableMeta, 3)).toFixed(1)}
/>
<NumberFormat
thousandSeparator={true}
style={{ fontSize: 12, textAlign: 'right', borderColor: 'transparent', margin: 0, width: 96, backgroundColor: 'transparent' }}
type="text"
placeholder=""
disabled={true}
value={String(tableMeta.rowData[8]).toLocaleUpperCase() == "CORPORATE INCOME TAX" ? Number(handleValueFormula(value, tableMeta, 3)).toFixed(2) : Number(handleValueFormula(value, tableMeta, 3)).toFixed(1)}
/>
:
tableMeta.rowData[3] === 5 ?
<NumberFormat
......@@ -6880,14 +6891,14 @@ export default class TaxPlanning extends Component {
null
:
tableMeta.rowData[3] === 6 ?
<NumberFormat
thousandSeparator={true}
style={{ fontSize: 12, textAlign: 'right', borderColor: 'transparent', margin: 0, width: 96, backgroundColor: 'transparent' }}
type="text"
placeholder=""
disabled={true}
value={Number(handleValueFormula(value, tableMeta, 3)).toFixed(1)}
/>
<NumberFormat
thousandSeparator={true}
style={{ fontSize: 12, textAlign: 'right', borderColor: 'transparent', margin: 0, width: 96, backgroundColor: 'transparent' }}
type="text"
placeholder=""
disabled={true}
value={String(tableMeta.rowData[8]).toLocaleUpperCase() == "CORPORATE INCOME TAX" ? Number(handleValueFormula(value, tableMeta, 3)).toFixed(2) : Number(handleValueFormula(value, tableMeta, 3)).toFixed(1)}
/>
:
tableMeta.rowData[3] === 5 ?
<NumberFormat
......@@ -7370,14 +7381,14 @@ export default class TaxPlanning extends Component {
null
:
tableMeta.rowData[3] === 6 ?
<NumberFormat
thousandSeparator={true}
style={{ fontSize: 12, textAlign: 'right', borderColor: 'transparent', margin: 0, width: 96, backgroundColor: 'transparent' }}
type="text"
placeholder=""
disabled={true}
value={Number(handleValueFormula(value, tableMeta, 3)).toFixed(1)}
/>
<NumberFormat
thousandSeparator={true}
style={{ fontSize: 12, textAlign: 'right', borderColor: 'transparent', margin: 0, width: 96, backgroundColor: 'transparent' }}
type="text"
placeholder=""
disabled={true}
value={String(tableMeta.rowData[8]).toLocaleUpperCase() == "CORPORATE INCOME TAX" ? Number(handleValueFormula(value, tableMeta, 3)).toFixed(2) : Number(handleValueFormula(value, tableMeta, 3)).toFixed(1)}
/>
:
tableMeta.rowData[3] === 5 ?
<NumberFormat
......@@ -7497,7 +7508,7 @@ export default class TaxPlanning extends Component {
}
/>
</div> :
tableMeta.rowData[24] === 77 ?
tableMeta.rowData[8] === "Income Before Tax (NPBT)" ?
<div style={{ flex: 1 }}>
<FormControlLabel
style={{ margin: 0 }}
......@@ -7545,7 +7556,7 @@ export default class TaxPlanning extends Component {
type="text"
placeholder="input"
disabled={this.props.isApprover == true ? true : ((this.props.lastStatus === 'SUBMIT' || this.props.lastStatus === 'REVISION') && this.props.prevRevision === false && (this.props.status === 'revision' || this.props.status === 'not-yet' || this.props.status === 'draft' || this.props.status === 'submitted') ? false : true)}
value={Number(handleNewFormula(tableMeta, 3, "@83*@87#TP2")).toFixed(1)}
value={Number(handleNewFormula(tableMeta, 3, "@83*@87#TP2")).toFixed(2)}
/>
}
/>
......@@ -8160,7 +8171,7 @@ export default class TaxPlanning extends Component {
type="text"
placeholder=""
disabled={true}
value={Number(handleForecast(tableMeta, Number(this.props.periode) + 1, 3)).toFixed(1)}
value={String(tableMeta.rowData[8]).toLocaleUpperCase() == "CORPORATE INCOME TAX" ? Number(handleForecast(tableMeta, Number(this.props.periode) + 1, 3)).toFixed(2) : Number(handleForecast(tableMeta, Number(this.props.periode) + 1, 3)).toFixed(1)}
/>
// null
:
......@@ -8689,7 +8700,7 @@ export default class TaxPlanning extends Component {
type="text"
placeholder=""
disabled={true}
value={Number(handleForecast(tableMeta, Number(this.props.periode) + 2, 3)).toFixed(1)}
value={String(tableMeta.rowData[8]).toLocaleUpperCase() == "CORPORATE INCOME TAX" ? Number(handleForecast(tableMeta, Number(this.props.periode) + 2, 3)).toFixed(2) : Number(handleForecast(tableMeta, Number(this.props.periode) + 2, 3)).toFixed(1)}
/>
// null
:
......
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