Commit b1e0992e authored by Riri Novita's avatar Riri Novita

Issue Prod Subco

parent 91ee0ec2
...@@ -4328,7 +4328,7 @@ export default class SubHolding extends Component { ...@@ -4328,7 +4328,7 @@ export default class SubHolding extends Component {
onChange={(event, newInputValue) => this.setState({ periode: newInputValue, loading: true, previewTable: false }, () => { onChange={(event, newInputValue) => this.setState({ periode: newInputValue, loading: true, previewTable: false }, () => {
let tahun = Number(this.state.periode.periode) let tahun = Number(this.state.periode.periode)
let bizpar = tahun >= 2024 && defaultCurrencyID == 2 && newInputValue.id == 1 ? defaultReport.filter(e => e.report === 2) : defaultReport let bizpar = tahun >= 2024 && defaultCurrencyID == 2 && newInputValue.id == 1 ? defaultReport.filter(e => e.report === 2) : defaultReport
this.setState({ report: bizpar[0], reportType: bizpar }) this.setState({ report: this.state.report, reportType: bizpar })
this.getCurrency(this.state.company.company_id) this.getCurrency(this.state.company.company_id)
this.getReportType() this.getReportType()
})} })}
...@@ -4351,7 +4351,7 @@ export default class SubHolding extends Component { ...@@ -4351,7 +4351,7 @@ export default class SubHolding extends Component {
this.getCurrency(newInputValue.company_id) this.getCurrency(newInputValue.company_id)
let tahun = Number(this.state.periode.periode) let tahun = Number(this.state.periode.periode)
let bizpar = tahun >= 2024 && defaultCurrencyID == 2 && newInputValue.id == 1 ? defaultReport.filter(e => e.report === 2) : defaultReport let bizpar = tahun >= 2024 && defaultCurrencyID == 2 && newInputValue.id == 1 ? defaultReport.filter(e => e.report === 2) : defaultReport
this.setState({ report: bizpar[0], reportType: bizpar }) this.setState({ report: this.state.report, reportType: bizpar })
})} })}
disableClearable disableClearable
style={{ width: 250 }} style={{ width: 250 }}
...@@ -4392,7 +4392,7 @@ export default class SubHolding extends Component { ...@@ -4392,7 +4392,7 @@ export default class SubHolding extends Component {
// } // }
let tahun = Number(this.state.periode.periode) let tahun = Number(this.state.periode.periode)
let bizpar = tahun >= 2024 && defaultCurrencyID == 2 && newInputValue.id == 1 ? defaultReport.filter(e => e.report === 2) : defaultReport let bizpar = tahun >= 2024 && defaultCurrencyID == 2 && newInputValue.id == 1 ? defaultReport.filter(e => e.report === 2) : defaultReport
this.setState({ report: bizpar[0], reportType: bizpar }) this.setState({ report: tahun >= 2024 ? bizpar[0] : this.state.report, reportType: bizpar })
this.getReportType() this.getReportType()
})} })}
......
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