Commit e09c5ac1 authored by muhammad ridwan's avatar muhammad ridwan

Merge branch 'ENV-DEV-CR-CAFRM' into 'ENV-DEPLOYMENT'

Env dev cr cafrm

See merge request !1617
parents ab6909b9 14822e98
......@@ -193,10 +193,10 @@ class RepotrCafrm extends Component {
}
async downloadData() {
let url = `${process.env.REACT_APP_URL_MAIN_BE}/public/transaction/monitoring/export_cafrm_report?periode=${this.state.curYear}&months=${this.state.curMonth}`
let url = `${process.env.REACT_APP_URL_MAIN_BE}/public/transaction/monitoring/export_cafrm_report?periode=${this.state.curYear}&months=${this.state.curMonth}&status=${this.state.curStatus}`
console.log(url);
let res = await fetch(
`${process.env.REACT_APP_URL_MAIN_BE}/public/transaction/monitoring/export_cafrm_report?periode=${this.state.curYear}&months=${this.state.curMonth}`
`${process.env.REACT_APP_URL_MAIN_BE}/public/transaction/monitoring/export_cafrm_report?periode=${this.state.curYear}&months=${this.state.curMonth}&status=${this.state.curStatus}`
)
res = await res.blob()
this.setState({ loading: false })
......@@ -204,7 +204,7 @@ class RepotrCafrm extends Component {
let url = window.URL.createObjectURL(res);
let a = document.createElement('a');
a.href = url;
a.download = `Progress Report CARFM ${this.state.curYear}-${this.state.curMonth}.xlsx`;
a.download = `Progress Report CARFM ${this.state.curYear}-${this.state.curMonth}-${this.state.defaultStatus.name}.xlsx`;
a.click();
}
}
......
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