Commit 20de32fb authored by r.kurnia's avatar r.kurnia

input tpmr

parent 7dcb1ad9
......@@ -977,6 +977,7 @@ export default class TaxPlanningMR extends Component {
}
const handleChange = (value, tableMeta, indexChilds) => {
console.log(dataTable2)
let val = String(value).split(",").join("")
// let data = this.state.dataTable2
let indexParent = dataTable2.findIndex((val) => val[4] === dataTable2[tableMeta.rowIndex][5])
......@@ -1246,7 +1247,7 @@ export default class TaxPlanningMR extends Component {
</th>
),
setCellProps: () => ({ style2 }),
customBodyRender: (val, tableMeta, updateValue) => {
customBodyRender: (value, tableMeta, updateValue) => {
return (
<div>
<div className="grid grid-3x content-center">
......@@ -1254,7 +1255,7 @@ export default class TaxPlanningMR extends Component {
<div style={{ textAlign: 'right', width: 90 }}>
{tableMeta.rowData[0] === 4 ?
null :
val.tbc
value.tbc
}
</div>
</div>
......@@ -1262,7 +1263,29 @@ export default class TaxPlanningMR extends Component {
<div style={{ textAlign: 'right', width: 90 }}>
{tableMeta.rowData[0] === 4 ?
null :
val.fcp
tableMeta.rowData[0] === 2 ?
null :
tableMeta.rowData[0] === 1 ?
null :
<div style={{ flex: 1 }}>
<FormControlLabel
style={{ margin: 0 }}
value={value.fcp}
control={
<NumberFormat
thousandSeparator={true}
style={{ color: "#5198ea", fontSize: 12, textAlign: 'right', borderColor: 'transparent', margin: 0, width: 96, backgroundColor: 'transparent' }}
type="text"
placeholder="input"
value={String(tableMeta.rowData[5]).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)
}}
/>
}
/>
</div>
}
</div>
</div>
......@@ -1270,7 +1293,7 @@ export default class TaxPlanningMR extends Component {
<div style={{ textAlign: 'right', width: 90 }}>
{tableMeta.rowData[0] === 4 ?
null :
val.tbf
value.tbf
}
</div>
</div>
......
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