Skip to content

Commit

Permalink
fix: 修复导航表单模式和yaml模式切换后跳转路由问题 (merge request !1485)
Browse files Browse the repository at this point in the history
Squash merge branch 'fix_webconsole' into 'master'
fix: 修复导航表单模式和yaml模式切换后跳转路由问题
  • Loading branch information
hitozhang committed Oct 28, 2023
1 parent 46b201b commit afafb1c
Show file tree
Hide file tree
Showing 2 changed files with 8 additions and 3 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -122,6 +122,8 @@ import request from '@/api/request';
import Header from '@/components/layout/Header.vue';
import CodeEditor from '@/components/monaco-editor/new-editor.vue';
import fullScreen from '@/directives/full-screen';
import $router from '@/router';
import $store from '@/store';
const BKForm = createForm({
namespace: 'bcs',
Expand Down Expand Up @@ -432,7 +434,8 @@ export default {
theme: 'success',
message: this.$t('generic.msg.success.update'),
});
this.$router.back();
// 跳转回列表页
$router.push({ name: $store.state.curSideMenu?.route });
}
},
});
Expand Down Expand Up @@ -472,7 +475,8 @@ export default {
message: this.$t('generic.msg.success.create'),
});
this.$store.commit('updateCurNamespace', this.schemaFormData.metadata?.namespace);
this.$router.back();
// 跳转回列表页
$router.push({ name: $store.state.curSideMenu?.route });
}
},
// 表单预览
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -569,7 +569,8 @@ export default defineComponent({
message: $i18n.t('generic.msg.success.create'),
});
$store.commit('updateCurNamespace', detail.value.metadata?.namespace);
$router.back();
// 跳转回列表页
$router.push({ name: $store.state.curSideMenu?.route });
}
};
const handleUpdateResource = () => {
Expand Down

0 comments on commit afafb1c

Please sign in to comment.