diff --git a/public/react/src/App.js b/public/react/src/App.js index 7ec25ebc8..e6f55f5d2 100644 --- a/public/react/src/App.js +++ b/public/react/src/App.js @@ -275,6 +275,11 @@ class App extends Component { }) window.location.href = "/"; }; + ModalshowCancelsy=()=>{ + this.setState({ + mydisplay:true, + }) + }; componentDidMount() { // force an update if the URL changes history.listen(() => { @@ -327,7 +332,7 @@ class App extends Component { this.HideAddcoursestypess(i)}/> - + diff --git a/public/react/src/modules/courses/new/Goldsubject.js b/public/react/src/modules/courses/new/Goldsubject.js index da7a12b3f..1e72d1995 100644 --- a/public/react/src/modules/courses/new/Goldsubject.js +++ b/public/react/src/modules/courses/new/Goldsubject.js @@ -442,7 +442,8 @@ class Goldsubject extends Component { var subjectids=this.props.match.params.subjectid; window.location.href=`/paths/${subjectids}` }else{ - this.props.history.goBack(); + // this.props.history.goBack(); + window.location.href=`/courses/${this.props.match.params.coursesId}/informs` } } diff --git a/public/react/src/modules/modals/Certifiedprofessional.js b/public/react/src/modules/modals/Certifiedprofessional.js index 5e3df4abb..af192273a 100644 --- a/public/react/src/modules/modals/Certifiedprofessional.js +++ b/public/react/src/modules/modals/Certifiedprofessional.js @@ -18,20 +18,23 @@ class Certifiedprofessional extends Component { componentDidMount() { // console.log("加入金品课堂"); // console.log(this.props); + axios.interceptors.response.use((response) => { + if (response != undefined) + if (response && response.data.status === 410) { + try { + this.props.ModalshowCancelsy(); + }catch (e) { + + } + + } + return response; + }, (error) => { + + }); } - componentDidMount() { - // axios.interceptors.response.use((response) => { - // if (response != undefined) - // if (response && response.data.status === -1) { - // - // } - // return response; - // }, (error) => { - // //TODO 这里如果样式变了会出现css不加载的情况 - // - // }); - } + modalCancel=()=>{ this.props.ModalCancelsy(); };