fix closing error/success message
This commit is contained in:
parent
c3d1c51000
commit
9cd60d131e
@ -40,7 +40,7 @@ class Main extends Component {
|
||||
for(const [key, value] of searchParams){
|
||||
if (key == "refId"){
|
||||
fetch(addr_prefix + "/api/payment_state?refId=" + value).then(resp => resp.json()).then(json =>{
|
||||
this.setState({status: json.status, text: json.reason})
|
||||
this.setState({status: json.status, status_text: json.reason})
|
||||
})
|
||||
}
|
||||
}
|
||||
@ -85,12 +85,12 @@ class Main extends Component {
|
||||
this.setState({progress:false, uploadProgress: 1.0});
|
||||
if(data.reason){
|
||||
this.setState({
|
||||
text: data.reason,
|
||||
status_text: data.reason,
|
||||
status: "failed",
|
||||
})
|
||||
} else {
|
||||
this.setState({
|
||||
text: data.success,
|
||||
status_text: data.success,
|
||||
status: "success",
|
||||
})
|
||||
if (data.redirect){
|
||||
@ -100,7 +100,7 @@ class Main extends Component {
|
||||
}).catch((error) => {
|
||||
this.setState({
|
||||
progress: false,
|
||||
text: "Chyba: " + error.response.status +", " + error.response.data,
|
||||
status_text: "Chyba: " + error.response.status +", " + error.response.data,
|
||||
status: "failed",
|
||||
})
|
||||
});
|
||||
|
Loading…
x
Reference in New Issue
Block a user