Commit d0e51ac2 authored by rifkaki's avatar rifkaki

Merge branch 'master' of http://103.44.149.204/d.arizona/tia-dev into rifka

parents f0ab7251 8bb3b8a3
......@@ -276,10 +276,12 @@ export default class SubHolding extends Component {
// console.log(data)
// console.log(yearNow)
// console.log(periode)
let index = data.sort((a, b) => a - b).findIndex((val) => val.periode == (String(this.state.report.label).toLocaleLowerCase().includes('summary') ? yearNow : periode))
// console.log(index)
this.setState({periode: data[index]})
if (String(this.state.report.label).toLocaleLowerCase().includes('summary')) {
let index = data.sort((a, b) => a - b).findIndex((val) => val.periode == yearNow)
// console.log(index)
this.setState({periode: data[index]})
}
let payload = {
"company_id": this.state.company.company_id,
"periode": this.state.periode.periode,
......
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