Commit 27d8d90f authored by Riri Novita's avatar Riri Novita

Merge branch 'riri' into 'master'

handletektektek

See merge request !857
parents 3a7ed211 587548ec
......@@ -419,7 +419,7 @@ export default class BalanceSheetMR extends Component {
this.props.onClickClose()
// this.props.getReport()
} else {
this.setState({ alert: true, messageAlert: response.data.message, tipeAlert: 'warning', loading: false }, () => {
this.setState({ alert: true, messageAlert: response.data.message, tipeAlert: 'warning', loading: false, handleTekTekTek: 0 }, () => {
if (response.data.message.includes("Someone Logged In")) {
setTimeout(() => {
localStorage.removeItem(Constant.TOKEN)
......@@ -429,7 +429,7 @@ export default class BalanceSheetMR extends Component {
})
}
} else {
this.setState({ alert: true, messageAlert: response.problem, tipeAlert: 'error', loading: false })
this.setState({ alert: true, messageAlert: response.problem, tipeAlert: 'error', loading: false, handleTekTekTek: 0 })
}
})
}
......@@ -472,12 +472,12 @@ export default class BalanceSheetMR extends Component {
if (response.data.status === "success") {
this.props.saveToMonthlyReport()
} else {
this.setState({ loading: false }, () => {
this.setState({ loading: false, handleTekTekTek: 0 }, () => {
this.props.saveToMonthlyReport()
})
}
} else {
this.setState({ loading: false })
this.setState({ loading: false, handleTekTekTek: 0 })
}
})
}
......
......@@ -389,12 +389,12 @@ export default class ProfitLossMR extends Component {
if (response.data.status === "success") {
this.props.saveToMonthlyReport()
} else {
this.setState({ loading: false }, () => {
this.setState({ loading: false, handleTekTekTek: 0 }, () => {
this.props.saveToMonthlyReport()
})
}
} else {
this.setState({ loading: false })
this.setState({ loading: false, handleTekTekTek: 0 })
}
})
}
......@@ -537,7 +537,7 @@ export default class ProfitLossMR extends Component {
// this.props.onClickClose()
// this.props.getReport()
} else {
this.setState({ alert: true, messageAlert: response.data.message, tipeAlert: 'warning', loading: false }, () => {
this.setState({ alert: true, messageAlert: response.data.message, tipeAlert: 'warning', loading: false, handleTekTekTek: 0 }, () => {
if (response.data.message.includes("Someone Logged In")) {
setTimeout(() => {
localStorage.removeItem(Constant.TOKEN)
......@@ -548,10 +548,10 @@ export default class ProfitLossMR extends Component {
// alert(response.data.status)
}
} else {
this.setState({ alert: true, messageAlert: response.data.message, tipeAlert: 'error', loading: false })
this.setState({ alert: true, messageAlert: response.data.message, tipeAlert: 'error', loading: false, handleTekTekTek: 0 })
}
} else {
this.setState({ alert: true, messageAlert: response.problem, tipeAlert: 'error', loading: false })
this.setState({ alert: true, messageAlert: response.problem, tipeAlert: 'error', loading: false, handleTekTekTek: 0 })
}
})
}
......
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