dev_oauth
杨树林 6 years ago
parent 942e5d9752
commit 2729871a36

@ -248,9 +248,9 @@ class CoursesBanner extends Component {
axios.post(url).then((response) => {
if(response!==undefined){
window.location.href = "/courses/" + response.data.new_course_id+"/students";
}else {
this.modalCancel();
return
}
this.modalCancel();
// window.location.href = "/courses/" + response.data.new_course_id;
}).catch(function (error) {
@ -259,19 +259,16 @@ class CoursesBanner extends Component {
console.log(error);
});
// axios.interceptors.response.use((response) => {
// if (response != undefined)
// if (response && response.data.status === -1) {
// this.setState({
// antIcon: false,
// })
//
// }
// return response;
// }, (error) => {
// //TODO 这里如果样式变了会出现css不加载的情况
//
// });
axios.interceptors.response.use((response) => {
if (response != undefined)
if (response && response.data.status === -1) {
this.modalCancel();
}
return response;
}, (error) => {
//TODO 这里如果样式变了会出现css不加载的情况
});
}
if(this.state.metype===6){

Loading…
Cancel
Save