Commit f2b2151e authored by d.arizona's avatar d.arizona

update BS

parent 1d40c17f
......@@ -689,7 +689,7 @@ export default class BalanceSheetRO extends Component {
return total
}
const handleValueFormula = (value, tableMeta, colIdx) => {
const handleValueFormula = (value, tableMeta, colIdx, periode, forecast) => {
let splitFormula = String(tableMeta.rowData[3]).split(/([()@])/)
let baru = []
let anjay = []
......@@ -722,7 +722,15 @@ export default class BalanceSheetRO extends Component {
anjay.push(item)
} else {
if (String(item).includes('#')) {
if (String(item).includes('[M-1]')) {
if (forecast !== undefined) {
let forecastt = 0
forecast.map((items, index) => {
if (items.periode == periode) {
forecastt += Number(items.value)
}
})
anjay.push(forecastt)
} else if (String(item).includes('[M-1]')) {
let tst = String(item).replace('[M-1]', '')
let data = tableMeta.columnIndex == 7 ? 18 : tableMeta.columnIndex - 1
let period = data == 18 ? Number(this.props.periode) - 1 : this.props.periode
......@@ -2336,8 +2344,8 @@ export default class BalanceSheetRO extends Component {
type="text"
placeholder=""
disabled={true}
// value={Number(handleForecast(tableMeta, `${Number(this.props.periode)}`, 19)).toFixed(1)}
value={Number(val).toFixed(1)}
value={Number(handleForecast(tableMeta, `${Number(this.props.periode)}`, 19)).toFixed(1)}
// value={Number(val).toFixed(1)}
/>
}
/>
......
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