Commit cf519c45 by zhangleyuan

feat:处理视频课直播课创建成功后的跳转

parent 6cf380e8
......@@ -346,7 +346,9 @@ handleChangeBasicInfo = (field, value) => {
CourseService.createLiveCloudCourse(params).then((res) => {
if (res.success){
message.success("新建成功");
window.RCHistory.goBack();
window.RCHistory.push({
pathname: `/live-course`,
});
}
});
......@@ -359,7 +361,9 @@ handleChangeBasicInfo = (field, value) => {
CourseService.updateLiveCloudCourse(params).then((res) => {
if (res.success){
message.success("更新成功");
window.RCHistory.goBack();
window.RCHistory.push({
pathname: `/live-course`,
});
}
});
}
......@@ -493,11 +497,15 @@ handleChangeBasicInfo = (field, value) => {
cancelText: '留在本页',
icon: <span className="icon iconfont default-confirm-icon">&#xe6f4;</span>,
onOk: () => {
window.RCHistory.goBack();
window.RCHistory.push({
pathname: `/live-course`,
});
}
})
} else {
window.RCHistory.goBack();
window.RCHistory.push({
pathname: `/live-course`,
});
}
}
......
......@@ -2,7 +2,7 @@
* @Author: 吴文洁
* @Date: 2020-08-05 10:07:47
* @LastEditors: zhangleyuan
* @LastEditTime: 2021-03-11 15:29:41
* @LastEditTime: 2021-03-12 10:12:23
* @Description: 视频课新增/编辑页
* @Copyright: 杭州杰竞科技有限公司 版权所有
*/
......@@ -200,11 +200,15 @@ class AddVideoCourse extends React.Component {
cancelText: '留在本页',
icon: <span className="icon iconfont default-confirm-icon">&#xe6f4;</span>,
onOk: () => {
RCHistory.goBack();
window.RCHistory.push({
pathname: `/video-course`,
});
}
});
}else{
RCHistory.goBack();
window.RCHistory.push({
pathname: `/video-course`,
});
}
}
......@@ -349,7 +353,9 @@ class AddVideoCourse extends React.Component {
CourseService.createVideoSchedule(commonParams).then((res) => {
if (!res) return;
message.success("新建成功");
window.RCHistory.goBack();
window.RCHistory.push({
pathname: `/video-course`,
});
})
} else {
const editParams = {
......@@ -359,7 +365,9 @@ class AddVideoCourse extends React.Component {
CourseService.editVideoSchedule(editParams).then((res) => {
if (!res) return;
message.success("保存成功");
window.RCHistory.goBack();
window.RCHistory.push({
pathname: `/video-course`,
});
});
}
});
......
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